Problem with shadows

classic Classic list List threaded Threaded
7 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Problem with shadows

abcd efgh
Hello,

I am new to vtk. I have a 3D polydata, I cut it using vtkClipPolydata.
Now there are some shadow kind of thing, I have called functions to turn off shadows
as well as backface culling as off. But still shadow kind of effect remains and the Poly data is sometimes dark due to this.

Thanks

_______________________________________________
Powered by www.kitware.com

Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the VTK FAQ at: http://www.vtk.org/Wiki/VTK_FAQ

Search the list archives at: http://markmail.org/search/?q=vtkusers

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/vtkusers
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Problem with shadows

David Gobbi
Clipping a data set adds scalars to the data set. These scalars are probably causing the strange coloring that you are seeing. You can tell the mapper to ignore the scalars, and use the vtkProperty color instead:

mapper->ScalarVisibilityOff();

 - David

On Sun, Jul 16, 2017 at 2:15 AM, abcd efgh <[hidden email]> wrote:
Hello,

I am new to vtk. I have a 3D polydata, I cut it using vtkClipPolydata.
Now there are some shadow kind of thing, I have called functions to turn off shadows
as well as backface culling as off. But still shadow kind of effect remains and the Poly data is sometimes dark due to this.

Thanks


_______________________________________________
Powered by www.kitware.com

Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the VTK FAQ at: http://www.vtk.org/Wiki/VTK_FAQ

Search the list archives at: http://markmail.org/search/?q=vtkusers

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/vtkusers
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Problem with shadows

abcd efgh
Thanks, 
if  I turn off scalars then I see only white color, by the way even after that I see the shadow effects, how can I turn off the shadows in the scene completely.
I think the problem is with respect to shadows.

Thanks again.

On Sun, Jul 16, 2017 at 5:21 AM, David Gobbi <[hidden email]> wrote:
Clipping a data set adds scalars to the data set. These scalars are probably causing the strange coloring that you are seeing. You can tell the mapper to ignore the scalars, and use the vtkProperty color instead:

mapper->ScalarVisibilityOff();

 - David

On Sun, Jul 16, 2017 at 2:15 AM, abcd efgh <[hidden email]> wrote:
Hello,

I am new to vtk. I have a 3D polydata, I cut it using vtkClipPolydata.
Now there are some shadow kind of thing, I have called functions to turn off shadows
as well as backface culling as off. But still shadow kind of effect remains and the Poly data is sometimes dark due to this.

Thanks



_______________________________________________
Powered by www.kitware.com

Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the VTK FAQ at: http://www.vtk.org/Wiki/VTK_FAQ

Search the list archives at: http://markmail.org/search/?q=vtkusers

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/vtkusers
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Problem with shadows

David Gobbi
If it isn't the scalars, then it is probably the normals.  If the data has bad normals, then lighting of the data will be incorrect.

You can try generating new normals for the data with vtkPolyDataNormals.  Make sure that you read the documentation for this class, it has lots of options.

 - David


On Mon, Jul 17, 2017 at 12:31 PM, abcd efgh <[hidden email]> wrote:
Thanks, 
if  I turn off scalars then I see only white color, by the way even after that I see the shadow effects, how can I turn off the shadows in the scene completely.
I think the problem is with respect to shadows.

Thanks again.

On Sun, Jul 16, 2017 at 5:21 AM, David Gobbi <[hidden email]> wrote:
Clipping a data set adds scalars to the data set. These scalars are probably causing the strange coloring that you are seeing. You can tell the mapper to ignore the scalars, and use the vtkProperty color instead:

mapper->ScalarVisibilityOff();

 - David

On Sun, Jul 16, 2017 at 2:15 AM, abcd efgh <[hidden email]> wrote:
Hello,

I am new to vtk. I have a 3D polydata, I cut it using vtkClipPolydata.
Now there are some shadow kind of thing, I have called functions to turn off shadows
as well as backface culling as off. But still shadow kind of effect remains and the Poly data is sometimes dark due to this.

Thanks




_______________________________________________
Powered by www.kitware.com

Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the VTK FAQ at: http://www.vtk.org/Wiki/VTK_FAQ

Search the list archives at: http://markmail.org/search/?q=vtkusers

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/vtkusers
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Problem with shadows

abcd efgh
previously forgot to add VTKusers list.. forwarding same mail.

Hi,

