Actor always shows same face

Hi all,

I use a imageData to create a volume, but when I try to rotate it always show the same face.

Moment 1. When the app render show this


Moment 2. I rotate to see the other layers

Moment 3. Again shows the first layers.

Thanks in advance for your help.

1 Like

the face you mean is surface? When you change the camera parameters, you can only see the surface of the object from different positions or angles, but you can only see the surface.

When I say a face is not the surface, I mean one side of the volume like in a cube which has six square faces… I always see the same side.

try to change camera’s parameters? :thinking:

I checked and changed camera parameters, but still no good result.

Do you want to see different sections? Because your picture already shows surfaces with different angles.

Maybe my pictures are not good enough to explain my problem… next picture shows three views from the same 3D objects as it should work, previews images shows what I get now.

Moment 1 and 2, works perfect. Moment 3, when I want to see the opposed side of the “cube” is the problem. In my current work, does not matter how much I turn around the actors I ended with the layer 1 always on top.

Thanks for your help.

would you like show some code?
Because in my opinion, if you finish viewing the first two views, the third view is only about setting the camera’s horizontal swing angle, if you set the camera parameters yourself. For your reference only

Unfortunately, I test different things and if then did not work I delete them. I look for the options inside current examples online where 3D volumes are turning well (usually cubes without or no mayor settings change on camera).

After read your comment, I try camera.setUseHorizontalViewAngle(true/false); without any result for both options.

Have you try use camera->Elevation(180)?
below is the camera model in vtk.
vtkcamera01
vtkcamera02

I have a new approach of this problem…
Front view. This one shows three different layers, as expected.

Rear view. New idea: It “hides” third layer (dark purple) and shows the second layer (Purple) transparent because there is a priority to show the first layer (Red)

There is a way to give all of them the same priority or something like that? (Each layer is the result of drawing one actor).

Thanks for your comments.

1 Like

Are you adding the volumes to multiple renderers, each with its own layer? Then they are drawn in “order” of their layer number.

Try to add all your volumes to a single renderer. I think you probably also need to enable depth peeling for volumes via vtkRenderer::UseDepthPeelingForVolumesOn