Package: graphene

Macro graphene:with-ray

Lambda List

graphene:with-ray ((var &rest args) &body body)

Syntax

(graphene:with-ray (ray) body) => result
(graphene:with-ray (ray ray1) body) => result
(graphene:with-ray (ray origin direction) body) => result
(graphene:with-ray (ray (origin graphene:vec3-t) direction) body) => result

Arguments

ray -- a graphene:ray-t instance to create and initialize
ray1 -- a graphene:ray-t instance to use for initialization
origin -- a graphene:point3d-t or a graphene:vec3-t instance to use for initialization
direction -- a graphene:vec3-t instance to use for initialization

Details

The graphene:with-ray macro allocates a new graphene:ray-t instance, initializes the box with the given values and executes the body that uses the ray. After execution of the body the allocated memory for the box is released.

Notes

The memory is allocated with the graphene:ray-alloc function and released with the graphene:ray-free function.
 

See also

2025-4-7