[vtk-developers] Regarding of OpenGL/GPGPU intraoperation

Aashish Chaudhary aashish.chaudhary at kitware.com
Mon Jul 20 11:01:58 EDT 2015


Dear Shinya,

This sounds great. Please see my comments below:

On Mon, Jul 20, 2015 at 3:18 AM, sonogi1979 at live.jp <sonogi1979 at live.jp>
wrote:

> Hi,
>
> You know GPGPU is very hot technology in medical/scientific computing.
> Especially, I'm working 3D volume processing by using GPGPU(CUDA). To use
> GPGPU with vtk, I hope an interface for OpenGL-CUDA intraoperation to
> reduce
> redundant CPU-GPU data transfer.
>
> Simple hack of vtkOpenGLGPUVolumeRayCastMapper is followings:
>
> vtkTextureObject* vtkOpenGLGPUVolumeRayCastMapper::GetTextureObject()
> {
>   return this->Impl->VolumeTextureObject;
> }
>

When I get the texture object, I can access and operate a volume stored in
> GPU memory easily by using cudaGraphicsGLRegisterImage,
> cudaGraphicsMapResources, cudaGraphicsSubResourceGetMappedArray, and
> cudaBindSurfaceToArray because vtkTextureObject provides a texture handle
> and texture dimensions.
>
> On the other hand, the method is not well designed: no synchronization
> method among vtkImageData and vtkTextureObject, processed results does not
> affect in original vtkImageData.
>

Right. If the mapper has not been invoked once, then this will return a
un-initialized texture object. I believe the vtkTextureObject has an API to
check for its validity.

What exactly you are planning to do in CUDA?

Thanks,
Aashish

>
> If you know better way, please let me know.
>
> Thank you,
>
> Shinya
>
>
>
>
> --
> View this message in context:
> http://vtk.1045678.n5.nabble.com/Regarding-of-OpenGL-GPGPU-intraoperation-tp5732977.html
> Sent from the VTK - Dev mailing list archive at Nabble.com.
> _______________________________________________
> Powered by www.kitware.com
>
> Visit other Kitware open-source projects at
> http://www.kitware.com/opensource/opensource.html
>
> Search the list archives at: http://markmail.org/search/?q=vtk-developers
>
> Follow this link to subscribe/unsubscribe:
> http://public.kitware.com/mailman/listinfo/vtk-developers
>
>


-- 



*| Aashish Chaudhary | Technical Leader         | Kitware Inc.            *
*| http://www.kitware.com/company/team/chaudhary.html
<http://www.kitware.com/company/team/chaudhary.html>*
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/vtk-developers/attachments/20150720/5668f3a9/attachment.html>


More information about the vtk-developers mailing list