No subject
Sat Apr 19 02:14:48 UTC 2014
representing an image, sound bytes, scriptcode, prim shape definition. But
What happens when a scripted object is rez'ed, the code modifies the state
of the script or prim or the inventory of the object? If a script modifies
the link chain of a set of prims, changes the texture or any other mutable
property on a prim, do we have a new asset? if it is a new asset, do we copy
the textures into this new asset? Is the complete "file" changed, or only
parts of the file?
I know there is a huge debate on this going on on the sldev mailing list,
but I'd prefer to go for something resonably simple and practical, as a
first implementation.
My suggestion is based on the concept of triplets, much like the triplets in
RDF.
Basically an asset can be seen as a collection of values, each value
consists of three properties:
<assetid>, <type>, <value>
to give some examples
texture:
329AE20F-38C1-43fb-BDA0-6B13E569FCDF, Type, Texture
329AE20F-38C1-43fb-BDA0-6B13E569FCDF, Name, "Green grass"
329AE20F-38C1-43fb-BDA0-6B13E569FCDF, Width, 256
329AE20F-38C1-43fb-BDA0-6B13E569FCDF, Height, 256
329AE20F-38C1-43fb-BDA0-6B13E569FCDF, Image,
44BD483173EC206D130B5F775B2B31D.........
329AE20F-38C1-43fb-BDA0-6B13E569FCDF, Owner,
61AEA4D9-19CE-4fac-8E44-DFA24903BFB8
prim
61AEA4D9-19CE-4fac-8E44-DFA24903BFB8, Type, Primitive
61AEA4D9-19CE-4fac-8E44-DFA24903BFB8, Shape, Box
61AEA4D9-19CE-4fac-8E44-DFA24903BFB8, Position,
8D45A164-52B1-4dab-A7BE-53A7078CA50B
8D45A164-52B1-4dab-A7BE-53A7078CA50B, X, 125.7
8D45A164-52B1-4dab-A7BE-53A7078CA50B, Y, 10
8D45A164-52B1-4dab-A7BE-53A7078CA50B, Z, 19
61AEA4D9-19CE-4fac-8E44-DFA24903BFB8, Size,
EA7254C0-D692-436a-949C-ADFE500E85EF
EA7254C0-D692-436a-949C-ADFE500E85EF, Width, 10
EA7254C0-D692-436a-949C-ADFE500E85EF, Height, 2
EA7254C0-D692-436a-949C-ADFE500E85EF, Depth, 0.1
61AEA4D9-19CE-4fac-8E44-DFA24903BFB8, Name, "My plywood box"
On first inspection this seems to be too complex, but this scheme can easily
be extended to handle versioning, so in case somebody renames our texture in
the above example, this can be handled quite easily, by storing this
information:
texture
0CDE3656-D5A1-4ac2-819C-F8285680BC28, Parent,
329AE20F-38C1-43fb-BDA0-6B13E569FCDF
0CDE3656-D5A1-4ac2-819C-F8285680BC28, Name, "Dark green grass"
in essence, this has created a new asset, called
"0CDE3656-D5A1-4ac2-819C-F8285680BC28", which inherits most of it's values
from "329AE20F-38C1-43fb-BDA0-6B13E569FCDF".
This is the strategy, which I'd suggest as a first go for assets, I would
welcome any and all comments
/Tleiades
More information about the Opensim-dev
mailing list