Skip to main content

Process

element

element() 

Processes an element's function to get its drawables and bounds. Returns a dictionary with the key-values: ctx The modified context object, bounds The aabb of the element's drawables, drawables An array of the element's drawables.

ctx:

The current context object.

element-func:

A function that when passed ctx, it should return an element dictionary.

many

many() -> dictionary 

Runs the element function for a list of element functions and aggregates the results.

ctx:

The current context object.

body:

The array of element functions to process.