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

Implement EnvironmentCamera #69

wahn opened this Issue Nov 21, 2018 · 2 comments


None yet
1 participant
Copy link

wahn commented Nov 21, 2018

I asked on the PBRT mailing list (

Are there any example .pbrt files for EnvironmentCamera and/or RealisticCamera? I couldn't find any example scenes using them ...

And Haarm-Pieter Duiker replied with:

Finding the one example for the EnvironmentCamera:

> rg environment
27:Camera "environment"

And the resulting image (rendered with the C++ version of PBRT):


Now, lets add the Rust code to render the same image ...

@wahn wahn self-assigned this Nov 21, 2018

@wahn wahn added the enhancement label Nov 21, 2018


This comment has been minimized.

Copy link
Owner Author

wahn commented Nov 21, 2018

Here an image rendered by the Rust version (after fixing some parser problems - see commit 3a3eefd):


The environment camera was replaced by a perspective camera:

> git diff
diff --git a/maya/renderData/pbrt_feature_demo_camera_environment.pbrt b/maya/renderData/pbrt_feature_demo_camera_environment.pbrt
index 7d4182f..7ec17de 100644
--- a/maya/renderData/pbrt_feature_demo_camera_environment.pbrt
+++ b/maya/renderData/pbrt_feature_demo_camera_environment.pbrt
@@ -24,7 +24,7 @@ Accelerator "bvh"
 # Camera begin
 Scale -1 1 1
 LookAt 0.000000 4.250000 -45.000000 -0.000000 -0.177129 -2.878684 -0.000000 0.994522 0.104528
-Camera "environment"
+Camera "perspective"
        "float screenwindow" [-1.0 1.0 -0.5 0.5]
 # Camera end

We had to use the Rust version with OpenEXR support, but everything is prepared now to work on the EnvironmentCamera ...


This comment has been minimized.

Copy link
Owner Author

wahn commented Nov 21, 2018

After commit 1ac0ef5 the Rust version (with OpenEXR support) renders fine:


@wahn wahn closed this Nov 21, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment