Re: [vtkusers] vtkOpenGLVolumeTextureMapper3D/vtkVolumeTextureMapper3D and MIP

Aldredo Gourbish the.answer3 at libertysurf.fr
Wed Jul 25 07:29:44 EDT 2007


Oh thank's Eugen ! It is so obvious... but I'm not still awaked today ! lol
So it works good and I don't understand why this blending mode is not implemented in VTK.

Bye !

Gourbish

---------- Initial Header -----------

From      : eudyck at web.de
To          : "Aldredo Gourbish" <the.answer3 at libertysurf.fr>, vtkusers <vtkusers at vtk.org>
Cc          : 
Date      : Wed, 25 Jul 2007 12:41:16 +0200
Subject : Re: [vtkusers] vtkOpenGLVolumeTextureMapper3D/vtkVolumeTextureMapper3D and MIP

Hi,

you have to asure that your new class is used!
If you create your mapper like:

vtkVolumeTextureMapper3D* mapper = vtkVolumeTextureMapper3D::New()

then "mapper" will be of the derived type "vtkOpenGLVolumeTextureMapper3D"  
because of the vtkVolumeRenderingFactory, which chooses a suitable type  
according to your system. In order to get an object of your derived type  
you would have to modify vtkVolumeRenderingFactory to know your derived  
type and create an object with its type instead...

The easier way is to use your mapper directly like:

vtkMyDerivedOpenGLTextureMapper3D* mapper =  
vtkMyDerivedOpenGLTextureMapper3D::New()


At least this works for me...

A code chunk how you instantiate your mapper would help...

Bye,
Eugen




On Wed, 25 Jul 2007 11:43:37 +0200, Aldredo Gourbish  
<the.answer3 at libertysurf.fr> wrote:

> Hello everybody,
>
> I have two question about these classes : vtkOpenGLVolumeTextureMapper3D  
> and vtkVolumeTextureMapper3D.
> 1) Why there is no function to render using BlendModeToMaximumIntensity  
> ? Because it is very simple with OpenGL to do that...
> 2) How is it possible to add this functionality to my project without  
> modifying the VTK source code ? In fact I tried to create a class  
> inheriting from vtkOpenGLVolumeTextureMapper3D, and I reimplemented the  
> "RenderNV()", "RenderFP()" and "Render()" functions with the good  
> changes. But the result is bad : the used rendering function isn't the  
> one I reimplemented. So how can I do that ?
>
> Thank's for the answers... ;-)
>
> Have a good day.
>
> Gourbish

------------------------ ALICE C'EST ENCORE MIEUX AVEC CANAL+ LE BOUQUET ! ---------------
Découvrez vite l'offre exclusive ALICEBOX et CANAL+ LE BOUQUET, en cliquant ici http://alicebox.fr
Soumis à conditions.





More information about the vtkusers mailing list