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

Added pinhole functionality for depth mapping #3

Merged
merged 10 commits into from
Oct 29, 2024
Merged

Conversation

JoKhannn
Copy link
Contributor

@JoKhannn JoKhannn commented Oct 9, 2024

No description provided.

Copy link
Owner

@makeecat makeecat left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please investigate the mismatch of 3d asset and rendered depth image pointcloud

.idea/.gitignore Outdated Show resolved Hide resolved
.idea/Peng.iml Outdated Show resolved Hide resolved
.idea/modules.xml Outdated Show resolved Hide resolved
.idea/vcs.xml Outdated Show resolved Hide resolved
src/lib.rs Show resolved Hide resolved
@makeecat
Copy link
Owner

let pinhole_camera = rerun::Pinhole::from_focal_length_and_resolution(
        (width as f32 / 2.0, height as f32 / 2.0),
        (width as f32, height as f32),
    )
    .with_camera_xyz(rerun::components::ViewCoordinates::RDF)
    .with_resolution((width as f32, height as f32))
    .with_principal_point((width as f32 / 2.0, height as f32 / 2.0));

seems like from_fov_and_aspect_ratio has a bug? The above code works for me if I set the fov as 90 degrees and set the resolution as a square (ex. [128, 128].

I suggest we use the from_focal_length_resolution to setup the pinhole camera.

@makeecat makeecat changed the base branch from main to develop October 17, 2024 02:15
config/quad.yaml Show resolved Hide resolved
src/lib.rs Show resolved Hide resolved
src/main.rs Show resolved Hide resolved
@makeecat makeecat changed the base branch from develop to main October 29, 2024 20:03
@makeecat makeecat merged commit 5d291f8 into makeecat:main Oct 29, 2024
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants