Canvas: Add function to API for getting canvas path
This commit is contained in:
parent
c785b1bd1c
commit
a129877eb8
1 changed files with 6 additions and 1 deletions
|
@ -791,7 +791,12 @@ var Canvas = {
|
|||
# Set the background color
|
||||
#
|
||||
# @param color Vector of 3 or 4 values in [0, 1]
|
||||
setColorBackground: func { _setColorNodes(me.color, arg); return me; }
|
||||
setColorBackground: func { _setColorNodes(me.color, arg); return me; },
|
||||
# Get path of canvas to be used eg. in Image::setFile
|
||||
getPath: func()
|
||||
{
|
||||
return "canvas://by-index/texture[" ~ me._node.getIndex() ~ "]";
|
||||
}
|
||||
};
|
||||
|
||||
# Create a new canvas. Pass parameters as hash, eg:
|
||||
|
|
Loading…
Reference in a new issue