Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Photogrammery #192

Open
OrionOth opened this issue Jan 16, 2024 · 0 comments
Open

Photogrammery #192

OrionOth opened this issue Jan 16, 2024 · 0 comments
Labels
priority: nice to have Would be nice to complete this, but not required

Comments

@OrionOth
Copy link
Member

OrionOth commented Jan 16, 2024

Here lies my notes on making a to-scale 3d model of a specific pvc pipe structure.

Rough OpenSCAD mockup of the shape
WIDTH = 36; // 36 cm
UNION_OFFSET = 0.001;
LABEL_SIZE = 3;
LABEL_FONT = "monospace";
LABEL_COLOR = "black";

x1 = 35; // unknown
y1 = 10 + 4;
x2 = 32 + 4; // corner to corner inside pipes
y2 = 26 + 2 + 30; // unknown
x3 = 40; // unknown
y3 = 26 + 4;

ch = 15; // unknown
rh = 5;  // irrelevant abstraction

//p0 = [0, 0];
p1 = [x1 + x2 + x3, 0];
p2 = [x1 + x2 + x3, y3];
p3 = [x1 + x2, y3];
p4 = [x1 + x2, y2];
p5 = [x1, y2];
p6 = [x1, y1];
p7 = [0, y1];

translate([-(x1 + x2/2), 0, 0])
rotate([90,0,0]){
    linear_extrude(WIDTH, center = true)
        polygon(points = [[0, 0], p1, p2, p3, p4, p5, p6, p7]);

    // Labels
    translate([0,0,WIDTH/2])
    color(LABEL_COLOR)
    linear_extrude(1, center = true)
    {
        translate([x1/2,y1,0])
            text(str(x1, "cm"), LABEL_SIZE, LABEL_FONT, halign = "center", valign = "top");
        translate([0,y1/2,0])
            text(str(y1, "cm"), LABEL_SIZE, LABEL_FONT, halign = "left", valign = "center");
        translate([x1+x2/2, y2, 0])
            text(str(x2, "cm"), LABEL_SIZE, LABEL_FONT, halign = "center", valign = "top");
        translate([x1,y1+(y2-y1)/2,0])
            text(str(y2-y1, "cm"), LABEL_SIZE, LABEL_FONT, halign = "left", valign = "center");
        translate([x1+x2+x3/2,y3,0])
            text(str(x3, "cm"), LABEL_SIZE, LABEL_FONT, halign = "center", valign = "top");
        translate([x1+x2,y3+(y2-y3)/2,0])
            text(str(y2-y3, "cm"), LABEL_SIZE, LABEL_FONT, halign = "right", valign = "center");
        translate([x1+x2+x3,y3/2,0])
            text(str(y3, "cm"), LABEL_SIZE, LABEL_FONT, halign = "right", valign = "center");
        translate([(x1+x2+x3)/2,0,0])
            text(str(x1+x2+x3, "cm"), LABEL_SIZE, LABEL_FONT, halign = "center", valign = "bottom");
    }
}

// Bounding box for top coral
translate([0,0,y2 + ch/2])
cylinder(h = ch, r = rh, center = true);

Keywords: Photogrammetry, Structure from Motion (SFM), Multi-view Geometry (MVG), Computer Vision (CV), Simultaneous Localization and Mapping (SLAM), Scale-invariant feature transform (SIFT)

https://szeliski.org/Book/

@steph1111 steph1111 changed the title Automatic 3d Coral Model Photogrammery May 3, 2024
@steph1111 steph1111 added the priority: nice to have Would be nice to complete this, but not required label May 3, 2024
@steph1111 steph1111 moved this to Not Started in Todo 2024 May 3, 2024
@liamgilligan liamgilligan moved this from Not Started to Not doing in Todo 2024 Jun 1, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
priority: nice to have Would be nice to complete this, but not required
Projects
Status: Not doing
Development

No branches or pull requests

2 participants