[vtkusers] change contrast in volume object (it's too dark)
Lisa Avila
lisa.avila at kitware.com
Fri Sep 2 16:36:14 EDT 2005
Hi Mark,
Yes - you do need a color function and you should probably set it to solid
white to achieve the effect you are looking for. You probably have a gray
ramp color function. For both maximize methods the opacity transfer
function plays a role - in the maximize scalar value method the maximum
scalar value is found, then this scalar value is passed through the opacity
and color function to determine the final pixel value. In the maximize
opacity method, each scalar value is passed through the opacity function
and the one with the maximum opacity is selected. This would allow you to,
for example, actually do minimum opacity (with an inverse opacity ramp)
You can render the volume into an offscreen image, capture that, display
that as an image and use W/L operations on it. This is the same as
adjusting the opacity transfer function when in maximize scalar value mode,
but not when in maximize opacity mode.
Lisa
At 11:55 AM 9/2/2005, Mark Wyszomierski wrote:
>Hi Lisa,
>
>First I had my MIP function using SetMaximizeMethodToScalarValue(), and it
>looks like setting the opacity transfer function had no effect. If I
>switch to SetMaximizeMethodToOpacity(), then the transfer function does
>have an effect, though it is a strange effect. The areas of my organ
>dataset that have the greatest intensity will appear as bright white both
>in the 2D slices, and in the MIP rendering if maximize scalars is on
>(areas like veins/artieries etc). Now that I set maximize to use opacity,
>and adjusted the ramp, yes I can have only those really bright areas stand
>out, but since their opacity is high I guess they are really dark grey
>now! It almost looks like an inverted MIP. Should I specify a color
>mapping now too? My input is one component unisigned short.
>
>The window and leveling for the image viewer classes is very interactive
>with good response times. If I were to try the same thing binding the
>opacity ramp to be interactive for this volume, I can get a refresh maybe
>once every 1 - 2 seconds per change. That's why I am still wondering about
>hooking into the output of the rendered volume somehow, so window / level
>would only be done on the output image instead of every voxel in the
>volume, then resampling etc, does this sound feasible/possible?
>
>I posted the relevant lines for my MIP below in case I'm doing something
>wrong:
>
>OpacityTransferFunction->AddPoint(0, 0);
>OpacityTransferFunction->AddPoint(0, 300.0);
>
>Volume->SetProperty(VolumeProperty);
>CompositeFunctionMIP->SetMaximizeMethodToOpacity();
>VolumeMapper->SetVolumeRayCastFunction(CompositeFunctionMIP);
>VolumeMapper->SetInput((*this->pImageData));
>Volume->SetMapper(VolumeMapper);
>
>Thank you!
>
>On 9/2/05, Lisa Avila
><<mailto:lisa.avila at kitware.com>lisa.avila at kitware.com> wrote:
>Hello,
>
>You would apply the window / leve directly to the opacity transfer function
>- just adjust the start / end points of the ramp. If it is too dark, lower
>the point at which the opacity becomes 1.
>
>Lisa
>
>At 09:03 AM 9/2/2005, powerhouseofexcellence wrote:
> >Hi all,
> >
> >I have the VTK users guide book (version 4.4) and was reading to see how
> >to edit the diffuse/ambient etc to make my volumes look brighter (problem
> >from an earlier post). But I'm doing a MIP, and the book says that these
> >parameters and the ShadingOn() are ignored by MIP rendering. So my MIP
> >still looks dark, any way to increase their brightness? I am using the
> >scalar value as the maximize function.
> >
> >I was hoping that since the volume data is being passed to the render
> >window somewhere, maybe there would be a chance to set the output of the
> >volume renderer into a window level filter which is then passed along to
> >the render window. So only the final output is window/leveled and this
> >could be a quick operation. Is this possible?
> >
> >Thanks
> >_______________________________________________
> >This is the private VTK discussion list.
> >Please keep messages on-topic. Check the FAQ at:
> ><http://www.vtk.org/Wiki/VTK_FAQ>http://www.vtk.org/Wiki/VTK_FAQ
> >Follow this link to subscribe/unsubscribe:
> ><http://www.vtk.org/mailman/listinfo/vtkusers>http://www.vtk.org/mailman/
> listinfo/vtkusers
>
>
>_______________________________________________
>This is the private VTK discussion list.
>Please keep messages on-topic. Check the FAQ at:
><http://www.vtk.org/Wiki/VTK_FAQ>http://www.vtk.org/Wiki/VTK_FAQ
>Follow this link to subscribe/unsubscribe:
><http://www.vtk.org/mailman/listinfo/vtkusers>http://www.vtk.org/mailman/listinfo/vtkusers
>
>
>_______________________________________________
>This is the private VTK discussion list.
>Please keep messages on-topic. Check the FAQ at:
>http://www.vtk.org/Wiki/VTK_FAQ
>Follow this link to subscribe/unsubscribe:
>http://www.vtk.org/mailman/listinfo/vtkusers
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20050902/2dc115b6/attachment.htm>
More information about the vtkusers
mailing list