Type alias ObjectOptions

ObjectOptions: {
    castShadow?: boolean;
    color?: ColorRepresentation;
    material?: Material;
    name?: string;
    parent?: Object3D;
    position?: Vec3 | [number, number, number];
    receiveShadow?: boolean;
    rotation?: Vec3 | [number, number, number];
    scale?: Vec3 | number;
    texture?: Texture;
}

Options to create an object. Used by ObjectUtils.createPrimitive

Type declaration

  • Optional castShadow?: boolean

    If the object should cast shadows

    Default

    true
    
  • Optional color?: ColorRepresentation

    The color of the object. This color will only be used if no material is provided

  • Optional material?: Material

    The material to apply to the object

  • Optional name?: string

    The name of the object

  • Optional parent?: Object3D

    The parent object to add the created object to

  • Optional position?: Vec3 | [number, number, number]

    The position of the object in local space

  • Optional receiveShadow?: boolean

    If the object should receive shadows

    Default

    true
    
  • Optional rotation?: Vec3 | [number, number, number]

    The rotation of the object in local space

  • Optional scale?: Vec3 | number

    The scale of the object in local space

  • Optional texture?: Texture

    The texture will applied to the material's main texture slot e.g. material.map if any is passed in

Generated using TypeDoc