[vtkusers] Transparency Question
De Boer Ingo
I.deBoer at polytec.de
Tue Apr 15 09:25:12 EDT 2003
Hi,
I have a question about transparency. I have a texture which
is color coded with a scalar. I set the transparency with the
actor, like m_pvtkActorData->GetProperty()->SetOpacity(m_fTransparency);
This sets the transparency for the texture aswell as for the color
scalars. How can I make the transparency of the texture 100% and
only the colors transparent to let's say 50% ?
here is a code snip:
m_pvtkPolydata->GetPointData()->SetTCoords(tCoords);
m_pvtkPolydata->SetPoints(m_pvtkPoints);
m_pvtkPolydata->SetPolys(polygons);
m_pvtkPolydata->GetPointData()->SetScalars(scalars);
m_pvtkPolyDataMapper->SetInput(m_pvtkPolydata);
m_pvtkPolyDataMapper->SetScalarRange(0,m_lPoints);
m_pvtkActorData->SetMapper(m_pvtkPolyDataMapper);
m_pvtkActorData->SetTexture(m_pvtkTexture);
m_pvtkActorData->GetProperty()->SetOpacity(m_fTransparency);
greets
Ingo
More information about the vtkusers
mailing list