Thank you for the input. I have tried with new Normals, its the same.
I dont think there is an issue with normals. When Poly data appears on screen, it will be in darkness(shadow).
I need to turn off every shadow in the renderer. I am using Renderer->UseShadowsOff(), still no use.

Please someone guide me to turn off all shadows in the scene. Just like how the Cube source appears in the renderer.

Thanks

On Thu, Jul 20, 2017 at 3:52 PM, abcd efgh <[hidden email]> wrote:
Hi,

Thank you for the input. I have tried with new Normals, its the same.
I dont think there is an issue with normals. When Poly data appears on screen, it will be in darkness(shadow).
I need to turn off every shadow in the renderer. I am using Renderer->UseShadowsOff(), still no use.

Please someone guide me to turn off all shadows in the scene. Just like how the Cube source appears in the renderer.

Thanks

On Mon, Jul 17, 2017 at 12:06 PM, David Gobbi <[hidden email]> wrote:
If it isn't the scalars, then it is probably the normals.  If the data has bad normals, then lighting of the data will be incorrect.

You can try generating new normals for the data with vtkPolyDataNormals.  Make sure that you read the documentation for this class, it has lots of options.

 - David


On Mon, Jul 17, 2017 at 12:31 PM, abcd efgh <[hidden email]> wrote:
Thanks, 
if  I turn off scalars then I see only white color, by the way even after that I see the shadow effects, how can I turn off the shadows in the scene completely.
I think the problem is with respect to shadows.

Thanks again.

On Sun, Jul 16, 2017 at 5:21 AM, David Gobbi <[hidden email]> wrote:
Clipping a data set adds scalars to the data set. These scalars are probably causing the strange coloring that you are seeing. You can tell the mapper to ignore the scalars, and use the vtkProperty color instead:

mapper->ScalarVisibilityOff();

 - David

On Sun, Jul 16, 2017 at 2:15 AM, abcd efgh <[hidden email]> wrote:
Hello,

I am new to vtk. I have a 3D polydata, I cut it using vtkClipPolydata.
Now there are some shadow kind of thing, I have called functions to turn off shadows
as well as backface culling as off. But still shadow kind of effect remains and the Poly data is sometimes dark due to this.

Thanks






_______________________________________________
Powered by www.kitware.com

Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the VTK FAQ at: http://www.vtk.org/Wiki/VTK_FAQ

Search the list archives at: http://markmail.org/search/?q=vtkusers

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/vtkusers
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Problem with shadows

David Gobbi
Can you attach a screenshot?  My own experience with VTK tells me that it is very, very unlikely that you are seeing shadows.  Whenever I see dark areas in VTK rendering, it is almost always due to the scalars, the normals, or the winding of the polydata.  It could be that some of your polygons are wound incorrectly.

On Fri, Jul 21, 2017 at 12:37 PM, abcd efgh <[hidden email]> wrote:
previously forgot to add VTKusers list.. forwarding same mail.

Hi,

Thank you for the input. I have tried with new Normals, its the same.
I dont think there is an issue with normals. When Poly data appears on screen, it will be in darkness(shadow).
I need to turn off every shadow in the renderer. I am using Renderer->UseShadowsOff(), still no use.

Please someone guide me to turn off all shadows in the scene. Just like how the Cube source appears in the renderer.

Thanks

On Thu, Jul 20, 2017 at 3:52 PM, abcd efgh <[hidden email]> wrote:
Hi,

Thank you for the input. I have tried with new Normals, its the same.
I dont think there is an issue with normals. When Poly data appears on screen, it will be in darkness(shadow).
I need to turn off every shadow in the renderer. I am using Renderer->UseShadowsOff(), still no use.

Please someone guide me to turn off all shadows in the scene. Just like how the Cube source appears in the renderer.

Thanks

On Mon, Jul 17, 2017 at 12:06 PM, David Gobbi <[hidden email]> wrote:
If it isn't the scalars, then it is probably the normals.  If the data has bad normals, then lighting of the data will be incorrect.

You can try generating new normals for the data with vtkPolyDataNormals.  Make sure that you read the documentation for this class, it has lots of options.

 - David


On Mon, Jul 17, 2017 at 12:31 PM, abcd efgh <[hidden email]> wrote:
Thanks, 
if  I turn off scalars then I see only white color, by the way even after that I see the shadow effects, how can I turn off the shadows in the scene completely.
I think the problem is with respect to shadows.

Thanks again.

