--- Chris Moore <[EMAIL PROTECTED]> escribió:

> On 9/15/07, Chris Moore <[EMAIL PROTECTED]> wrote:
> > On 9/14/07, Ulrik Bodén <[EMAIL PROTECTED]>
> wrote:
> > > One question, is it possible to animate the
> gadients just as plain colors? I
> > > can't do that now but do you think Synfig was
> meant to be able to do that?
> >
> > I'm not sure whether it was meant to be able to
> animate between any
> > two gradients - remember that gradients can have
> any number of CPoints
> > in them - they don't just go from one color to
> another.
> >
> > You can animate 2-color gradients using the 'two
> tone' conversion -
> > that lets you define a gradient using 2 colors,
> and you can animate
> > the two colors as usual.  See the attached .sif
> file.
> >
> > I reported a bug about the lack of gradient
> animation a long time ago,
> > before I discovered the 'two tone' conversion:
> >
> >
>
http://sourceforge.net/tracker/index.php?func=detail&aid=1568818&group_id=144022&atid=757416
> 
> OK, I've looked at the code, and it's definitely
> do-able to animate
> gradients.  The only problem is we need to decide
> how it's going to be
> done.
> 
> For example, suppose at time 0s we have a gradient:
> 
> 0.0 white
> 0.1 black
> 0.2 white
> 1.0 white -- that is a gradient that's all white
> except for the very left fifth
> 
> and at time 2s we have a gradient:
> 
> 0.0 white
> 0.8 white
> 0.9 black
> 1.0 white
> 
> what should the gradient look like at time 1s, ie.
> half way between the two?
> 
> should it go:
> 
> 0.0 white
> 0.1 grey
> 0.2 white
> 0.8 white
> 0.9 grey
> 1.0 black -- ie. a simple average of the two
> gradients?
> 
> or should it go
> 
> 0.0 white
> 0.5 grey
> 1.0 white -- since the black is on the left at the
> beginning, and at
> the right at the end, it should be spread all the
> way across in the
> middle?
> 
> or maybe:
> 
> 0.0 white
> 0.4 white
> 0.5 black
> 0.6 white
> 1.0 white -- the black bit stays the same size, but
> moves across from
> left to right?
> 
> or should it do something else?
> 
> The first one is the most generally useful.  I mean,
> what if at 0s
> there were 2 black areas, and at 2s there are 3 red
> areas - what
> happens at 1s?
> 
> If you could think about this it would be useful. 
> Otherwise I'll
> probably go with the simple average (the first case
> above) and see how
> that looks.
> 
> Chris.
> 
> 

I have other idea:

Think about two gradients that you're about to
interpolate from one to other.

Then to do the transition just create another gradient
with a full mix of the CPoints of both gradients. 
Let's say that gradient 1 have N CPoints and gradient
2 have M CPoints. Lets call the CPoints of gradient 1
like CP1-1, CP1-2 ... CP1-N and for gradient 2
something similar: CP2-1, CP2-2 ... CP2-M

The full mixed gradient should have a mixture of CP1
and CP2 CPoints depending on the order they have been
defined on each gradient.

For example:

CP1-1, CP1-2, CP2-1, CP1-3, CP2-2, ... and so on.

Then for a particular frame between the gradient 1 and
gradient 2 definitions you have to interpolate the
color value for every CPoint in this way:

For the gradient 1 the CPoints colors go from its
original value to the interpolated value of that
CPoint at gradient 2. For the CPoints of gradient 2
they go from the interpolated value of that CPoint at
gradient 1 to its original value. 

In this way you don't have to think about move CPoints
and only have a gradient with static CPoints and the
number of CPoints is the same of the mixture of both
gradients. Number of CPoints during transition is N+M.
The N CPoints have a transition from its original to
the interpolated value on the destination and the M
CPoints have a transition from the interpolated values
on the origin to its original. Remember gradient 1 is
origin and gradient 2 is destiny. 

I don't know if I have explained properly... 

-Carlos

-------------------------------------------------------------------------
> This SF.net email is sponsored by: Microsoft
> Defy all challenges. Microsoft(R) Visual Studio
> 2005.
>
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
> _______________________________________________
> Synfig-user mailing list
> Synfig-user@lists.sourceforge.net
>
https://lists.sourceforge.net/lists/listinfo/synfig-user
> 



       
____________________________________________________________________________________
Sé un Mejor Amante del Cine                         
¿Quieres saber cómo? ¡Deja que otras personas te ayuden!
http://advision.webevents.yahoo.com/reto/entretenimiento.html

-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
Synfig-user mailing list
Synfig-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/synfig-user

Reply via email to