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

How to pass lightmap data between passes #5

Closed
braddabug opened this issue Mar 9, 2017 · 2 comments
Closed

How to pass lightmap data between passes #5

braddabug opened this issue Mar 9, 2017 · 2 comments
Labels

Comments

@braddabug
Copy link

What's the correct way to transfer the lighting results of Pass N to Pass N+1?

From looking at the sample, it seems like the results of each pass is converted to a plain old texture, and then the next pass uses that texture as emissive data. But that seems wrong. It seems like you wouldn't want to convert the HDR lightmap info to an actual texture until the very end of all your passes/bounces. You'd want to keep the original floating point 32-bits-per-channel array you pass to lmSetTargetLightmap() around for use in the subsequent pass, rather than rely on a clamped/exposed/processed 8-bits-per-channel texture.

So am I just doing it wrong?

@ands
Copy link
Owner

ands commented Mar 9, 2017

You can just use a floating point HDR texture format for rendering. That's what I do :)

@braddabug
Copy link
Author

Oh, yep, that works.

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

No branches or pull requests

2 participants