On Sun, Jul 16, 2017 at 5:21 AM, David Gobbi <[hidden email]> wrote:
Clipping a data set adds scalars to the data set. These scalars are probably causing the strange coloring that you are seeing. You can tell the mapper to ignore the scalars, and use the vtkProperty color instead:

mapper->ScalarVisibilityOff();

 - David

On Sun, Jul 16, 2017 at 2:15 AM, abcd efgh <[hidden email]> wrote:
Hello,

I am new to vtk. I have a 3D polydata, I cut it using vtkClipPolydata.
Now there are some shadow kind of thing, I have called functions to turn off shadows
as well as backface culling as off. But still shadow kind of effect remains and the Poly data is sometimes dark due to this.

Thanks


_______________________________________________
Powered by www.kitware.com

Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the VTK FAQ at: http://www.vtk.org/Wiki/VTK_FAQ

Search the list archives at: http://markmail.org/search/?q=vtkusers

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/vtkusers
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Problem with shadows

abcd efgh
Hi,

Due to some reason I am not able to attach screenshot.
But if I rotate and change the angle for the Polydata by interacting with it, I can see colors correctly, only at certain angles the colors are dark the way you see for shadows. May be my understanding is wrong, meanwhile I will try to work with Normals ,Scalars. But if there is a way to turn off every shadow or add lights to all viewing angles it would be great.

Thanks



On Fri, Jul 21, 2017 at 12:12 PM, David Gobbi <[hidden email]> wrote:
Can you attach a screenshot?  My own experience with VTK tells me that it is very, very unlikely that you are seeing shadows.  Whenever I see dark areas in VTK rendering, it is almost always due to the scalars, the normals, or the winding of the polydata.  It could be that some of your polygons are wound incorrectly.


On Fri, Jul 21, 2017 at 12:37 PM, abcd efgh <[hidden email]> wrote:
previously forgot to add VTKusers list.. forwarding same mail.

Hi,

Thank you for the input. I have tried with new Normals, its the same.
I dont think there is an issue with normals. When Poly data appears on screen, it will be in darkness(shadow).
I need to turn off every shadow in the renderer. I am using Renderer->UseShadowsOff(), still no use.

Please someone guide me to turn off all shadows in the scene. Just like how the Cube source appears in the renderer.

Thanks

On Thu, Jul 20, 2017 at 3:52 PM, abcd efgh <[hidden email]> wrote:
Hi,

Thank you for the input. I have tried with new Normals, its the same.
I dont think there is an issue with normals. When Poly data appears on screen, it will be in darkness(shadow).
I need to turn off every shadow in the renderer. I am using Renderer->UseShadowsOff(), still no use.

Please someone guide me to turn off all shadows in the scene. Just like how the Cube source appears in the renderer.

Thanks

On Mon, Jul 17, 2017 at 12:06 PM, David Gobbi <[hidden email]> wrote:
If it isn't the scalars, then it is probably the normals.  If the data has bad normals, then lighting of the data will be incorrect.

You can try generating new normals for the data with vtkPolyDataNormals.  Make sure that you read the documentation for this class, it has lots of options.

 - David


On Mon, Jul 17, 2017 at 12:31 PM, abcd efgh <[hidden email]> wrote:
Thanks, 
if  I turn off scalars then I see only white color, by the way even after that I see the shadow effects, how can I turn off the shadows in the scene completely.
I think the problem is with respect to shadows.

Thanks again.

On Sun, Jul 16, 2017 at 5:21 AM, David Gobbi <[hidden email]> wrote:
Clipping a data set adds scalars to the data set. These scalars are probably causing the strange coloring that you are seeing. You can tell the mapper to ignore the scalars, and use the vtkProperty color instead:

mapper->ScalarVisibilityOff();

 - David

On Sun, Jul 16, 2017 at 2:15 AM, abcd efgh <[hidden email]> wrote:
Hello,

I am new to vtk. I have a 3D polydata, I cut it using vtkClipPolydata.
Now there are some shadow kind of thing, I have called functions to turn off shadows
as well as backface culling as off. But still shadow kind of effect remains and the Poly data is sometimes dark due to this.

Thanks



_______________________________________________
Powered by www.kitware.com

Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the VTK FAQ at: http://www.vtk.org/Wiki/VTK_FAQ

Search the list archives at: http://markmail.org/search/?q=vtkusers

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/vtkusers
Loading...