Author Topic: Minimal Grid  (Read 4637 times)

Offline Phrog30

  • Hero Member
  • *****
  • Posts: 1234
    • View Profile
Minimal Grid
« on: September 01, 2015, 08:23:01 PM »
Sorry if this has been discussed before, but I was having issues with Morphs and not starting and stopping at the correct time.  I remembered reading about changing the model to minimal grid so I went through and made these changes.  This fixed the timing issue, but introduced another where part of the model is cut off.  I spent an hour playing with XML files, deleting and recreating models, etc., but I can't find a fix.  I noticed in the effect assist that it actually shows the morph stopping short (right side) and starting late (missing top row).  I tried updating the effect, recreating the effect, rendering, saving... nothing seems to help.  I change the model group back to 400, it will include everything, but of course, the timing is not quite right.

Can anyone help me on this?

Thanks in advance,
James

Offline Gilrock

  • Supporting Member
  • Hero Member
  • *
  • Posts: 6946
    • View Profile
Re: Minimal Grid
« Reply #1 on: September 01, 2015, 10:56:36 PM »
Let me look into it.  It's in the calculation that tries to determine the midpoint percentage value for the column.  I tested values of 0 to 100 which work fine but you get up to the larger models like 300 columns a 100% value calculates out to column 297 instead of 299.  So it's just a less than 1% error that didn't matter for the smaller model values I tested on the spreadsheet when Dave and I were talking out how to create the percentage.

Offline Gilrock

  • Supporting Member
  • Hero Member
  • *
  • Posts: 6946
    • View Profile
Re: Minimal Grid
« Reply #2 on: September 01, 2015, 11:26:40 PM »
Ok I think I figured out the best way to tackle this and checked in the change.

Offline Phrog30

  • Hero Member
  • *****
  • Posts: 1234
    • View Profile
Re: Minimal Grid
« Reply #3 on: September 02, 2015, 05:07:29 AM »
Awesome Gil! Thank you so much.

Offline Phrog30

  • Hero Member
  • *****
  • Posts: 1234
    • View Profile
Re: Minimal Grid
« Reply #4 on: September 02, 2015, 05:05:59 PM »
Latest release seems to fix my issues, thanks Gil.

Offline Charles Belcher

  • Full Member
  • ***
  • Posts: 164
    • View Profile
Re: Minimal Grid
« Reply #5 on: October 01, 2015, 05:24:28 PM »
Sorry if this has been discussed before, but I was having issues with Morphs and not starting and stopping at the correct time.  I remembered reading about changing the model to minimal grid so I went through and made these changes.  This fixed the timing issue, but introduced another where part of the model is cut off.  I spent an hour playing with XML files, deleting and recreating models, etc., but I can't find a fix.  I noticed in the effect assist that it actually shows the morph stopping short (right side) and starting late (missing top row).  I tried updating the effect, recreating the effect, rendering, saving... nothing seems to help.  I change the model group back to 400, it will include everything, but of course, the timing is not quite right.

Can anyone help me on this?

Thanks in advance,
James

James or anyone,

I am three days into programming on xLights.  Can you explain the difference and/or how/when to use the "Layout Mode" categories under "Select Model Group"/"Edit Groups"?

They are listed as

Minimal grid
Grid as per preview
Horizontal as per model
Vertical as per model

Are these settings global or sequence bound or model specific or other?

Thanks,

Charles
« Last Edit: October 01, 2015, 05:34:42 PM by Charles Belcher »
2014 Finalist The Great Christmas Light Fight
2018 All Star The Great Christmas Light Fight

Offline Phrog30

  • Hero Member
  • *****
  • Posts: 1234
    • View Profile
Re: Minimal Grid
« Reply #6 on: October 01, 2015, 06:20:46 PM »
The manual should explain the grid choices: http://nutcracker123.com/nutcracker/releases/xLightsNutcracker4.xUserManual.pdf

Gil recently made minimal grid the default.  In my opinion, I don't know why you would use anything else.  In my understanding, everything is a grid/matrix.  So, if your model/group is 20x20 pixels, having the grid anything other than minimal, or 20x20 is silly to me.  If the grid is bigger than the model/group, then the effect has to move so far in order to reach the first pixel.  That was my initial problem when using the morph effect.

