GEORGE : Layer selection Topic is solved
- schwarzgrau
- Posts: 1062
- Joined: 23 Jan 2012, 22:08
- Location: Offenbach / Germany
- Contact:
GEORGE : Layer selection
It would be pretty nice, if you could get the information which layers are selected in George. Also it could be pretty handy if you could select multiple layers in it.
Mac OS X 10.11.6 / TVP 11.0.8 PRO / Cintiq 22HD
Mac OS X 10.11.6 / TVP 11.0.8 PRO / Cintiq Companion 2
SCHWARZGRAU.COM
Mac OS X 10.11.6 / TVP 11.0.8 PRO / Cintiq Companion 2
SCHWARZGRAU.COM
Re: GEORGE : Layer selection
Bumping this request because some tools artists here have requested are entirely impossible without being able to detect multiple selected layers with George.
- NathanOtano
- Posts: 944
- Joined: 01 Apr 2014, 07:07
- Location: Paris, France
- Contact:
Re: GEORGE : Layer selection
Can't you just run on all the layers with tv_layerinfo to check which are selected and put that in a list of variables to interact with? It's less handy that the command you want but such a command would be weird to use. How much variables would you get? How do you code that on your scripts?
Storyboard, animation and design work : http://nathanotano.tumblr.com/
As I'm highly interested in animation workflows, I'm open to scripting new TVP functions for individuals and studios. Please don't hesitate to contact me!
As I'm highly interested in animation workflows, I'm open to scripting new TVP functions for individuals and studios. Please don't hesitate to contact me!
Re: GEORGE : Layer selection
I didn't realise LayerInfo had that info (in fact I didn't realise it could be called on a layer that wasn't the current layer). Thanks for the tip!
I suppose you have a point about how it'd be represented. I forget that George commands can only return simple data structures even though you can make tables/arrays yourself.
I suppose you have a point about how it'd be represented. I forget that George commands can only return simple data structures even though you can make tables/arrays yourself.
- NathanOtano
- Posts: 944
- Joined: 01 Apr 2014, 07:07
- Location: Paris, France
- Contact:
Re: GEORGE : Layer selection
Nice 
You can also create a function for the whole process in one command
and share it here hehe

You can also create a function for the whole process in one command

Storyboard, animation and design work : http://nathanotano.tumblr.com/
As I'm highly interested in animation workflows, I'm open to scripting new TVP functions for individuals and studios. Please don't hesitate to contact me!
As I'm highly interested in animation workflows, I'm open to scripting new TVP functions for individuals and studios. Please don't hesitate to contact me!
Re: GEORGE : Layer selection
I have!
I'm sure there's improvements that could be made (like a better way to iterate over layers) but this does the job for me. Here's the function:
Also some sample usage:
I'm sure there's improvements that could be made (like a better way to iterate over layers) but this does the job for me. Here's the function:
Code: Select all
FUNCTION get_selected()
select_count = 0
FOR id = 1 to 10000
tv_LayerInfo id
PARSE result layerDisplay layerPosition layerOpacity layerName layerType layerStart layerEnd layerPrelighttable layerPostlighttable selected x
IF (CMP(selected,'1') == 1)
select_count = select_count + 1
selected[select_count] = id
END
END
return selected
END
Code: Select all
get_selected()
selected = result
FOR x = 1 to select_count
tv_warn "ID"selected[x]
END
- Hironori Takagi
- Posts: 69
- Joined: 14 May 2018, 10:15
- Location: Tokyo, Japan
- Contact:
Re: GEORGE : Layer selection
The layerselection item in tv_layerinfo is not listed on tvpaintwiki, but it is described in the TVPaint 11 Documentation published last year.
https://www.tvpaint.com/doc/tvpaint-ani ... _layerinfo
https://www.tvpaint.com/doc/tvpaint-ani ... _layerinfo
TVPaint 11.0.9, Windows10 Pro, DELL Precision M3800 / Mac OS 10.15, Apple Mac Pro(Late 2013)
- NathanOtano
- Posts: 944
- Joined: 01 Apr 2014, 07:07
- Location: Paris, France
- Contact:
Re: GEORGE : Layer selection
Nice thanks 

Storyboard, animation and design work : http://nathanotano.tumblr.com/
As I'm highly interested in animation workflows, I'm open to scripting new TVP functions for individuals and studios. Please don't hesitate to contact me!
As I'm highly interested in animation workflows, I'm open to scripting new TVP functions for individuals and studios. Please don't hesitate to contact me!