CreateImageWithOptions - TransparentBackground = true

CreateImageWithOptions - TransparentBackground = true

Rene_Gerlach
Advocate Advocate
2,324 Views
6 Replies
Message 1 of 7

CreateImageWithOptions - TransparentBackground = true

Rene_Gerlach
Advocate
Advocate

Did someone tried this option and get saved the Image transparent?

 

It returns a IPictureDisp.

The type inside IPictureDisp is PICTYPE_BITMAP.

The attributes (PICTUREATTRIBUTES) are 0, so no PICTURE_TRANSPARENT(2) is set.

 

So for what is TransparentBackground = true usable?

 

Shouldn't IPictureDisp be of type PICTYPE_ICON or PICTYPE_METAFILE which are supporting transparency.

Accepted solutions (1)
2,325 Views
6 Replies
Replies (6)
Message 2 of 7

Rene_Gerlach
Advocate
Advocate

Any comment from Autodesk?

Message 3 of 7

WCrihfield
Mentor
Mentor

You probably already know about this one, but there is a 'Remark' at the bottom of the online help page for that method (CreateImageWithOptions) that may help.  It basically says that if you currently have an image set as background within Inventor, it will ignore your settings for background when creating this image.  Then says you can check the status of this with ColorSchemes.BackgroundTypeColorSchemes is a ReadOnly property of the Inventor application, and the second property returns a value from the BackgroundTypeEnum.

Wesley Crihfield

EESignature

(Not an Autodesk Employee)

0 Likes
Message 4 of 7

ls-4453
Enthusiast
Enthusiast

This appears to still be a problem in Inventor 2022. Using TransparentBackground = True with Camera.CreateImageWithOptions produces an IPictureDisp which does not have a transparent background.

 

Does anyone from Autodesk have any input? Sure they didn't intend for this option to do absolutely nothing.

 

Currently, the only way to get a transparent image is to use View.SaveAsBitmapWithOptions, which clearly isn't a solution because it requires creating a view for every single image.

0 Likes
Message 5 of 7

ls-4453
Enthusiast
Enthusiast

Bump. How can we get assistance with this? It's not as if we get this software for free.

0 Likes
Message 6 of 7

Yijiang.Cai
Autodesk
Autodesk

It has been tracked as [INVGEN-81693], which is being worked in progress. Thanks!

Thanks,
River Cai

Inventor Quality Assurance Team
Autodesk, Inc.
Email: River-Yijiang.Cai@autodesk.com
0 Likes
Message 7 of 7

Yijiang.Cai
Autodesk
Autodesk
Accepted solution

This has been implemented in Inventor 2026.1, and please have a try. Thank you!

Thanks,
River Cai

Inventor Quality Assurance Team
Autodesk, Inc.
Email: River-Yijiang.Cai@autodesk.com