Skip to content

added property cameraSpaceLightingDef to DirectionalLight#4483

Open
abmajith wants to merge 3 commits intosilx-kit:mainfrom
abmajith:cameraSpaceLighting
Open

added property cameraSpaceLightingDef to DirectionalLight#4483
abmajith wants to merge 3 commits intosilx-kit:mainfrom
abmajith:cameraSpaceLighting

Conversation

@abmajith
Copy link
Contributor

This property to use in sphere primitive to make the lighting angle constant from view point

@t20100 t20100 self-requested a review March 3, 2026 14:06
@t20100 t20100 added this to the 3.0.0 milestone Mar 3, 2026
@t20100
Copy link
Member

t20100 commented Mar 3, 2026

This breaks the lighting of some items.

With python examples/plot3dSceneWindow.py, no items should be black:

Screenshot from 2026-03-03 15-10-11

@t20100
Copy link
Member

t20100 commented Mar 3, 2026

This is the cause of the lighting issue with spheres:

/*Lighting performed in NDC*/
/*TODO update this when lighting changed*/
//XXX vec3 position = vPosition + vViewRadius * normal;
gl_FragColor = $lightingCall(vColor, vPosition, normal);

@t20100
Copy link
Member

t20100 commented Mar 3, 2026

I made PR #4491 to fix this issue

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