Author Topic: Morph Effect  (Read 6565 times)

Offline Gilrock

  • Supporting Member
  • Hero Member
  • *
  • Posts: 6946
    • View Profile
Morph Effect
« on: March 01, 2015, 07:43:00 PM »
I know I'm supposed to be fixing bugs but I just had to get started on this.  I've been wanting an effect like this and spent the past day developing it.  I've still got some things I want to add and a couple minor things I want to fix but checkout this video of me playing around testing the effect.  See how I overlapped 4 of them using the new layers.  I've followed the Nutcracker philosophy where everything scales to whatever model you drop it on but I'll make sure there is a way to fine tune the placement if you're looking for something exact.

http://youtu.be/hpj0OmDS2m4

Offline mararunr

  • Sr. Member
  • ****
  • Posts: 271
    • View Profile
    • Bentonville Heart Lites
Re: Morph Effect
« Reply #1 on: March 02, 2015, 02:30:01 PM »
+1 - very nice.  Finally got to play with XL4 in earnest last night and it was an absolute blast.  I'm excited to do more sequence (versus dreading).  Keep up the great work Gil (and to the others as well).
Bentonville Heart Lites (www.facebook.com/bheartlites)

Offline flyinverted

  • Administrator
  • Hero Member
  • *****
  • Posts: 756
    • View Profile
Re: Morph Effect
« Reply #2 on: March 02, 2015, 05:11:17 PM »
Hey Gil.. you Rock!
Steve Giron
Maricopa County, AZ
xLights user with a boat-load of channels.

Do not ask to know all the answers, but ask to understand the question.

Offline danj

  • Hero Member
  • *****
  • Posts: 895
    • View Profile
Re: Morph Effect
« Reply #3 on: March 02, 2015, 08:08:27 PM »
Can't wait to really get into XL4, especially the multiple layering aspect...  Thanks so much to Gil and others on the dev team.  Can't tell you thanks enough times for what you do.

Offline Gilrock

  • Supporting Member
  • Hero Member
  • *
  • Posts: 6946
    • View Profile
Re: Morph Effect
« Reply #4 on: March 04, 2015, 10:00:49 PM »
Here's another short video showing some testing with the morph effect.  At the end it goes to the Preview screen where you can see the colors better.  I have the same channels mapped to a dummy matrix above the tree so you can see the effect playing in two orientations.

The special test here was the last section I created 30 layers on a single model and dropped a morph effect on every layer.  I was really pleased it didn't seem to bog down at all.

https://www.youtube.com/watch?v=PTfYJrbSfbA

Offline sean

  • Administrator
  • Hero Member
  • *****
  • Posts: 1727
    • View Profile
    • Xlights and Nutcracker Forum
Morph Effect
« Reply #5 on: March 05, 2015, 07:43:42 AM »
Kudos to you Gil for creating the morph effect and to Dan kulp for making the engine that can render 30 effects at once.


Sent from my iPhone using Tapatalk
« Last Edit: March 05, 2015, 08:04:20 AM by sean »
Sean
Littleton, CO
Latest releases http://nutcracker123.com/nutcracker/releases
xLights/Nutcracker Forum http://nutcracker123.com/forum/index.php
Fbook [url=https://www.facebook.com/groups/62

Offline Gilrock

  • Supporting Member
  • Hero Member
  • *
  • Posts: 6946
    • View Profile
Re: Morph Effect
« Reply #6 on: March 05, 2015, 01:59:37 PM »
Yep it's nice to have several talented guys working on this.  I told them all to let me know if they ever need a job. :)

Offline arw01

  • Full Member
  • ***
  • Posts: 191
    • View Profile
Re: Morph Effect
« Reply #7 on: March 08, 2015, 11:13:47 AM »
Gil would you mind explaining how the morph works, I especially liked towards the last of the second video, that looked like it could be interesting for fireworks efects.

Alan

Offline Gilrock

  • Supporting Member
  • Hero Member
  • *
  • Posts: 6946
    • View Profile
Re: Morph Effect
« Reply #8 on: March 09, 2015, 07:20:02 AM »
Basically you can define it with 2, 3, or 4 points.  Technically its always 4 points but you can link the start or the end points into the same point so when I call something a vector if the points are at the same location it becomes a vector with a length of 1 which is basically a point.

The morph always moves from the start vector to the end vector.  With the various ways you can place the points you can create shapes like a line, a rectangle, any 4 sided polygon, a triangle with the start a point and the end a vector, a triangle with the start a vector and the end a point, an hourglass shape where the end vectors cross somewhere between the start and end, etc.  You can have it run anywhere across the model so it can take up the whole model or just a small piece of it.  So when you use several morphs on a model you want to set the blend mode to 1 Reveals 2 so that it lets the other morphs show through in the areas where pixels are black.

On the Start Tab you define the X/Y for two points 1a and 1b. If you check Link Points then it uses 1a for both points to make it easier to define a line instead of a region.
Same thing on the End tab. You are defining the vector where the effect will end.
You can do some pretty neat things where you reverse the points for the start or end vectors and cause the morph to look like it's twisting.

The length slider on the Start and End tabs defines the size of the head at the start and end of the morph so you can make it grow, shrink, stay the same, or drag it to zero to delete it.

The head duration on the options panel sets the amount of time the head takes to travel from start to end.
So if you have an effect length of 10 sec and drag the slider to 30% the head will take 3 seconds to travel from the defined start and end points and 7 seconds for the tail to make it across.

Colors: It uses the first 4 color palettes to define the head and tail colors.
Color 1: defines the starting color of the head
Color 2: defines the ending color of the head
Color 3: defines the starting color of the tail
Color 4: defines the ending color of the tail

If you want it to look like the tail is fading out then select Black for Color4.

Offline mararunr

  • Sr. Member
  • ****
  • Posts: 271
    • View Profile
    • Bentonville Heart Lites
Re: Morph Effect
« Reply #9 on: March 09, 2015, 08:42:29 AM »
Wow, I'm going to have to go back and watch the videos again to piece all that together.  Sounds amazing though.
Bentonville Heart Lites (www.facebook.com/bheartlites)

Offline Gilrock

  • Supporting Member
  • Hero Member
  • *
  • Posts: 6946
    • View Profile
Re: Morph Effect
« Reply #10 on: March 09, 2015, 08:53:58 AM »
I hope to make it easier to define the points in the future but it will take some work.  It's a little cumbersome to use sliders to define where the points are.  I'd like to create a method that lets you graphically draw where you want the vectors to be and to adjust the points.  But I need to get some more important stuff working first like the playback in the grid.