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

Feature request: Rendering without lighting and shading model #3

Open
Yumin-Sun-00 opened this issue Oct 12, 2020 · 1 comment
Open

Comments

@Yumin-Sun-00
Copy link

Yumin-Sun-00 commented Oct 12, 2020

Hi,

thanks a lot to your work on this repository. And thanks a lot for the detailed documentation.

Recently I want to project curvature from 3D geometry to an image. Just like to generate a 2D normal image from 3D, a curvature is just a physical value, it should not be affected from lightning or shading at all. Almost all the render engines have controls about lightning model and shading, but they don't give a simple instruction how to shut this down. Does your rasterizer have this simple but useful function? Could you give me some instruction how to play around with it? I am very appreciated to your help.

@mtrebi
Copy link
Owner

mtrebi commented Oct 13, 2020

Hey,

Currently there rasterizer doesn't have such functionality but it shouldn't be too hard to add it. Basically, what you want to is replace the function which the pixel its color. Right now, it takes into account the lights in the scene as well as the material properties. In your case, that function would just compute the curvature value and assign it to the pixel. For this, you may needto modify lines 40-45 in https://github.com/mtrebi/Rasterizer/blob/master/src/ForwardRasterizer.cpp

Hope this helps.

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

No branches or pull requests

2 participants