Difference between revisions of "PRIM TEXTURE"

From Second Life Wiki
Jump to navigation Jump to search
m
m
Line 32: Line 32:
|text=When used with [[llSetPrimitiveParams]] & [[llSetLinkPrimitiveParams]]
|text=When used with [[llSetPrimitiveParams]] & [[llSetLinkPrimitiveParams]]
====Caveats====
====Caveats====
{{#var:caveats_set}}
{{#var:caveats_set}}{{#vardefine:caveats_set}}
|toc=llSetPrimitiveParams
|i1_type=integer|i1_name=face
|i1_type=integer|i1_name=face
|i2_type=string|i2_name=texture
|i2_type=string|i2_name=texture
Line 43: Line 44:
|text=
|text=
====Caveats====
====Caveats====
{{#var:caveats}}
{{#var:caveats}}{{#vardefine:caveats}}
|toc=llGetPrimitiveParams
|i1_type=integer|i1_name=face
|i1_type=integer|i1_name=face
|r1_type=string|r1_name=texture
|r1_type=string|r1_name=texture

Revision as of 11:10, 23 May 2008

Description

Constant: integer PRIM_TEXTURE = 17;

The integer constant PRIM_TEXTURE has the value 17

Used to get or set the texture settings of a prim's face.

llSetPrimitiveParams

[ PRIM_TEXTURE, integer face, string texture, vector repeats, vector offsets, float rotation_in_radians ]
• integer face face number or ALL_SIDES
• string texture a texture in the inventory of the prim this script is in or a UUID of a texture
• vector repeats x and y range from 0.0 to 100, in 0.01 increments (z is ignored)
• vector offsets x and y range from -1 to 1 (z is ignored)
• float rotation_in_radians angle in radians

When used with llSetPrimitiveParams & llSetLinkPrimitiveParams

Caveats

  • If texture is missing from the prim's inventory and it is not a UUID or it is not a texture then an error is shouted on DEBUG_CHANNEL.
  • If texture is a UUID then there are no new asset permissions consequences for the object.
    • The resulting object develops no new usage restrictions that might have occurred if the asset had been placed in the prims inventory.

llGetPrimitiveParams

llGetPrimitiveParams([ PRIM_TEXTURE, integer face ]);

Returns the list [ string texture, vector repeats, vector offsets, float rotation_in_radians ]

• integer face face number or ALL_SIDES

• string texture a texture in the inventory of the prim this script is in or a UUID of a texture
• vector repeats x and y range from 0.0 to 100, in 0.01 increments (z is ignored)
• vector offsets x and y range from -1 to 1 (z is ignored)
• float rotation_in_radians angle in radians

Caveats

Related Articles

Constants

•  CHANGED_TEXTURE

Functions

•  llSetPrimitiveParams
•  llSetLinkPrimitiveParams
•  llGetPrimitiveParams

Events

•  changed

Deep Notes

Search JIRA for related Issues

Signature

integer PRIM_TEXTURE = 17;