Qmaze2D How To/en/functions

From QmazeWiki
Jump to: navigation, search

Back to the manual

Explanation per individual function


Here you can find all the documentation for each individual functions.
How to use the functions, what they do and more.


If you wish to try out the functions in a safe and easy-to-use enviroment, visit: Demo


Adding / altering (existent) objects / images:

These functions can be used to add objects / images to the canvas.
If objects already exist they will be altered.


Function name:

setcanvas



Function description:
Changes the default canvas to a fabric canvas.

Function structure:
x3d(object).setcanvas;
setcanvas('object');

Example:
x3d(c).setcanvas;
setcanvas('c');
The objects(id) must be the same as

Returns:
canvas




Function name:

settext



Function description:
Adds a text object to a canvas or changes the text of an already existent text object.

Function structure:
x3d(object).settext = value
settext('object','value');

Example:
x3d(welcometext).settext = Hello World!
settext('welcometext','Hello World!');
In case a text object already exists; When the id matches that of an already existent text object, the text of this object is then replaced by the given value.
If you wish to split a sentence (enter), you can use \n.
An example of this: x3d('welcomeimg').settext = Hello \n World! or settext('welcomeimg','Hello \n World!');

Returns:
add: object
alter: object or 'error'



Function name:

setimage



Function description:
Adds a image to a canvas or changes the source/url or data string of an already existent image.

