Method

GskTransformperspective

Declaration [src]

GskTransform*
gsk_transform_perspective (
  GskTransform* next,
  float depth
)

Description [src]

Applies a perspective projection transform.

This transform scales points in X and Y based on their Z value, scaling points with positive Z values away from the origin, and those with negative Z values towards the origin. Points on the z=0 plane are unchanged.

This function consumes next. Use gsk_transform_ref() first if you want to keep it around.

Parameters

next

Type: GskTransform

The next transform.

The argument can be NULL.
The instance takes ownership of the data, and is responsible for freeing it.
depth

Type: float

Distance of the z=0 plane. Lower values give a more flattened pyramid and therefore a more pronounced perspective effect.

Return value

Type: GskTransform

The new transform.

The caller of the method takes ownership of the returned data, and is responsible for freeing it.