Whatever choice you make they are global/model/group specific (kind of one in the same).

I hope this helped.

James

Offline Gilrock

  • Supporting Member
  • Hero Member
  • *
  • Posts: 6946
    • View Profile
Re: Minimal Grid
« Reply #7 on: October 01, 2015, 06:34:43 PM »
I believe the reason "Grid as per preview" is there was because that matched how the original Whole House Models were created.  So if you had created sequences with the earlier WHMs you would have used that option to keep the effects looking the same.  Dan explained what the horizontal and vertical options did somewhere around here.  I'd have to inspect the code to figure it out.

Offline Phrog30

  • Hero Member
  • *****
  • Posts: 1234
    • View Profile
Re: Minimal Grid
« Reply #8 on: October 01, 2015, 06:37:13 PM »
Good to know Gil, thanks for the info.

Offline Charles Belcher

  • Full Member
  • ***
  • Posts: 164
    • View Profile
Re: Minimal Grid
« Reply #9 on: October 01, 2015, 07:30:19 PM »
So the right choice is minimal grid.  My defaults to Grid Size 400.  Is that the right number?

Charles
2014 Finalist The Great Christmas Light Fight
2018 All Star The Great Christmas Light Fight

Offline Gilrock

  • Supporting Member
  • Hero Member
  • *
  • Posts: 6946
    • View Profile
Re: Minimal Grid
« Reply #10 on: October 01, 2015, 07:58:16 PM »
Grid size isn't used for minimal grid.

Offline Phrog30

  • Hero Member
  • *****
  • Posts: 1234
    • View Profile
Re: Minimal Grid
« Reply #11 on: October 01, 2015, 08:02:34 PM »
So the right choice is minimal grid.  My defaults to Grid Size 400.  Is that the right number?

Charles

It's the default now.  If you already had models/groups when Gil updated the code, it would have remained the same.  I went through and changed all of mine to minimal grid.  If yours has 400, then it's not set to minimal.

James

Offline RGBNoob

  • Newbie
  • *
  • Posts: 35
    • View Profile
Re: Minimal Grid
« Reply #12 on: October 04, 2015, 03:05:43 PM »
So the right choice is minimal grid.  My defaults to Grid Size 400.  Is that the right number?

Charles

It's the default now.  If you already had models/groups when Gil updated the code, it would have remained the same.  I went through and changed all of mine to minimal grid.  If yours has 400, then it's not set to minimal.

James

Just want to make sure I have this set up correctly.  I have all of my groups set up for Minimal Grid, but they all also show a Grid Size of 400.  If Grid Size doesn't apply to Minimal Grid I would have expected it to be grayed out and not editable. 

As it is, I can select Minimal Grid and also choose a Grid Size (yes I saved my changes by Updating Group and clicking Save on the Layout screen and also restarted the application for good measure).  See the attached photo. 

Is it really using Minimal Grid or a Grid Size of 400?

Offline Phrog30

  • Hero Member
  • *****
  • Posts: 1234
    • View Profile
Re: Minimal Grid
« Reply #13 on: October 04, 2015, 04:58:05 PM »
You are right, with minimal grid it will still let you change the grid. I can tell you that with a grid of 400 morphs don't work correctly on my layout. Minimal grid works fine, so that tells me even though you can change the value, it's ignored.

James

Offline RGBNoob

  • Newbie
  • *
  • Posts: 35
    • View Profile
Re: Minimal Grid
« Reply #14 on: October 04, 2015, 05:15:38 PM »
You are right, with minimal grid it will still let you change the grid. I can tell you that with a grid of 400 morphs don't work correctly on my layout. Minimal grid works fine, so that tells me even though you can change the value, it's ignored.

James

I don't know if I was lucky or not, but I chose Minimal Grid for a group then chose 200 for Grid Size as a test (like the photo in my post above).  After restarting, the model preview was zoomed in on just the elements in the group, so I don't know if I luckily chose the correct number or it just gets ignored when Minimal Preview is selected.