Function structure:
x3d(object).setimage = source/url/data-string
setimage('object','source/url/data-string);

Example:
x3d('welcomeimg').setimage = /Images/pug.png
setimage('welcomeimg','/Images/pug.png');
In case a image already exists; When the id matches that of an already existent image, the source/url or datastring of this image will be replaced by the given value.
supported: source/url/data/svg

Returns:
add: object
alter: object or 'error'



Function name:

setbgimg



Function description:
Adds a background image to a canvas or changes the current background image, the image fills the entire canvas.

Function structure:
x3d(object).setbgimg = source/url/data-string
setbgimg('object','source/url/data-string);

Example:
x3d(bgimg).setbgimg = /Images/pineapples.png
setbgimg('bgimg','/Images/pineapples.png');
In case a background image already exists; When the id matches that of an already existing background image, the source/url or data string of this background image will be replaced by the given value.
When you add a background image with another id whilst a background image is already active on that canvas, the lastest added background image will be the one shown because of the layering structure. (see setz)

Returns:
object



Function name:

setrectangle



Function description:
Adds a rectangle to a canvas or changes an already existent rectangle. ( position, height and width )

Function structure:
x3d(object).setrectangle = x1,y1,x2,y2
setrectangle('object','x1,y1,x2,y2');

Example:
x3d(newrect).setrectangle = 50,50,100,100
setrectangle('newrect','50,50,100,100');
The rectangle in this example starts ( starting top left (0,0)) 50 pixels to the right and 50 pixels to the bottom.
In case a rectangle with this id is already existent, the locations ( and the width,height ) are changed.

Returns:
add: object
alter: object or 'error'



Function name:

setcircle



Function description:
Adds a circle to a canvas or changes an already existent circle. ( position and radius )

Function structure:
x3d(object).setcircle = x,y,radius
setcircle('object','x,y,radius');

Example:
x3d(newcircle).setcircle = 50,50,25
setcircle('newcircle','50,50,25');
The circle in this example starts ( starting top left (0,0)) 50 pixels to the right and 50 pixels to the bottom and gets a 25 pixel radius.
In case a circle with this id is already existent, the location and radius is changed.

Returns:
add: object
alter: object or 'error'



Function name:

settriangle



Function description:
Adds a triangle to a canvas or changes an already existent circle. ( position, height and width )

Function structure:
x3d(object).settriangle = x,y,width,height
settriangle('object','x,y,width,height');

Example:
x3d(newtriangle).settriangle = 50,50,75,75
settriangle('newtriangle','50,50,75,75');
The triangle in this example starts ( starting top left (0,0)) 50 pixels to the right and 50 pixels to the bottom and get a 75 pixels height and a 75 pixels width.
In case a triangle with this id is already existent, the location, height and width are changed.

Returns:
add: object
alter: object or 'error'



Function name:

setpolygon



Function description:
Adds a polygon to a canvas or changes an already existent polygon, the begin and endpoint always connect. ( positions)

Function structure:
x3d(object).setpolygon = x1,y1,x2,y2 etc.
setpolygon('object','x1,y1,x2,y2 etc.');

Example:
x3d(newpoly).setpolygon = 20,0,40,50,60,80,40,70,20,60
setpolygon('newpoly','20,0,40,50,60,80,40,70,20,60');
The polygon in this example starts ( starting top left (0,0)) 20 pixels to the right and 0 pixels to the bottom, the second point is 40 pixels to the right and 50 pixels to the bottom etc.
The end of the polygon always connects with the beginpoint.
In case a triangle with this id is already existent, the points get changed.

Returns:
add: object
alter: object or 'error'



Function name:

setarrows



Function description:
Adds a line to the canvas with 2 arrowpoints or replaces an already existing arrow/line.

Function structure:
x3d(object).setarrows = x1,y1,x2,y2
setarrows('object','x1,y1.x2.y2');

Example:
x3d(newarrow).setarrows = 100,100,300,300
setarrows('newarrow','100,100,300,300');
The arrow in this example starts ( starting top left (0,0)) 100 pixels to the right and 100 pixels to the bottom and stops 300 pixels to the right and 300 pixels to the bottom.
In case a arrow with this id is already existent (setline,setarrow,setarrows), the positions are replaced with the given value and if required arrowpoints are added/removed.

Returns:
object(s) or 'error'



Function name:

setarrow



Function description:
Adds a line to a canvas with 1 arrowpoint or replaces an already existing arrow/line.

Function structure:
x3d(object).setarrow = x1,y1,x2,y2
setarrow('object','x1,y1,x2,y2');

Example:
x3d(newarrow).setarrows = 100,100,300,300
setarrow('newarrow','100,100,300,300'); The arrow in this example starts ( starting top left (0,0)) 100 pixels to the right and 100 pixels to the bottom and stops 300 pixels to the right and 300 pixels to the bottom.
In case a arrow with this id is already existent (setline,setarrow,setarrows), the positions are replaced with the given value and if required arrowpoints are added/removed.

Returns:
object(s) or 'error'



Function name:

setline



Function description:
Adds a line to a canvas or replaces an already existing arrow/line.

Function structure:
x3d(object).setline = x1,y1,x2,y2
setline('object','x1,y1,x2,y2');
Example:
x3d(newarrow).setline = 100,100,300,300
setline('newarrow','100,100,300,300');
The arrow in this example starts ( starting top left (0,0)) 100 pixels to the right and 100 pixels to the bottom and stops 300 pixels to the right and 300 pixels to the bottom.
In case a arrow with this id is already existent (setline,setarrow,setarrows), the positions are replaced with the given value and if required arrowpoints are added/removed.

Returns:
object or 'error'



Altering existent objects / images

These functions alter an already existent object' / image' property.

Function name:

setcolor



Function description:
Changes the color of an object.

Function structure:
x3d(object).setcolor = value
setcolor('object','value');

Example:
x3d(welcometext).setcolor = red
setcolor('welcometext','red');
When the object is a canvas the background color is changed to the given value.
The value can be a color in: string, hex and rgb.

Returns:
object or 'error'



Function name:

setdraggable



Function description:
Changes the object to be static or dynamic ( user interaction )

Function structure:
x3d(object).setdraggable = value
setdraggable('object','value');

Example:
x3d(welcomeimg).setdraggable = 1
setdraggable('welcomeimg','1');
The value can either be 1 or 0, where 0 makes the object static and 1 makes the object draggable.
Objects that are NOT draggable will still have events, the user will not be able to move/scale/rotate the object/image.
Returns:
object or 'error'



Function name:

setanimationduration



Function description:
Changes the duration of animations.

Function structure:
x3d().setanimationduration = duration
setanimationduration('duration');

Example:
x3d(object).setanimationduration = 1000
setanimationduration('1000'); In this example the animation duration is set to 1000ms (1 second).
The animation duration counts for all animations until it is altered again.

Returns:
animation duration or 'error'



Function name:

setanimationtype



Function description:
Changes which animation is played when positions change.

Function structure:
x3d().setanimationtype = value
setanimationtype('value');

Example:
x3d().setanimationtype = easeInOutBounce
setanimationtype('easeInOutBounce');
In this example the animation type is set to InOutBounce, this makes the object 'bounce' at the end of an position change.
The animation type counts for all animations until it is altered again.

Returns:
animation name or 'error'



Function name:

sethandles



Function description:
Changes the handles of an object depended on the value.

Function structure:
x3d(object).sethandles = value
sethandles('object','value');
Example:
x3d(newrect).sethandles = 2
sethandles('newrect','2');
Changes which lines and or user interactive corners are visible.

Returns:
object or 'error'



Function name:

sethandlecolor



Function description:
Changes the color of the handles.

Function structure:
x3d(object).sethandlecolor = value
sethandlecolor('object','value');

Example:
x3d(newrect).sethandlecolor = red
sethandlecolor('newrect','red');
This function changes the color of all handlers, visible or invisible.
The value can be a color in: string, hex and rgb.

Returns:
object or 'error'



Function name:

setheight



Function description:
Changes the height of an object in pixels.

Function structure:
x3d(object).setheight = value
setheight('object',value);

Example:
x3d(welcomeimg).setheight = 150
setheight('welcomeimg',150);

Returns:
object or 'error'



Function name:

setwidth



Function description:
Changes the width of an object in pixels.

Function structure:
x3d(object).setwidth = value
setwidth('object',value);

Example:
x3d(welcomeimg).setwidth = 250
setwidth('welcomeimg',250);

Returns:
object or 'error'



Function name:

setscale



Function description:
Changes the width and height of an object or image by scale.

Function structure:
x3d(object).setscale = value
setscale('object',value);

Example:
x3d(welcomeimg).setscale = 0.8
setscale('welcomeimg',0.8)
The value represents the scale on which the object / image is scaled. ( x and y axle )
The value 1 is the original value.

Returns:
object or 'error'



Function name:

setid



Function description:
Changes the id of an already existent object / image.

Function structure:
x3d(object).setid = value
setid('object','value');

Example:
x3d(welcomeimg).setid = goodbyeimg
setid('welcomeomg','goodbyeimg');
The object is the id of an object that is to be changed, the value is to become the new id.
The new id must not be existent on the canvas.

Returns:
object or 'error'



Function name:

setlineheight



Function description:
Changes how much height is between text lines.

Function structure:
x3d(object).setlineheight = value
setlineheight('object',value);

Example: x3d(welcometext).setlineheight = 10 setlineheight('welcometext',10);

Returns:
object or 'error'



Function name:

setrotation



Function description:
Changes the rotation of an object / image.

Function structure:
x3d(object).setrotation = value
setrotation('object',value);

Example:
x3d(welcomeimg).setrotation = 90
setrotation('welcomeimg',90);
The value is the rotation starting from the original rotationpoint (0) in degrees. (celcius)
The object / image is always rotated from its most center point.
This function is animated if an animation is set.

Returns:
object or 'error'



Function name:

setx



Function description:
Changes the position of an object / image on the x-axle. (in pixels where the left is 0)

Function structure:
x3d(object).setx = value
setx('object',value);

Example:
x3d(welcomeimg).setx = 500
setx('welcomeimg',500);
The image in this example will now be placed 500 pixels to the right.
This function can be animated dependend on the animationtype and duration.
Using the setx and sety function together will make the object / image move diagonally.
This function is animated if an animation is set.

Returns:
object or 'error'



Function name:

sety



Function description:
Changes the position of an object / image on the y-axle. (in pixels where the top is 0)

Function structure:
x3d(object).sety = value
sety('object',value);

Example:
x3d(welcomeimg).sety = 200
sety('welcomeimg',200);
The image in this example will now be placed 200 pixels to the bottom.
This function can be animated dependend on the animationtype and duration.
Using the setx and sety function together will make the object / image move diagonally.
This function is animated if an animation is set.

Returns:
object or 'error'



Function name:

setz



Function description:
Changes on which layer the object / image resides. ( where 0 is in the back )

Function structure:
x3d(object).setz = value
setz('object',value);

Example:
x3d(welcomeimg).setz = 10
setz('welcomeimg',10);
The value is the layer on which the object / image is placed, where the layer 0 is in the back.
The object / image that is already active on the chosen layer will be placed 1 place higher into the layers.

Returns:
object or 'error'



Function name:

setstroke



Function description:
Changes the stroke of an object.

Function structure:
x3d(object).setstroke = value
setstroke('object',value);

Example:
x3d(newrect).setstroke = 20
setstroke('newrect',20);
The object gets a line around the object with the size of the value in pixels.

Returns:
object or 'error'



Function name:

setstrokecolor



Function description:
Changes the color of the objects' stroke.

Function structure:
x3d(object).setstrokecolor = value
setstrokecolor('object','value');

Example:
x3d(newrect).setstrokecolor = blue
setstrokecolor('newrect','blue');
The value can be a color in: string, hex and rgb.

Returns:
object or 'error'



Function name:

settextfont



Function description:
Changes the text font of an text object.

Function structure:
x3d(object).settextfont = value
settextfont('object','value');

Example:
x3d(welcometext).settextfont = Arial
settextfont('welcometext','Arial');
The text font must exist, if this is not the case the text font will remain the same. Attention: Case sensitive!
You can download text fonts directly from fonts.google.com or through a url link.

Returns:
object or 'error'



Function name:

settextsize



Function description:
Changes the text size of a text object.

Function structure:
x3d(object).settextsize = value
settextsize('object',value);

Example:
x3d(welcometext).settextsize = 20
settextsize('welcometext',20);
The value is the text size in pixels.

Returns:
object or 'error'



Function name:

settextweight



Function description:
Changes the boldness of an text object.

Function structure:
x3d(object).settextweight = value
settextweight('object',value);

Example:
x3d(welcometext).settextweight = 400
settextweight('welcometext',400);
Possible values: light, normal, bold, number.

Returns:
object or 'error'



Function name:

setvisible



Function description:
Changes the visibility of an object / image / canvas.

Function structure:
x3d(object).setvisible = value
setvisible('object',value);

Example:
x3d(welcometext).setvisible = 0.7
setvisible('welcometext',0.7);
To make the canvas visible or invisible the value must be either 1 or 0 where 0 makes it invisible and 1 makes it visible.
To make an object / image visible or invisible the value must be between 0 and 1, where 1 is visible and 0 is invisible, decimals may be used.
This function is animated if an animation is set.

Returns:
object or 'error'



Function name:

setflipx



Function description:
Flips the object / image around. (Horizontally)

Function structure:
x3d(object).setflipx = value
setflipx('object','value');
Example:
x3d(welcomeimg).setflipx = true
setflipx('welcomeimg','true');
The 'value' true flips the object / image around from it original stance, the value 'false' changes it back to it's original stance.
The value 'flip' makes the object / image flip around no matter which stance it currently is.

Returns:
object or 'error'



Function name:

setflipy



Function description:
Flips the object / image around. (Vertically)

Function structure:
x3d(object).setflipy = value
setflipy('object','value');

Example:
x3d(welcomeimg).setflipy = flip
setflipy('welcomeimg','flip');
The 'value' true flips the object / image around from it original stance, the value 'false' changes it back to it's original stance.
The value 'flip' makes the object / image flip around no matter which stance it currently is.

Returns:
object or 'error'



Function name:

setdefault



Function description:
Changes the default properties of which an object / image is loaded in with.

Function structure:
x3d(object).setdefault = property,propertyvalue
setdefault('object','propertympropertyvalue');
Example:
x3d(text).setdefault = fill,red
setdefault('text','fill,red');
Object defines the type of object, this could for example be; 'Text','Image','Rectangle','Arrow','Circle',Etc.
Neither the property, nor the propertyvalue is case sensitive.

Returns:
default properties or 'error'



Function name:

setcornersize



Function description:
Changes the size of the handle corners.

Function structure:
x3d(object).setcornersize = value
setcornersize('object','value');
Example:
x3d(welcomeimg).setcornersize = 8
setcornersize('welcomeimg',8);

Returns:
object or 'error'



Function name:

setcornercolor



Function description:
Changes the color of the handle corners.

Function structure:
x3d(object).setcornercolor = value
setcornercolor('object','value');
Example:
x3d(welcomeimg).setcornercolor = Red
setcornercolor('welcomeimg','Red');

Returns:
object or 'error'



Function name:

setbordercolor



Function description:
Changes the color of the handle line.

Function structure:
x3d(object).setbordercolor = value
setbordercolor('object','value');
Example:
x3d(welcomeimg).setbordercolor = Red
setbordercolor('welcomeimg','Red');

Returns:
object or 'error'



Function name:

settransparentcorners



Function description:
Changes the transparancy of the handle corners.

Function structure:
x3d(object).settransparentborders = value
settransparentborders('object','value');
Example:
x3d(welcomeimg).settransparentborders = true
settransparentborders('welcomeimg',true);

Returns:
object or 'error'



Function name:

setgroup



Function description:
Wraps a fabric group element around one or more object(s).

Function structure:
x3d(group).setgroup = object(s)
setgroup('group','object(s)');
Example:
x3d(welcomegroup).setgroup = welcometext, welcomeimg, welcomesign
setgroup('welcomegroup','welcometext,welcomeimg,welcomesign');

Returns:
group or 'error'



Function name:

settextpattern



Function description:
Lays a (image) pattern over a text object.

Function structure:
x3d(object).settextpattern = src/url
settextpattern('object','src/url');
Example:
x3d(welcometext).settextpattern = Images/pineapples.png
settextpattern('welcometext','Images/pineapples.png');

Returns:
object or 'error'



Function name:

ungroup



Function description:
Removes an already existent group from the canvas.

Function structure:
x3d(group).ungroup = value
ungroup('group','value');
Example:
x3d(welcomegroup).ungroup = 1
ungroup('welcomegroup',1);

Returns:
group or 'error'



Function name:

setdraganddrop



Function description:
Enables/disables html image drag and drop onto the canvas.

Function structure:
x3d().setdraganddrop = value
setdraganddrop(,'value');
Example:
x3d().setdraganddrop = true
setdraganddrop(,true);
Only images with the property: " draggable = 'true' " are draggable onto the canvas.

Returns:
draggable images or 'error'



Function name:

sethue



Function description:
Places a filter above an object / image that changes its hue vibrance.

Function structure:
x3d(object).sethue = value
sethue ('object','value');
Example:
x3d(welcomeimg).sethue = 0.85
sethue ('welcomeimg',0.85);
Values that are allowed are: between -1 and 1 OR -100 and 100.
Returns:
object or 'error



Function name:

setsaturation



Function description:
Places a filter above an object / image that changes its saturation.

Function structure:
x3d(object).setsaturation= value
setsaturation('object','value');
Example:
x3d(welcomeimg).setsaturation = 0.85
setsaturation('welcomeimg',0.85);
Values that are allowed are: between -1 and 1 OR -100 and 100.
Returns:
object or 'error



Function name:

setbrightness



Function description:
Places a filter above an object / image that changes its brightness.

Function structure:
x3d(object).setbrightness = value
setbrightness('object','value');
Example:
x3d(welcomeimg).setbrightness= 0.85
setbrightness('welcomeimg',0.85);
Values that are allowed are: between -1 and 1 OR -100 and 100.
Returns:
object or 'error




Function name:

setgamma



Function description:
Changes the gamma (Red, Green, Blue) of an image.

Function structure:
x3d(object).setgamma= value
setgamma('object','value');
Example:
x3d(welcomeimg).setgamma= 256,0,31
setgamma('welcomeimg','256,0,31');
Values that are allowed are: between 0 and 256.
Values must be written in 'string literals': '256,current,|'
Value must consist of 3 values; Red, Green, Blue. If you wish to only change 1 value for example green you can use 'current' or '|'. Example:
'256,current,34'.
Returns:
object or 'error



Retrieving object / image properties

These functions 'get' a property of the object / image, they return this property and could thus be used for testing or to fill variables for example.


Function name:

getproperty



Function description:
Gets the chosen property (value) of the object / image.

Function structure:
x3d(object).getproperty = value
getproperty('object','value');

Example:
x3d(welcomeimg).getproperty = top
getproperty('welcomeimg','top');
The value is the property you wish to retrieve.

Returns:
propertyvalue



Function name:

getx



Function description:
Gets the x-axle value from the object / image.

Function structure:
x3d(object).getx = value
getx('object');

Example:
x3d(welcomeimg).getx = 1
getx('welcomeimg');
To use this function through the outputscript, you only need to enter an object(id).
To use this function through the rules, you must enter a value of either 1 or 0.
Note: This function returns the value of which the object resides in at that moment and time, if the object is in animation this might not be the end position.

Returns:
x (left) value



Function name:

gety



Function description:
Gets the y-axle value from the object / image.

Function structure:
x3d(object).gety = value
gety('object');

Example:
x3d(welcomeimg).gety = 1
gety('welcomeimg');
To use this function through the outputscript, you only need to enter an object(id).
To use this function through the rules, you must enter a value of either 1 or 0.
Note: This function returns the value of which the object resides in at that moment and time, if the object is in animation this might not be the end position.

Returns:
y (top) value



Function name:

getz



Function description:
Gets the layer on which the object / images resides.

Function structure:
x3d(object).getz = value
getz('object');

Example:
x3d(welcomeimg).getz = 1
getz('welcomeimg');
To use this function through the outputscript, you only need to enter an object(id).
To use this function through the rules, you must enter a value of either 1 or 0.

Returns:
z (layer) value



Function name:

getscale



Function description:
Gets the objects scale (X&Y combined)

Function structure:
x3d(object).getscale = value
getscale('object');

Example:
x3d(welcomeimg).getscale = 1
getscale('welcomeimg');
To use this function through the outputscript, you only need to enter an object(id).
To use this function through the rules, you must enter a value of either 1 or 0.

Returns:
scale (x&y) value



Function name:

getscalex



Function description:
Gets the objects x-axle scale.

Function structure:
x3d(object).getscalex = value
getscalex('object');

Example:
x3d(welcomeimg).getscalex = 1
getscalex('welcomeimg'):
To use this function through the outputscript, you only need to enter an object(id).
To use this function through the rules, you must enter a value of either 1 or 0.

Returns:
scalex value



Function name:

getscaley



Function description:
Gets the objects y-axle scale.

Function structure:
x3d(object).getscaley = value
getscaley('object');

Example:
x3d(welcomeimg).getscaley = 1
getscaley('welcomeimg');
To use this function through the outputscript, you only need to enter an object(id).
To use this function through the rules, you must enter a value of either 1 or 0.

Returns:
scaley value



Function name:

getfilter



Function description:
Gets the objects filter.

Function structure:
x3d(object).getfilter = filtername
getfilter('object', 'filtername');

Example:
x3d(welcomeimg).getfilter = rotation
getfilter('welcomeimg','rotation');

Returns:
filter



Function name:

getfilterindex



Function description:
Gets the index of an objects' filter.

Function structure:
x3d(object).getfilterindex = filtername
getfilterindex('object', 'filtername');

Example:
x3d(welcomeimg).getfilterindex = 'rotation'
getfilterindex('welcomeimg', 'rotation');

Returns:
filter index



Other functions

These functions don't add/alter objects / images.
They are classified as 'other' functions for this reason.


Function name:

copy



Function description:
Copies the chosen object / image and gives it a new id.

Function structure:
x3d(object).copy = value
copy('object','value');

Example:
x3d(welcomeimg).copy = newimage
copy('welcomeimg','newimage');
The new id (value) must be unique. (can't already exist)
Note: When copying an object/image the new object/image will be placed ontop of the copied object/image.

Returns:
cloned object or 'error'



Function name:

delete/deletethis



Function description:
Deletes the chosen object / image from the canvas.

Function structure:
x3d(object).delete = value
deletethis('object');

Example:
x3d(newimage).delete = 1
deletethis('newimage');
If you wish to use this function in the outputscript you must use 'deletethis' otherwise an error will occur.
Using this function in the rules works with both 'delete' and 'deletethis'.
To use this function through the outputscript, you only need to enter an object(id).
To use this function through the rules, you must enter a value of either 1 or 0.

Returns:
'success' or 'error'




Function name:

clearcanvas



Function description:
Removes all objects and images from the canvas.

Function structure:
x3d(object).clearcanvas = value
clearcanvas('object');

Example:
x3d(c).clearcanvas = 1
clearcanvas('c');
To use this function through the outputscript, you only need to enter an object(id).
To use this function through the rules, you must enter a value of either 1 or 0.
The object(id) in this case is that of the canvas.

Returns:
canvas or 'error'



Function name:

screenshot



Function description:
Makes a screenshot of the chosen canvas.

Function structure:
x3d(object).screenshot = value
screenshot('object');

Example:
x3d(c).screenshot = 1
screenshot('c');
To use this function through the outputscript, you only need to enter an object(id).
To use this function through the rules, you must enter a value of either 1 or 0.
The object(id) in this case is that of the canvas.

Returns:
screenshot name or 'error'



Function name:

saveconfig



Function description:
Saves the canvas(ses) data to the server.

Function structure:
x3d(savename).saveconfig = names of canvas(ses) to save
saveconfig('savename','names of canvas(ses) to save';

Example:
x3d(firstdesign).saveconfig = firstcanvas,secondcanvas
saveconfig('firstdesign', 'firstcanvas,secondcanvas');
When no canvas(ses) are chosen, every canvas will get saved.
Returns:
data (log) temporary



Function name:

buildconfig



Function description:
Loads the content from the server into the canvas(ses).

Function structure:
x3d(savename).buildconfig = firstcanvas, secondcanvas
buildconfig('savename', 'firstcanvas,secondcanvas');

Example:
x3d(firstdesign).buildconfig= 1
buildconfig('firstdesign');
To use this function use 'saveconfig' first, make sure the view (savename) is the same as the name used in 'saveconfig' (case sensitive).
Returns:
'succes' (temporary)