![]() |
![]() |
Shape.ConvertToBitmapEx
Function ConvertToBitmapEx([Mode As cdrImageType = cdrRGBColorImage], [Dithered As Boolean = False], [Transparent As Boolean = False], [Resolution As Long = 72], [AntiAliasing As cdrAntiAliasingType = cdrNormalAntiAliasing], [UseColorProfile As Boolean = True]) As Shape
Member of Shape
The ConvertToBitmapEx converts a shape object to a bitmap.
Parameters
|
Description
|
Mode
|
This parameter is optional, and its default value is cdrRGBColorImage (4).
|
Dithered
|
Enables dithering if set to True (-1)
This parameter is optional, and its default value is False.
|
Transparent
|
Enables a transparent background if set to True (-1)
This parameter is optional, and its default value is False.
|
Resolution
|
Sets the resolution
This parameter is optional, and its default value is 72.
|
AntiAliasing
|
Sets the anti-aliasing which returns cdrAntiAliasingType
This parameter is optional, and its default value is cdrNormalAntiAliasing (1).
|
UseColorProfile
|
Uses the color profile if set to True (-1)
This parameter is optional, and its default value is True.
|
The following code example creates a rectangle and an ellipse. Then it converts the ellipse to a CMYK bitmap with a transparent background, applies a dropshadow to it, and groups it with the rectangle.
Sub Test() Dim r As Shape, s As Shape Set r = ActiveLayer.CreateRectangle(0, 0, 5, 5) r.Fill.UniformColor.CMYKAssign 100, 0, 0, 0 Set s = ActiveLayer.CreateEllipse2(3, 3, 2) s.Fill.UniformColor.CMYKAssign 0, 100, 100, 0 Set s = s.ConvertToBitmapEx(cdrCMYKColorImage, False, True) s.CreateDropShadow cdrDropShadowFlat, 80, 10, 0.5, -0.5, CreateCMYKColor(0, 50, 50, 50) r.CreateSelection s.Selected = True ActiveSelection.Group End Sub
![]() |
![]() |
![]() |
Copyright 2007 Corel Corporation. All rights reserved.