Struct hapi_rs::pdg::TopNode

source ·
pub struct TopNode {
    pub node: HoudiniNode,
}
Expand description

A wrapper for HoudiniNode with methods for cooking PDG.

Fields

node: HoudiniNode

Implementations

Start cooking a TOP node asynchronously. For each generated event, a user closure will be called with a CookStep argument.

The closure returns Result<ControlFlow<bool>> which is handled like this:

If its an Err(_) - bubble up the error. If it’s [ControlFlow::Break(bool)] then the bool is either to cancel the cooking or just break the loop and return. In case of [ControlFlow::Continue(_)] run until completion.

See the pdg_cook example in the /examples folder.

Get the graph(context) id of this node in PDG.

Cancel cooking.

Dirty the node, forcing the work items to regenerate.

Which this node current PdgState

Get the work item by id and graph(context) id.

Trait Implementations

Returns a copy of the value. Read more
Performs copy-assignment from source. Read more
Formats the value using the given formatter. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The resulting type after obtaining ownership.
Creates owned data from borrowed data, usually by cloning. Read more
Uses borrowed data to replace owned data, usually by cloning. Read more
The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.