@polygonjs/polygonjs
Version:
node-based WebGL 3D engine https://polygonjs.com
60 lines (59 loc) • 3.13 kB
TypeScript
/**
* Sets an attribute value for a specific point or object
*
* @remarks
* While the same operation is possible using the sop/attribCreate
* and its group parameter, this node is more performant.
* Also, unlike the sop/attribCreate, it does not accept point specific variables such as @ptnum
* in expressions.
*
*/
import { TypedSopNode } from './_Base';
import { AttribClass, AttribType } from '../../../core/geometry/Constant';
import { CoreGroup } from '../../../core/geometry/Group';
import { NodeParamsConfig } from '../utils/params/ParamsConfig';
declare class AttribSetAtIndexSopParamsConfig extends NodeParamsConfig {
/** @param the point or object index this applies to */
index: import("../utils/params/ParamsConfig").ParamTemplate<import("../../index_all").ParamType.INTEGER>;
/** @param the attribute class (geometry or object) */
class: import("../utils/params/ParamsConfig").ParamTemplate<import("../../index_all").ParamType.INTEGER>;
/** @param the attribute type (numeric or string) */
type: import("../utils/params/ParamsConfig").ParamTemplate<import("../../index_all").ParamType.INTEGER>;
/** @param the attribute name */
name: import("../utils/params/ParamsConfig").ParamTemplate<import("../../index_all").ParamType.STRING>;
/** @param the attribute size (1 for float, 2 for vector2, 3 for vector3, 4 for vector4) */
size: import("../utils/params/ParamsConfig").ParamTemplate<import("../../index_all").ParamType.INTEGER>;
/** @param the value for a float attribute */
value1: import("../utils/params/ParamsConfig").ParamTemplate<import("../../index_all").ParamType.FLOAT>;
/** @param the value for a vector2 */
value2: import("../utils/params/ParamsConfig").ParamTemplate<import("../../index_all").ParamType.VECTOR2>;
/** @param the value for a vector3 */
value3: import("../utils/params/ParamsConfig").ParamTemplate<import("../../index_all").ParamType.VECTOR3>;
/** @param the value for a vector4 */
value4: import("../utils/params/ParamsConfig").ParamTemplate<import("../../index_all").ParamType.VECTOR4>;
/** @param the value for a string attribute */
string: import("../utils/params/ParamsConfig").ParamTemplate<import("../../index_all").ParamType.STRING>;
}
export declare class AttribSetAtIndexSopNode extends TypedSopNode<AttribSetAtIndexSopParamsConfig> {
paramsConfig: AttribSetAtIndexSopParamsConfig;
static type(): string;
initializeNode(): void;
private _operation;
cook(inputCoreGroups: CoreGroup[]): void;
private _addAttribute;
private _addPointAttribute;
private _addObjectAttribute;
private _addCoreGroupAttribute;
private _addNumericAttributeToPoints;
private _addNumericAttributeToObject;
private _addNumericAttributeToCoreGroup;
private _addStringAttributeToPoints;
private _addStringAttributeToObject;
private _addStringAttributeToCoreGroup;
private _isUsingExpression;
setAttribClass(attribClass: AttribClass): void;
attribClass(): AttribClass;
setAttribType(type: AttribType): void;
attribType(): AttribType;
}
export {};