| Unix Content | Register | FAQ | Calendar | Search | Today's Posts | Mark Forums Read |
|
#1
|
| hi , I am tring to display DICOM image using .net. I am using following code. Bitmap bmp = new Bitmap(512, 512, System.Drawing.Imaging.PixelFormat.Format16bppGray Scale); It is giving error........ Which PixeFormat I have to use if bits allocated=8 and bits Stored=8. or if bits allocated=16 and bits Stored=12. Thanks, Rupali. |
|
#2
|
| Rupali wrote: > hi , > > I am tring to display DICOM image using .net. > I am using following code. > > Bitmap bmp = new Bitmap(512, 512, > System.Drawing.Imaging.PixelFormat.Format16bppGray Scale); > > It is giving error........ > > Which PixeFormat I have to use if bits allocated=8 and bits Stored=8. > > or if bits allocated=16 and bits Stored=12. > > Thanks, > > Rupali. Ha. The GDI+ provider of graphics in .Net land does not support 16bpp gray scale - not that it would matter. How many shades of gray can a human see anyway? You will need to work with the VOI LUT (window center and window width), allowing your user to adjust them in some fashion - the current fashion seems to be through grabbing the mouse and tracking mouse movement left/right and up/down. Take a look at KPACS and/or Clear Canvas "windowing" functions. Now, this isn't particularly difficult - the hard part comes in trying to do this in a performance kind of way. I'm currently studying the code in ClearCanvas - they seem to be more adept at performance with large 16bpp mammo images than what I can muster... Chuck |