Appearances.add Method

Parent Object: Appearances

PreviewThis functionality is provided as a preview of intended future API capabilities. You are encouraged to use it and report any problems or suggestions using the Fusion API and Scripts forum.

Because this is a preview of future functionality, there is the possibility that it will change, which will possibly break any existing programs that use this functionality. Because of that, you should never deliver any programs that use any preview capabilities. For a distributed program, you should wait until it has moved from preview to released state.


Defined in namespace "adsk::core" and the header file is <Core/Materials/Appearances.h>

Description

Creates a new Appearance in the Design with neutral defaults. The `surfaceType` parameter selects the surface category; the default (`OpaqueAppearanceSurface`) is appropriate for plastics, paints, ceramics, rubber, and most other non-metallic, non-transparent materials. Configure the result via the Appearance's `color`, `roughness`, `colorTexture`, `normalTexture`, and `roughnessTexture` properties, or via `appearanceProperties` for finer control.

This method only applies to the Appearances collection on a Design.

Syntax

"appearances_var" is a variable referencing an Appearances object.

# Uses no optional arguments.
returnValue = appearances_var.add(name)

# Uses optional arguments.
returnValue = appearances_var.add(name, surfaceType)
"appearances_var" is a variable referencing an Appearances object.

#include <Core/Materials/Appearances.h>

// Uses no optional arguments.
returnValue = appearances_var->add(name);

// Uses optional arguments.
returnValue = appearances_var->add(name, surfaceType);
"appearances_var" is a variable referencing an Appearances object.

// Uses no optional arguments.
returnValue = appearances_var.add(name);

// Uses Optional arguments.
returnValue = appearances_var.add(name, surfaceType);

Return Value

Type Description
Appearance Returns the newly created Appearance, or null if the collection is not from a Design (e.g. on a Library). Raises an error if `name` is empty or already in use.

Parameters

Name Type Description
name string The name to apply to the new Appearance. Must be non-empty and unique within the document's appearance collection.
surfaceType AppearanceSurfaceTypes The underlying surface type for the new appearance — opaque, metal, or transparent. Defaults to `OpaqueAppearanceSurface`.

This is an optional argument whose default value is AppearanceSurfaceTypes.OpaqueAppearanceSurface.

Version

Introduced in version July 2026