[vtkusers] Re: volume rendering using 2D Textures

jose manjon jmanjon at fis.upv.es
Fri Jul 20 06:23:48 EDT 2001


Hi all,

anyone knows how to use 2D textures for volume rendering
I have done ray casting volume rendering but is very slow
and I need to speed up it.

a sample code should be perfect ...

jose


vtkusers-admin at public.kitware.com wrote:

> Send vtkusers mailing list submissions to
>         vtkusers at public.kitware.com
>
> To subscribe or unsubscribe via the web, visit
>         http://public.kitware.com/mailman/listinfo/vtkusers
> or, via email, send a message with subject or body 'help' to
>         vtkusers-request at public.kitware.com
> You can reach the person managing the list at
>         vtkusers-admin at public.kitware.com
>
> When replying, please edit your Subject line so it is more specific than
> "Re: Contents of vtkusers digest..."
>
> Today's Topics:
>
>   1. Re: VTK MPI with SSH Display problem (Juerg Tschirren)
>   2. Re: VTK MPI with SSH Display problem (Tony Lavoie)
>   3. execution error? (qakz)
>   4. Re: VTK MPI with SSH Display problem (Simon Warfield)
>   5. Re: vtkusers digest, Vol 1 #486 - 3 msgs (Sivashanmugaraman Sugavanam)
>   6. vrml 1 to vrml 2 translator (David E. Jones)
>   7. Re: vtk w/ CAVElib and clipping (John Biddiscombe)
>   8. dbx dumps core on Forte Developer 6 (Johan de Jong)
>   9. Scalar Range problem (Matthieu Ferrant)
>   10. Re: Inconsistent rendering times (John Biddiscombe)
>   11. Re: Scalar Range problem (Matthieu Ferrant)
>   12. vtkdll.lib not produced with nmake on WNT4.0/VC++6.0 (=?iso-8859-1?q?Herbert=20Muthsam?=)
>   13. vtkXYPlotActor C++ Examples (leung at arlut.utexas.edu)
>   14. compiling on IRIX machine (Ziji Wu)
>
> --__--__--
>
> Message: 1
> Date: Wed, 18 Jul 2001 10:17:38 -0500 (CDT)
> From: Juerg Tschirren <juerg-tschirren at uiowa.edu>
> To: Simon Winberg <swinberg at utsi.edu>
> cc: <vtkusers at public.kitware.com>
> Subject: Re: [vtkusers] VTK MPI with SSH Display problem
>
> I never used the MPI option with VTK, but I do run VTK on a remote machine
> through an SSH connection. It looks like you didn't do one or both of the
> following two steps:
>
>   If your application runs on machine A and wants to display something on
> machine B, then you have to:
>
>   1. on machine A type
>
>      export DISPLAY=B:0.0
>
>      assuming you are using the Bash shell. B has to be the valid
>      network name of machine B, or its IP address.
>
>   2. on machine B type
>
>      xhost + A
>
>      in order to allow machine A to do an X connection to B. Again, A
>      hast to be a valid network name (resolvable by DNS) or an IP address.
>
> Hope that helps
>
> Juerg
>
> On Wed, 18 Jul 2001, Simon Winberg wrote:
>
> > Hi all,
> >
> > I've got VTK compiled with the MPI option, and am testing the
> > ParallelIso program. I'm using ssh with the ssh-agent to connect to the
> > other PC's.
> >
> > When I execute the program (using the lamexec command) the
> > application runs for a few seconds and then crashes (see output
> > below). I can run the application fine on one PC simulating multiple
> > processors, but when I add any of the other PCs in my cluster I get this
> > error:
> >
> > --------
> > $ lamexec -np 3 ParallelIso
> >
> > Update 3000 took 0.531551 seconds to produce 68 triangles
> > Update 1750 took 0.828511 seconds to produce 88310 triangles
> > Update 500 took 0.738054 seconds to produce 64982 triangles
> > Update 3000 took 2.94585 seconds to produce 68 triangles
> > ERROR: In vtkXRenderWindow.cxx, line 176
> > vtkMesaRenderWindow (0x8235550): bad X server connection.
> >
> > ERROR: In vtkMesaRenderWindow.cxx, line 122
> > vtkMesaRenderWindow (0x8235550): bad X server connection.
> > --------
> >
> > I have tried the other example programs with similar results.
> > Could this be a problem with how ssh handles exporting of the display?
> >
> > Any ideas?
> >
> >
> >
> >
> > _______________________________________________
> > This is the private VTK discussion list.
> > Please keep messages on-topic. Check the FAQ at: <http://public.kitware.com/cgi-bin/vtkfaq>
> > Follow this link to subscribe/unsubscribe:
> > http://public.kitware.com/mailman/listinfo/vtkusers
> >
>
> --__--__--
>
> Message: 2
> Date: Wed, 18 Jul 2001 11:15:18 -0500 (CDT)
> From: Tony Lavoie <lavoie at mcs.anl.gov>
> To: Simon Winberg <swinberg at utsi.edu>
> cc: vtkusers at public.kitware.com
> Subject: Re: [vtkusers] VTK MPI with SSH Display problem
>
> I'm not very knowledgable on the whole ssh/ X-pipes/ display thing, but
> I've worked with the vtk parallel libs quite a bit. Here are my ideas:
>
> do an 'xhost +<machine expected to be proc zero>' on the display term; the
> display process (zero) may not run on that machine, even though you don't
> have a '-nolocal' option to lamexec. (actually I use mpirun, so I'm not
> sure what your options are).
>
> After ssh_agent, do you run ssh_add? (I have this in my notes).
>
> Then, either a line in the program of 'putenv("DISPLAY=<hostname>");' or
> this option as an arg after the job name:
> '-MPDENV- DISPLAY=<hostname>:0.0' (which should get handled by the
> MPI_Init)
>
> This at least has worked for me; ymmv.
> -Tony
>
> On Wed, 18 Jul 2001, Simon Winberg wrote:
>
> > Hi all,
> >
> > I've got VTK compiled with the MPI option, and am testing the
> > ParallelIso program. I'm using ssh with the ssh-agent to connect to the
> > other PC's.
> >
> > When I execute the program (using the lamexec command) the
> > application runs for a few seconds and then crashes (see output
> > below). I can run the application fine on one PC simulating multiple
> > processors, but when I add any of the other PCs in my cluster I get this
> > error:
> >
> > --------
> > $ lamexec -np 3 ParallelIso
> >
> > Update 3000 took 0.531551 seconds to produce 68 triangles
> > Update 1750 took 0.828511 seconds to produce 88310 triangles
> > Update 500 took 0.738054 seconds to produce 64982 triangles
> > Update 3000 took 2.94585 seconds to produce 68 triangles
> > ERROR: In vtkXRenderWindow.cxx, line 176
> > vtkMesaRenderWindow (0x8235550): bad X server connection.
> >
> > ERROR: In vtkMesaRenderWindow.cxx, line 122
> > vtkMesaRenderWindow (0x8235550): bad X server connection.
> > --------
> >
> > I have tried the other example programs with similar results.
> > Could this be a problem with how ssh handles exporting of the display?
> >
> > Any ideas?
> >
> >
> >
> >
> > _______________________________________________
> > This is the private VTK discussion list.
> > Please keep messages on-topic. Check the FAQ at: <http://public.kitware.com/cgi-bin/vtkfaq>
> > Follow this link to subscribe/unsubscribe:
> > http://public.kitware.com/mailman/listinfo/vtkusers
> >
> >
>
> --__--__--
>
> Message: 3
> Date: Wed, 18 Jul 2001 09:36:17 -0700 (PDT)
> From: qakz <qakz at yahoo.com>
> To: vtkusers at public.kitware.com
> Subject: [vtkusers] execution error?
>
> hi again..
> thx for all the help!
> managed to compile & link now.. but now when i
> execute, i get an error window which says
>
> Debug Error!
> ... FILES\MYPROJECTS\DEMO1\DEBUG\DEMO1.EXE
> Module:
> File:i386\chkesp.c
> Line:42The value of ESP was not properly saved across
> a function call. This is usually a result of calling a
> function declared with one calling convention with a
> function pointer declared with a different calling
> convention.
>
> & when i press retry to debug, i get that dialog box
> that says this program has performed an illegal
> operation & will close...
>
> i was trying with the example Cone.cxx & have trie
> with other examples but got the same thing..
> what have i done wrong now?
> pls help! i'm sposed to get this working by tomoro =(
> tina
>
> __________________________________________________
> Do You Yahoo!?
> Get personalized email addresses from Yahoo! Mail
> http://personal.mail.yahoo.com/
>
> --__--__--
>
> Message: 4
> Date: Wed, 18 Jul 2001 12:55:07 -0400
> From: Simon Warfield <warfield at bwh.harvard.edu>
> To: Simon Winberg <swinberg at utsi.edu>
> Cc: vtkusers at public.kitware.com
> Subject: Re: [vtkusers] VTK MPI with SSH Display problem
>
> ssh can be configured to automatically forward the X display for you.
>
> See the ForwardX11 option of the ssh man page.
>
> You can also explicitly pass the display back to your localhost.  We have had
> success running vtk tcl scripts with MPICH it via e.g.
>
> xhost +
> mpirun -np 3 /d/pathtobinary/vtk -display localhost:0.0 -nolocal -machinefile machines-for-this-run /d/pathtovtkscript
>
> On Wed, Jul 18, 2001 at 10:38:58AM -0500, Simon Winberg wrote:
> > Hi all,
> >
> > I've got VTK compiled with the MPI option, and am testing the
> > ParallelIso program. I'm using ssh with the ssh-agent to connect to the
> > other PC's.
> >
> > When I execute the program (using the lamexec command) the
> > application runs for a few seconds and then crashes (see output
> > below). I can run the application fine on one PC simulating multiple
> > processors, but when I add any of the other PCs in my cluster I get this
> > error:
> >
> > --------
> > $ lamexec -np 3 ParallelIso
> >
> > Update 3000 took 0.531551 seconds to produce 68 triangles
> > Update 1750 took 0.828511 seconds to produce 88310 triangles
> > Update 500 took 0.738054 seconds to produce 64982 triangles
> > Update 3000 took 2.94585 seconds to produce 68 triangles
> > ERROR: In vtkXRenderWindow.cxx, line 176
> > vtkMesaRenderWindow (0x8235550): bad X server connection.
> >
> > ERROR: In vtkMesaRenderWindow.cxx, line 122
> > vtkMesaRenderWindow (0x8235550): bad X server connection.
> > --------
> >
> > I have tried the other example programs with similar results.
> > Could this be a problem with how ssh handles exporting of the display?
> >
> > Any ideas?
> >
> >
> >
> >
> > _______________________________________________
> > This is the private VTK discussion list.
> > Please keep messages on-topic. Check the FAQ at: <http://public.kitware.com/cgi-bin/vtkfaq>
> > Follow this link to subscribe/unsubscribe:
> > http://public.kitware.com/mailman/listinfo/vtkusers
>
> --
> Simon Warfield, Ph.D. warfield at bwh.harvard.edu Phone:617-732-7090
> http://www.spl.harvard.edu/~warfield           FAX:  617-582-6033
> Thorn 329, Brigham and Women's Hospital, Harvard Medical School
> Department of Radiology, 75 Francis St, Boston, MA, 02115
>
> --__--__--
>
> Message: 5
> Date: 18 Jul 2001 14:27:46 -0700
> To: vtkusers at public.kitware.com
> From: Sivashanmugaraman Sugavanam <s_s_raman45 at altavista.com>
> Subject: [vtkusers] Re: vtkusers digest, Vol 1 #486 - 3 msgs
>
> Hi VTK users,
>             Is there any way in which I could find out the tissue layer thickness specifying the isosurface values of the bone and the outer skin layer using the vtk classes. Any kind of help is greatly appreciated.
>
> Thanks
>
> Graduate Research Assistant
> #310,300 South Cooper Street
> Arlington
> TX 76013.
> Ph- 817-860-2638  (Home)
>          817-272-5719  (Office)
> Find the best deals on the web at AltaVista Shopping!
> http://www.shopping.altavista.com
>
> --__--__--
>
> Message: 6
> Date: Wed, 18 Jul 2001 20:53:19 -0400
> From: "David E. Jones" <jonesde at rainbow.es.dupont.com>
> Organization: Central Research
> To: vtkusers at public.kitware.com
> Subject: [vtkusers] vrml 1 to vrml 2 translator
>
> --------------4F63D0E023B8F956BD35CE1D
> Content-Type: text/plain; charset=us-ascii
> Content-Transfer-Encoding: 7bit
>
> I have some vrml 1 files to import into vtk.   However the vtk vrml
> importer reads vrml 2.
> There used to be a vrml 1 to vrml 2 translator distributed with SGI Irix
> I think but I can't
> find it now.
> Does anyone know of a vrml 1 to vrml 2 translator ?
>
> Thanks in advance,
> Dave
>
> --
> David E Jones
> Du Pont Central Research
> Experimental Station, Bldg 320
> Wilmington, DE 19880-0320
>
> --------------4F63D0E023B8F956BD35CE1D
> Content-Type: text/html; charset=us-ascii
> Content-Transfer-Encoding: 7bit
>
> <HTML>
> I have some vrml 1 files to import into vtk.&nbsp;&nbsp; However the vtk
> vrml importer reads vrml 2.
> <BR>There used to be a vrml 1 to vrml 2 translator distributed with SGI
> Irix I think but I can't
> <BR>find it now.
> <BR>Does anyone know of a vrml 1 to vrml 2 translator ?
>
> <P>Thanks in advance,
> <BR>Dave
> <PRE>--&nbsp;
> David E Jones
> Du Pont Central Research
> Experimental Station, Bldg 320
> Wilmington, DE 19880-0320</PRE>
> &nbsp;</HTML>
>
> --------------4F63D0E023B8F956BD35CE1D--
>
> --__--__--
>
> Message: 7
> Date: Thu, 19 Jul 2001 02:03:33 +0100
> To: Tony Lavoie <lavoie at mcs.anl.gov>, vtkusers at public.kitware.com
> From: John Biddiscombe <jbiddiscombe at skippingmouse.co.uk>
> Subject: Re: [vtkusers] vtk w/ CAVElib and clipping
> >
>
> >if I translate it vertically (set with PolyDataMapper::SetTranslation)
>
> Does the problem go away if you use a vtkTranslatePointsFilter instead of
> the translation mentioned. (I don't have a PolyDataMapper::SetTranslation
> member anywhere around). It could be something odd to do with the
> clippingplanes being applied before a transformation matrix and being in
> the wrong coord system.
>
> [just a thought...]
>
> JB
>
> --__--__--
>
> Message: 8
> Date: Thu, 19 Jul 2001 10:26:16 +0200
> From: Johan de Jong <Johan.de.Jong at best.ms.philips.com>
> Organization: Philips Medical Systems
> To: vtkusers at public.kitware.com
> Subject: [vtkusers] dbx dumps core on Forte Developer 6
>
> Hi,
>
> When I attempt to debug a VTK program (for example the demo 'Cube') dbx
> dumps core.
> I compiled VTK and the demo with the WorkShop 6 C++ 5.1 compiler (Forte
> Developer 6) on Sun Solaris 8.
>
> Here's the dbx log:
>
> (dbx) cd /user/jong/vtk/vtk3.2/vtk/vtkunix/graphics/examplesCxx
> (dbx) debug /user/jong/vtk/vtk3.2/vtk/vtkunix/graphics/examplesCxx/Cube
> Reading Cube
> Reading ld.so.1
> Reading libVTKPatented.so
> Reading libVTKImaging.so
> Reading libVTKGraphics.so
> Reading libVTKCommon.so
>
> dbx: internal error: signal SIGSEGV (no mapping at the fault address)
> dbx's coredump will appear in /tmp
>
> Any sugestions ?
>
> --
> Johan de Jong
> Philips Medical Systems
>
> --__--__--
>
> Message: 9
> Date: Thu, 19 Jul 2001 11:39:08 +0200
> From: Matthieu Ferrant <ferrant at tele.ucl.ac.be>
> To: vtkusers at public.kitware.com
> Subject: [vtkusers] Scalar Range problem
>
> Hi,
>
> I am encountering an unwanted behavior of GetScalarRange on
> vtkImageData.
>
> When I read in imagedata and call an update so the entire image is in
> memory, GetScalarRange performs normally. After having used the
> imageData for some other viewing purposes as input to other filters,
> GetScalarRange fails and outputs a different scalar range ...
>
> To check what was going on at the level of the scalars associated to the
> image, I added a print in the ComputeRange method of vtkScalars to
> output the number of scalars at each call :
> - first call (after imageReader update) : 126976 (normal : 64*64*31
> voxels)
> - second call (no other calls, no modifications to image ,it has just
> been passed as input to other filters) : 1984 (31*64, just a slice), so
> it seems it has computed the scalar range on a slice the image viewer
> used before the call to ComputeRange. Apparently, the entire image does
> not stay in memory, because when I call GetActualMemorySize it goes down
> from 127 kbytes to 2kbytes, which is the size of a slice.
>
> How can I prevent this from happening, and keep the entire image stored
> in memory so that if I call GetScalarRange, it keeps giving me the same
> range ?
>
> Thanks,
>
> matt
>
> --
> M.Ferrant, Ph.D.
> UCL/TELE Room A-157 Place du Levant, 2 B-1348LLN - Belgium
> Tel. +32-10-478073 Fax. : +32-10-472089
> http://www.tele.ucl.ac.be/MEMBERS/Ferrant_Matthieu_e.html
>
> --__--__--
>
> Message: 10
> Date: Thu, 19 Jul 2001 11:50:23 +0100
> To: TJ Wilkinson <tswilkin at fas.harvard.edu>,
> VTK Mailing List <vtkusers at public.kitware.com>
> From: John Biddiscombe <jbiddiscombe at skippingmouse.co.uk>
> Subject: Re: [vtkusers] Inconsistent rendering times
> du>
>
> >pipeline and then update the screen, it sometimes takes a few minutes to
> >get out of the Render() call, while other times it takes only a few
>
> when using an imagemapper ...
> if the data is in unsigned char format, the pointer can be passed directly
> to glDrawPixels, if the data is float, or other, it has to be scaled and
> wotnot. This causes a delay.
> Also, if a slice is contigous in memory (usually a zslice), then it can be
> rendered directly, but if taking a slice on another axis, it has to be
> extracted and passed.
> These two are you main delays, but may not be valid in your case....
>
> JB
>
> --__--__--
>
> Message: 11
> Date: Thu, 19 Jul 2001 14:28:52 +0200
> From: Matthieu Ferrant <ferrant at tele.ucl.ac.be>
> To: vtkusers at public.kitware.com
> Subject: Re: [vtkusers] Scalar Range problem
>
> Response to my earlier posting :
>
> I found a way to avoid the scalar range being computed only on the part
> of the image which is used by the pipeline : AllocateScalars()
> e.g. to obtain the scalar range on an entire image volume :
> myImageData AllocateScalars
> set range [myImageData GetScalarRange]
>
> It seems that vtk is releasing the memory of the scalars to those
> associated to the chunks of the data that are being used by the
> pipeline.
>
> matt
>
> Matthieu Ferrant wrote:
> >
> > Hi,
> >
> > I am encountering an unwanted behavior of GetScalarRange on
> > vtkImageData.
> >
> > When I read in imagedata and call an update so the entire image is in
> > memory, GetScalarRange performs normally. After having used the
> > imageData for some other viewing purposes as input to other filters,
> > GetScalarRange fails and outputs a different scalar range ...
> >
> > To check what was going on at the level of the scalars associated to the
> > image, I added a print in the ComputeRange method of vtkScalars to
> > output the number of scalars at each call :
> > - first call (after imageReader update) : 126976 (normal : 64*64*31
> > voxels)
> > - second call (no other calls, no modifications to image ,it has just
> > been passed as input to other filters) : 1984 (31*64, just a slice), so
> > it seems it has computed the scalar range on a slice the image viewer
> > used before the call to ComputeRange. Apparently, the entire image does
> > not stay in memory, because when I call GetActualMemorySize it goes down
> > from 127 kbytes to 2kbytes, which is the size of a slice.
> >
> > How can I prevent this from happening, and keep the entire image stored
> > in memory so that if I call GetScalarRange, it keeps giving me the same
> > range ?
> >
> > Thanks,
> >
> > matt
> >
> > --
> > M.Ferrant, Ph.D.
> > UCL/TELE Room A-157 Place du Levant, 2 B-1348LLN - Belgium
> > Tel. +32-10-478073 Fax. : +32-10-472089
> > http://www.tele.ucl.ac.be/MEMBERS/Ferrant_Matthieu_e.html
> >
> > _______________________________________________
> > This is the private VTK discussion list.
> > Please keep messages on-topic. Check the FAQ at: <http://public.kitware.com/cgi-bin/vtkfaq>
> > Follow this link to subscribe/unsubscribe:
> > http://public.kitware.com/mailman/listinfo/vtkusers
>
> --
> M.Ferrant, Ph.D.
> UCL/TELE Room A-157 Place du Levant, 2 B-1348LLN - Belgium
> Tel. +32-10-478073 Fax. : +32-10-472089
> http://www.tele.ucl.ac.be/MEMBERS/Ferrant_Matthieu_e.html
>
> --__--__--
>
> Message: 12
> Date: Thu, 19 Jul 2001 16:08:11 +0200 (CEST)
> From: =?iso-8859-1?q?Herbert=20Muthsam?= <herbert_muthsam at yahoo.de>
> To: gentile at dancer.ca.sandia.gov, goodwin.lawlor at ucd.ie,
> vtk_ users <vtkusers at public.kitware.com>
> Subject: [vtkusers] vtkdll.lib not produced with nmake on WNT4.0/VC++6.0
>
> Hi,
>
> my problem in running any vtk example seems to boil
> down to the fact that I do not manage to produce a
> vtkdll.lib file with nmake (I get, however, a
> vtkdll.dll file). Below I describe closer
> circumstances and would be grateful for comments.
>
> Herbert J. Muthsam, University of Vienna
>
> Athlon, 768 MB memory, 2*512MB swap space (on 2drives)
>   no significant other process executing
> Windows Nt 4.0, sp6, VisualC++ 6.0 compiler
>
> PATH has been enhanced manually so as to include
>
> C:\..\Microsoft Visual Studio\VC98\Lib (for opengl and
>                                         glaux.lib
> files
> C:\..        ..              \VC98\Bin (for Cl.exe)
> C:\          ..              \Common\MSDev98\Bin
>
> When running nmake it looks like this:
>
> C:\..\vtk32 nmake
>   cd vtkdll
>   nmake OBJS
>
>   nmake LIBRARIES
>
>   link.exe @C:\TEMP\nma00338.
>
> C:\...\Microsoft Visual Studio\VC98\lib\gdi32.lib
> fatal
>   error LNK1106: invalid file or disk full. cannot
> seek
>   0x35012a68
>   [ACTUALLY DISK C has 5GB FREE; HOWEVER, I DO NOT SEE
>    a nma-FILE IN \TEMP]
>   NMAKE: fatal error U1077. return code 0x2
> Stop.
>
> By the way, in the vtl\vtk32dll\obj directory there
> are lots of .obj files.
>
> __________________________________________________________________
> Do You Yahoo!?
> Gesendet von Yahoo! Mail - http://mail.yahoo.de
>
> --__--__--
>
> Message: 13
> From: leung at arlut.utexas.edu
> To: vtkusers at public.kitware.com
> Date: Thu, 19 Jul 2001 09:18:30 -0500
> Subject: [vtkusers] vtkXYPlotActor C++ Examples
>
> Hi,
>
> I am wondering if there is anyone that has worked with vtkXYPlotActor and
> have any good examples in C++ (not Tcl) on this.  Thanks in advance for
> your help!
>
> Alvin
>
> --__--__--
>
> Message: 14
> Date: 19 Jul 2001 11:30:24 EDT
> From: Ziji.Wu at Dartmouth.EDU (Ziji Wu)
> Reply-To: Ziji.Wu at Dartmouth.EDU
> To: vtkusers at public.kitware.com
> Subject: [vtkusers] compiling on IRIX machine
>
> Hi, there
>
> I'm trying to compile vtk3.2 on IRIX machine. I have had no problem until the
> very end. The machine will freeze after linking the libraries together, that
> is, the screen will stop at 'ld ...', and I get no response from the machine at
> all. But, the vtk executables were actually created.
>
> Can anybody out there explain and help me to solve this issue?
>
> Thanks a lot!
>
> Ziji
>
> --__--__--
>
> _______________________________________________
> vtkusers mailing list
> vtkusers at public.kitware.com
> http://public.kitware.com/mailman/listinfo/vtkusers
>
> End of vtkusers Digest

--
----------------------------------------------------------
Jose Vicente Manjón Herrera
GIM (Group of Medical Informatics)
Applied Physics Department
Technical University of Valencia
46022 Valencia (SPAIN)
----------------------------------------------------------






More information about the vtkusers mailing list