Re: What's the DIB struct in C#?(Image Pro for .Net V14.0)
Started by fyjin99 at 06-01-2008 22:07. Topic has 5 replies.
|
|
06-02-2008, 2:21
|
fyjin99
Joined on 06-02-2008
Posts 8
|
Re: What's the DIB struct in C#?(Image Pro for .Net V14.0)
|
 
 
|
|
|
When I turn the DIB handle to a point I can enven move back as below: IntPtr ptr = Image.ToDib(RasterConvertToDibType.BitmapInfoHeader); The Image is IRasterImage type and loaded correctly. unsafe { byte* pDib = (byte*)ptr.ToPointer(); pDib -= 1000;//Move the point back. for (int i = 0; i < 1000; i++) pDib[i] = 255;// I expect the errors here but it just works! } It can works with no errors. I don't know what's happened. Could anybody figure it out? Thanks:)
|
|
|
|
|
Report
|
|
|
|
06-02-2008, 9:19
|
Qasem Lubani

Joined on 08-13-2006
Posts 1,082
|
Re: What's the DIB struct in C#?(Image Pro for .Net V14.0)
|
 
 
|
|
|
The DIB that results
from the ToDib method in LEADTOOLS is a standard Windows Independent Bitmap.
I'm not sure what you're trying to do with the byte pointer in the code you
posted, but if you use the DIB in a normal way that other DIBs work with but
not ours, please explain what you're doing and I will check it for you.
Qasem Al-Lubani LEAD Technical Support www.leadtools.com
|
|
|
|
|
Report
|
|
|
|
06-03-2008, 21:40
|
fyjin99
Joined on 06-02-2008
Posts 8
|
Re: What's the DIB struct in C#?(Image Pro for .Net V14.0)
|
 
 
|
|
|
Thanks very much o(∩_∩)o... I missed the GlobalLock() method. Now it works!
|
|
|
|
|
Report
|
|
|
|
|
LEAD Support Fo... » Developer » DotNet » Re: What's the DIB struct in C#?(Image Pro for .Net V14.0)
|
|
Copyright LEAD Technologies, Inc. 2008
