Aspose.Slides FOSS provides two separate format objects for advanced shape styling: EffectFormat for 2D visual effects and ThreeDFormat for three-dimensional appearance.
Package: aspose.slides_foss
Both are accessed from any Shape object:
EffectFormat
EffectFormat controls effects rendered in the same plane as the slide: drop shadows, glows, soft edges, blurs, and reflections.
Properties
| Property | Type | Description |
|---|
is_no_effects | bool | True when no effects are active. |
outer_shadow_effect | OuterShadow | None | Drop shadow outside the shape boundary. None until enable_outer_shadow_effect() is called. |
inner_shadow_effect | InnerShadow | None | Shadow cast inside the shape boundary. None until enabled. |
glow_effect | Glow | None | Colored glow around the shape edge. None until enable_glow_effect() is called. |
blur_effect | Blur | None | Gaussian blur of the shape. None until set_blur_effect() is called. |
soft_edge_effect | SoftEdge | None | Feathered edge fade. None until enable_soft_edge_effect() is called. |
reflection_effect | Reflection | None | Mirror reflection below the shape. None until enabled. |
Enable / Disable Methods
| Method | Description |
|---|
enable_outer_shadow_effect() | Create and attach an OuterShadow with default settings. |
disable_outer_shadow_effect() | Remove the outer shadow. |
enable_glow_effect() | Create and attach a Glow with default settings. |
disable_glow_effect() | Remove the glow. |
enable_soft_edge_effect() | Create and attach a SoftEdge. |
disable_soft_edge_effect() | Remove the soft edge. |
set_blur_effect(radius, grow) | Apply a Gaussian blur. radius is in points; grow (bool) controls whether the blur area expands the shape bounds. |
OuterShadow Properties
| Property | Type | Description |
|---|
blur_radius | float | Shadow softness in points. Larger = softer edge. |
direction | float | Shadow angle in degrees (0 = right, 90 = down, 315 = upper-left). |
distance | float | Offset distance in points between shape and shadow center. |
shadow_color | ColorFormat | Shadow color with alpha. Use Color.from_argb(alpha, r, g, b) for semi-transparent shadows. |
Glow Properties
| Property | Type | Description |
|---|
radius | float | Glow spread radius in points. |
color | ColorFormat | Glow color. |
SoftEdge Properties
| Property | Type | Description |
|---|
radius | float | Feather radius in points. |
Blur Properties
| Property | Type | Description |
|---|
radius | float | Blur radius in points. |
ThreeDFormat
ThreeDFormat gives a flat shape a three-dimensional appearance by defining bevel, camera perspective, light source, material, and extrusion depth.
Properties
| Property | Type | Description |
|---|
bevel_top | ShapeBevel | Bevel applied to the top (front) face of the shape. |
bevel_bottom | ShapeBevel | Bevel applied to the bottom (back) face. |
camera | Camera | Camera position/projection for the 3D view. |
light_rig | LightRig | Light source preset and direction. |
material | MaterialPresetType | Surface material appearance (e.g., METAL, PLASTIC, MATTE). |
depth | float | Extrusion depth in points. |
contour_width | float | Width of the shape contour/edge highlight in points. |
contour_color | ColorFormat | Color of the contour. |
ShapeBevel Properties
| Property | Type | Description |
|---|
bevel_type | BevelPresetType | Bevel shape preset (e.g., CIRCLE, RELAXED_INSET, COOL_SLANT, DIVOT, HARD_EDGE, SLOPE, CONVEX). |
width | float | Horizontal bevel size in points. |
height | float | Vertical bevel size in points. |
Camera Properties
| Property | Type | Description |
|---|
camera_type | CameraPresetType | Preset camera position (e.g., PERSPECTIVE_ABOVE, ISOMETRIC_LEFT_UP, ORTHOGRAPHIC_FRONT). |
LightRig Properties
| Property | Type | Description |
|---|
light_type | LightRigPresetType | Light preset (e.g., BALANCED, THREE_PT, SOFT, HARSH, FLOOD). |
direction | LightingDirection | Direction the light comes from (e.g., TOP, BOTTOM, LEFT, RIGHT, TOP_LEFT). |
MaterialPresetType Values
| Value | Appearance |
|---|
STANDARD | Default matte-like surface |
WARM | Warm tonal surface |
COOL | Cool tonal surface |
PLASTIC | Smooth plastic sheen |
METAL | Metallic reflective surface |
MATTE | Flat non-reflective |
WIREFRAME | Wireframe outline only |
Usage Examples
Outer Drop Shadow
Gold Glow Effect
Soft Edge Fade
3D Bevel with Metal Material
Combining Effects
See Also