Page 1 of 2

Camera lens sensor setup?

Posted: Thu Apr 11, 2019 3:04 pm
by Fox
I have little trouble with how to do camera lens material, that would cast only very slight hologram/reflection shape of camera sensor on the glass surfaces.

Seems very hard to get light to go from environment -> through lenses -> hit the sensor -> reflect and refract back out to environment -> to the render camera which is not directly visible to the mesh sensor.

Simple clear glass works the fastest, only rough glass is insanely slow, and mix of clear and rough has some brightness issues.

I set the sensor to mesh emitter (0.3W, gain 1, lumen 1).

Single lens
Single Lens.png
Single lens with clear glass:
Single Lens With Clear Glass.jpg
Single lens with rough glass:
Single Lens With Rough Glass.jpg
Single lens with mix glass:
Single Lens With Mix Glass.jpg
The brightness gets stronger the more i duplicate lens elements, i test with 3 lenses:
3 Lenses With Rough Glass.jpg
3 lenses with clear glass:
The attachment 3 Lenses With Clear Glass.jpg is no longer available
3 lenses with rough glass
3 Lenses With Mix Glass.jpg
3 lenses with mix glass
3 Lenses With Clear Glass.jpg
The blend file:
3 Lenses.png

Re: Camera lens sensor setup?

Posted: Thu Apr 11, 2019 5:15 pm
by Fox
I use pure rough glass and this seems to work.
Now i must figure out how to balance environment reflections against sensor reflections without blowing color values out :?: :roll: :?:
Sun sky is pretty strong.

Glass Rough 0.0015, Reflection 0.0001, Transmission 1
Rough0.0015 Reflection0.0001.jpg

Re: Camera lens sensor setup?

Posted: Thu Apr 11, 2019 5:17 pm
by Sharlybg
How do the real life reference of what you want to achieve look like ?

Re: Camera lens sensor setup?

Posted: Thu Apr 11, 2019 6:04 pm
by Fox
Sharlybg wrote: Thu Apr 11, 2019 5:17 pm How do the real life reference of what you want to achieve look like ?
It doesn't really matter, some colorful reflections with no thin film.
If you are lens aperture wide open and shutter curtain open, then there is little color when you shine light in, can't find related image.

Image

Re: Camera lens sensor setup?

Posted: Sun Apr 14, 2019 2:40 pm
by Fox
Mixing glass and rough glass for lens elements was bad idea.
The overnight render was all blown out, the BlendLuxCore recommended clamping value of e+36 or was it e+38.

The pure rough glass seems very sensitive to too small gaps (0.0001m) between lens elements.
Looks like LuxCore ui supports roughness as low as 1e-9, but even this was too slow.

Only option for now is clear glass.

Re: Camera lens sensor setup?

Posted: Sun Apr 14, 2019 3:09 pm
by Fox
The mix material should work when i use the mix factor with new math option "greater than" 0.5 via Blender noise texture.
So it only selects rough glass or only clear glass (using mix factor 1 or 0).

But Blender tells "unknown texture type greaterthan"

Re: Camera lens sensor setup?

Posted: Sun Apr 14, 2019 3:18 pm
by B.Y.O.B.
Fox wrote: Sun Apr 14, 2019 3:09 pm But Blender tells "unknown texture type greaterthan"
You have probably only updated the Blender addon, but not the LuxCore binaries in the "bin" folder of the addon.
Follow the steps here: viewtopic.php?f=9&t=736#p9704

Re: Camera lens sensor setup?

Posted: Sun Apr 14, 2019 3:52 pm
by Fox
B.Y.O.B. wrote: Sun Apr 14, 2019 3:18 pm
Fox wrote: Sun Apr 14, 2019 3:09 pm But Blender tells "unknown texture type greaterthan"
You have probably only updated the Blender addon, but not the LuxCore binaries in the "bin" folder of the addon.
Follow the steps here: viewtopic.php?f=9&t=736#p9704
I did full clean install, it works now.

Re: Camera lens sensor setup?

Posted: Sun Apr 14, 2019 4:18 pm
by Fox
Indeed, this mixing factor works. No blown out render. :)
And i can weight around between rough and clear glass in Blender noise brightness tab.
Mix Factor That Works.png

Re: Camera lens sensor setup?

Posted: Sun Apr 14, 2019 7:40 pm
by B.Y.O.B.