Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Remove a color transform?

How do I remove a color transform? (If say, I want to revert back to the original color):

I tried null but this gives me a null error:

my-movieclip-name.transform.colorTransform = null;
like image 935
redconservatory Avatar asked Mar 11 '11 21:03

redconservatory


2 Answers

Just reset the color transform by creating a new instance of it:

myTransform = new ColorTransform();
like image 190
jpea Avatar answered Oct 23 '22 01:10

jpea


instead of recreating a ColorTransform object you can reset the current one as follows:

myTransform.redMultiplier = 1;

myTransform.greenMultiplier = 1;

myTransform.blueMultiplier = 1;

myTransform.redOffset = 0;

myTransform.greenOffset = 0;

myTransform.blueOffset = 0;
like image 36
YopSolo Avatar answered Oct 23 '22 00:10

YopSolo