@polygonjs/polygonjs
Version:
node-based WebGL 3D engine https://polygonjs.com
30 lines (29 loc) • 1.18 kB
TypeScript
/**
* The copy expression allows the copy SOP node to evaluates its input graph multiple times, and vary its result each time.
*
* @remarks
* It takes 2 or 3 arguments
*
* `copy(input_index_or_node_path, default_value, attribute_name)`
*
* - `input_index_or_node_path` is a number or a string
* - `default_value` is a number
* - `attribute_name` is the attribute that will be stamped
*
* ## Usage
*
* - `copy('../copy1', 0, 'i')` - returns the index of each evaluation
* - `copy('../copy1', 0)` - returns the index of each evaluation
* - `copy('../copy1')` - returns the index of each evaluation
* - `copy('../copy1', 0, 'id')` - returns the value of the 'id' attribute of the instance point, or 0 if the attribute doesn't exist
*
*/
import { BaseMethodFindDependencyArgs } from './_Base';
import { BaseMethod } from './_Base';
import { MethodDependency } from '../MethodDependency';
export declare class CopyExpression extends BaseMethod {
static requiredArguments(): string[][];
static optionalArguments(): string[][];
findDependency(args: BaseMethodFindDependencyArgs): MethodDependency | null;
processArguments(args: any[]): Promise<any>;
}