An extension to load 3d models into an application.
Currently, the extension supports all the standard 3d model formats such as OBJ, 3ds, ASC and MD2 formats.
There are a few blocks currently, there are many features to cover
ā Blocks
Loads the Model into an Object.
-
model
: The file path of the 3d model. This can also be a URI Object. -
options
: Configurations settings to load the Model in List form.
Options for types of Models:
Note: Scale can be in form of floating decimal
- 3ds: Scale
- asc: Scale and Swap (boolean)
- md2: Scale
- obj: MTL properties (File path / URI Note: can be empty) and Scale
The property list cannot be empty
-
type
: The type of the model, valid properties are "3ds, asc, md2, obj". Case insensitive.
Initializes the model in the arrangement.
-
arrangement
: Vertical or Horizontal arrangement -
model
: The model that was loaded.
By default, there is no texture applied, this will load the texture into the memory
-
texture
: File path or the URI to the resources image -
textureName
: The name for the texture (an identity)
Note: Don't try to load the texture with the same textureName
more than once.
Applies the texture into the model.
-
model
: The model that was loaded. -
textureName
Is the name of the texture that was loaded.
Sets the background colour of the surface (view) the model is placed in.
ā Examples and blocks
- Loading and Initializing the model
Store the loaded model into a variable, to avoid loading it again over.
- Applying the texture to the model
If you are in companion, only call LoadTexture once even if you refresh the companion.
- Working with SAF
Since the extension also accepts URI objects, you can use the SAF extension by @vknow360.
ā Download extension
xyz.kumaraswamy.themodel.aix (156.5 KB)
This extension was created with Rush by @shreyash
Feel free to suggest new things
Thanks!