Welcome Guest! To enable all features, please Login or Register.

Notification

Icon
Error

Options
View
Last Go to last post Unread Go to first unread post
#1 Posted : Monday, September 26, 2005 12:36:22 AM(UTC)

Dave  
Dave

Groups: Registered
Posts: 5


Hi,

I get a "Invalid structure size" error message whenever I try using the LBitmapRgn::CreateMaskFromBitmapRgn() function. First of all I tried using it with just the LBitmapBase parameter but found that the documentation is out of date, there is now another size parameter. However, even when copying the online example (below) it still returns an error.

   LBitmapRgn lBmpRgn;
   LBitmapBase lBmpMask;

   lBmpRgn.SetBitmap(destbmp->lBitmap); // this is the LBitmap in my image
   L_UINT uCombineMode = lBmpRgn.GetRgnCombineMode();
   uCombineMode |= L_RGN_OR;
   lBmpRgn.SetRgnCombineMode(uCombineMode);
   lBmpRgn.SetRgnColor(RGB(0,0,0));

   // create mask region from bitmap
   lBmpRgn.CreateMaskFromBitmapRgn(&lBmpMask, sizeof(lBmpMask));

Any ideas?

Thanks,
Dave.

 

 

Try the latest version of LEADTOOLS for free for 60 days by downloading the evaluation: https://www.leadtools.com/downloads

Wanna join the discussion? Login to your LEADTOOLS Support accountor Register a new forum account.

#2 Posted : Thursday, September 29, 2005 5:31:38 PM(UTC)

Amin  
Amin

Groups: Manager, Tech Support
Posts: 367

Was thanked: 1 time(s) in 1 post(s)

The size you need to pass is that of the LEAD Bitmap Handle structure, which is sizeof(BITMAPHANDLE)

Edited by user Monday, December 5, 2016 4:36:39 PM(UTC)  | Reason: Not specified

Amin Dodin

Senior Support Engineer
LEAD Technologies, Inc.
LEAD Logo
 
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.

Powered by YAF.NET | YAF.NET © 2003-2024, Yet Another Forum.NET
This page was generated in 0.050 seconds.