[vtkusers] vtkImageImport and RGB colouing

REGAT-BARREL Aurélien arbvtk at yahoo.fr
Fri May 14 11:54:43 EDT 2004


Create a Device Independant Bitmap and blit you memory DC inside.
Use this DIB a input for your vtkImageImport.
Why are you getting the bitmap from a DC ?
Greets.

Pedram Rezaei <pr at marinecomputing.com> wrote:

Hi all,

 

I am importing a bitmap from a memory device context (Win32) into VTK. Unfortunately the bitmap in memory is laid out in BGR format instead of RGB. So far I have managed to overcome the problem by manually swapping Blue with Red values for every single pixel. Is there an easy way to tell the vtkImageImport to assume that the imported format is BGR?

 

Thanks,

 

Pedram



Aurélien REGAT-BARREL
		
---------------------------------
Yahoo! Mail : votre e-mail personnel et gratuit qui vous suit partout !
Créez votre Yahoo! Mail

Dialoguez en direct avec vos amis grâce à Yahoo! Messenger !
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20040514/941c9b23/attachment.htm>


More information about the vtkusers mailing list