TV_SaveImage with a different height and width

A forum dedicated to George scripting questions
Post Reply
Kylerk
Posts: 47
Joined: 18 Jun 2011, 13:43

TV_SaveImage with a different height and width

Post by Kylerk »

I am writing a george script that uses the TV_SaveImage.

I need to save a smaller size image than the original. This is easy to do in the " Export to " menu. But I can't find a way to do it in George script . Is there a parameter I am missing?

Another smaller thing I would like to know is if there is an easy way to pad numbers converting something like 7 into 007? I could write code to do it, but is there a built in method?

thanks for your help.

Kyler
Svengali
Posts: 1557
Joined: 28 Dec 2006, 10:08

Re: TV_SaveImage with a different height and width

Post by Svengali »

Kyler,

You might try some variation of this script which captures the Display as a brush, rescales the brush and writes out the result as an image file.

The TVPaint - Basic.grg INCLUDE George file has character string functions that should help.

Sven
Attachments
SaveBrush.grg
(1.24 KiB) Downloaded 159 times
Kylerk
Posts: 47
Joined: 18 Jun 2011, 13:43

Re: TV_SaveImage with a different height and width

Post by Kylerk »

I can make the script you gave me work perfectly.

I'm not sure where I find the basic.grg george script? Is it part of TVpaint Pro? I only have standard edition.

Thanks for your help.
Svengali
Posts: 1557
Joined: 28 Dec 2006, 10:08

Re: TV_SaveImage with a different height and width

Post by Svengali »

I think BASIC.GRG should be included during your original install process in either the George folder or the Include folder inside of the George folder. Otherwise, ask management (Elodie, Fabrice or Herve).

Sven
Post Reply