Re: [Flashcoders] tint a movieclip

2010-05-20 Thread Henrik Andersson

That number does not have any multipliers.

Multipliers are not raw colors. They are an effect that you do to the 
colors of some object. They depend on what the original color was.

___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


RE: [Flashcoders] tint a movieclip

2010-05-20 Thread Mendelsohn, Michael
Thanks JC, I think that's it!  

- MM


are you looking for something like this:

var red:Number = (pColorValue >> 16) & 0xff;
var green:Number = (pColorValue >> 8) & 0xff;
var blue:Number = (pColorValue ) & 0xff;

___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


Re: [Flashcoders] tint a movieclip

2010-05-20 Thread Hans Wichman
Hi Michael,

are you looking for something like this:

var red:Number = (pColorValue >> 16) & 0xff;
var green:Number = (pColorValue >> 8) & 0xff;
var blue:Number = (pColorValue ) & 0xff;

regards
JC

On Thu, May 20, 2010 at 3:07 PM, Mendelsohn, Michael <
michael.mendels...@fmglobal.com> wrote:

> Thanks, Juan.
>
> What I'm really looking for is how to extract values for redMultiplier,
> greenMultiplier and blueMultiplier out of a given color hex value, say
> #336699.
>
> - Michael M.
>
> ___
> Flashcoders mailing list
> Flashcoders@chattyfig.figleaf.com
> http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
>
___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


RE: [Flashcoders] tint a movieclip

2010-05-20 Thread Mendelsohn, Michael
Thanks, Juan.

What I'm really looking for is how to extract values for redMultiplier, 
greenMultiplier and blueMultiplier out of a given color hex value, say #336699. 
 

- Michael M.

___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


[SPAM] Re: [Flashcoders] tint a movieclip

2010-05-19 Thread Latcho
Spam detection software, running on the system "he01.virtec.org", has
identified this incoming email as possible spam.  The original message
has been attached to this so you can view it (if it isn't spam) or label
similar future email.  If you have any questions, see
the administrator of that system for details.

Content preview:  codewise this offers you all the info and possibilities:
  http://www.adobe.com/devnet/flash/articles/matrix_transformations.html
  On 20-05-10 2:42, Juan Pablo Califano wrote: > To apply in code the same
  transform you set at author time in the IDE: > > var
  colTransf:ColorTransform = mc.transform.colorTransform; >
  colTransf.redMultiplier = -0.18; > colTransf.greenMultiplier = -0.42; >
  colTransf.blueMultiplier = 0.22; > colTransf.alphaMultiplier = 0.26; >
  mc.transform.colorTransform = colTransf; > > The left values in the
  panel are the multipliers (one for each channel). > There's a
  difference: in code the values are expressed as normal value in > the
  range 0-1 (whereas in the IDE it's represented as a percetage, 0 - 100).
  > > So the above code will have the same effect as setting the left
  values to > -18%, -42%, 22% and 26%. > > If you want to change the
  values in the right of the panel through code, set > the offsets instead
  (the properties redOffset, greenOffset, etc in the > ColorTransform
  object). They are expressed in the same units both in code > and the
  IDE. > > Cheers > Juan Pablo Califano > > 2010/5/19 Mendelsohn,
  Michael > > >> Hi list... >> >> This is
  probably a bitwise question, which is why I'm posting. I have a >>
  grayscale movieclip and I want to give it a particular hue based on a
  hex >> value. I don't want it to be tint, where it approaches being a
  solid color, >> but rather like watercolors. >> >> Additionally, I know
  that the left side values of the Advanced color pallet >> does this, and
  the right side values are for tinting. I'm just not sure at >> the
  moment how to do that through code. >> >> Thanks if anyone knows! >> -
  Michael M. >> >> >> Flashcoders mailing list >>
  Flashcoders@chattyfig.figleaf.com >>
  http://chattyfig.figleaf.com/mailman/listinfo/flashcoders >> >> > >
  Flashcoders mailing list > Flashcoders@chattyfig.figleaf.com >
  http://chattyfig.figleaf.com/mailman/listinfo/flashcoders > > [...] 

Content analysis details:   (7.2 points, 5.5 required)

 pts rule name  description
 -- --
 1.7 RATWARE_GECKO_BUILDBulk email fingerprint (Gecko faked) found
-0.2 BAYES_40   BODY: Bayesian spam probability is 20 to 40%
[score: 0.2520]
 2.0 RCVD_IN_SORBS_DUL  RBL: SORBS: sent directly from dynamic IP address
[195.240.16.75 listed in dnsbl.sorbs.net]
 1.7 DNS_FROM_RFC_POST  RBL: Envelope sender in
postmaster.rfc-ignorant.org
 2.0 RCVD_IN_PBLRBL: Received via a relay in Spamhaus PBL
[195.240.16.75 listed in zen.spamhaus.org]


___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


Re: [Flashcoders] tint a movieclip

2010-05-19 Thread Juan Pablo Califano
To apply in code the same transform you set at author time in the IDE:

var colTransf:ColorTransform = mc.transform.colorTransform;
colTransf.redMultiplier = -0.18;
colTransf.greenMultiplier = -0.42;
colTransf.blueMultiplier = 0.22;
colTransf.alphaMultiplier = 0.26;
mc.transform.colorTransform = colTransf;

The left values in the panel are the multipliers (one for each channel).
There's a difference: in code the values are expressed as normal value in
the range 0-1 (whereas in the IDE it's represented as a percetage, 0 - 100).

So the above code will have the same effect as setting the left values to
-18%, -42%, 22% and 26%.

If you want to change the values in the right of the panel through code, set
the offsets instead (the properties redOffset, greenOffset, etc in the
ColorTransform object). They are expressed in the same units both in code
and the IDE.

Cheers
Juan Pablo Califano

2010/5/19 Mendelsohn, Michael 

> Hi list...
>
> This is probably a bitwise question, which is why I'm posting.  I have a
> grayscale movieclip and I want to give it a particular hue based on a hex
> value.  I don't want it to be tint, where it approaches being a solid color,
> but rather like watercolors.
>
> Additionally, I know that the left side values of the Advanced color pallet
> does this, and the right side values are for tinting.  I'm just not sure at
> the moment how to do that through code.
>
> Thanks if anyone knows!
> - Michael M.
>
> ___
> Flashcoders mailing list
> Flashcoders@chattyfig.figleaf.com
> http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
>
___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders