DirectionalFromCamera with reversed axis SurfaceGridSeries3D

A forum dedicated to WinForms version of LightningChart Ultimate.

Moderator: Queue Moderators

Post Reply
Greg9504
Posts: 38
Joined: Fri Dec 06, 2013 4:51 pm

DirectionalFromCamera with reversed axis SurfaceGridSeries3D

Post by Greg9504 » Wed Dec 18, 2013 4:44 pm

When I set the chart lighting to DirectionalFromCamera (m_chart.View3D.SetPredefinedLightingScheme(LightingScheme.DirectionalFromCamera);) with a chart that has some of it's axis reversed the lighting isn't correct. It seems to be coming from the bottom of the SurfaceGridSeries3D. I know you mentioned that if I reversed the axis I would have to modify the lighting, however I figured the built in lighting schemes would handle this automatically. Is there a work around?

See the SurfaceGrid3DTest project in the solution posted in my previous post:
http://www.arction.com/forum/download/file.php?id=137

Thanks
Greg.

User avatar
ArctionPasi
Posts: 1367
Joined: Tue Mar 26, 2013 10:57 pm
Location: Finland
Contact:

Re: DirectionalFromCamera with reversed axis SurfaceGridSeri

Post by ArctionPasi » Thu Dec 19, 2013 9:36 am

The SurfaceGridSeries3D uses the same rendering data construction and lighting than SurfaceMeshSeries3D. That means, the surface can bend to any angle or any shape, and there's no "up" or "down" concept.

Only the other side of the surface can be lit correctly. LC makes the 3D rendering data in order of columns and rows starting from 0 indices. The light normals are computed from this order. If axis gets reversed the normals go to opposite direction. To get the correcting lighting, change surface.LightedSurface property to flip the light normals to opposite side, and to make the lighting correct.
LightningChart Support Team, PT

Post Reply