V4 beta Jan-22-2020 available now
 1-12  …  113-132  133-152  153-172  173-178

Previous
Next
 From:  Larry Fahnoe (FAHNOE)
9660.153 In reply to 9660.151 
Hi Michael,

Many thanks for your thorough answer and example!

--Larry
  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged

Previous
Next
 From:  pafurijaz
9660.154 
There's a command for deleting empty layers?
  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged

Previous
Next
 From:  Frenchy Pilou (PILOU)
9660.155 In reply to 9660.154 
I believe this ;)

script:/*Purge Styles*/var gd = moi.geometryDatabase; var styles = gd.getObjectStyles(); var counts = new Array(styles.length); for ( var i = 0; i < counts.length; ++i ) { counts[i] = 0; } var objs = gd.getObjects(); for ( var i = 0; i < objs.length; ++i ) { var obj = objs.item(i); if ( obj.styleIndex < counts.length ) ++counts[obj.styleIndex]; var subobjs = obj.getSubObjects(); for ( var j = 0; j < subobjs.length; ++j ) { var subobj = subobjs.item(j); if ( subobj.styleIndex < counts.length ) ++counts[subobj.styleIndex]; } } for ( var i = 0; i < styles.length; ++i ) { if ( counts[i] == 0 ) styles.item(i).remove(); }
---
Pilou
Is beautiful that please without concept!
My Moi French Site My Gallery My MagicaVoxel Gallery
  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged

Previous
Next
 From:  pafurijaz
9660.156 In reply to 9660.155 
Great and thanks is a bit long but it's works well when I pasted in command field.
  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged

Previous
Next
 From:  Michael Gibson
9660.157 In reply to 9660.156 
Hi pafurijaz, you can also set it on a shortcut key if that is more convenient.

- Michael
  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged

Previous
Next
 From:  pafurijaz
9660.158 In reply to 9660.157 
Yeah I will do :)
  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged

Previous
Next
 From:  moritzbock (MORITZ)
9660.159 In reply to 9660.157 
Hello, Michael,
would it be possible to add a column in the options/keyboard shortcuts for the description of the shortcuts for information purposes?
-moritz


Attachments:

  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged

Previous
Next
 From:  Frenchy Pilou (PILOU)
9660.160 In reply to 9660.159 
Normally you have a speed description in the Script itself
script: /* Show objects, or isolate */ var objs = moi.geometryDatabase.getObjects(); var any_hidden = false; for ( var i = 0; i < objs.length && !any_hidden; ++i ) { any_hidden = objs.item(i).hidden; } if ( any_hidden ) { objs.setProperty( 'hidden', false ); } else { for ( var i = 0; i < objs.length; ++i ) { var obj = objs.item(i); if ( !obj.selected ) obj.hidden = true; } }

If it's a direct function you can write
rebuild /*for rebuild a curve*/
  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged

Previous
Next
 From:  Michael Gibson
9660.161 In reply to 9660.159 
Hi moritz,

re:
> Hello, Michael,
> would it be possible to add a column in the options/keyboard shortcuts for the description of the shortcuts for information purposes?

The ones that are just command names are pretty self descriptive, like "Delete", "New", "Open", "Save", etc... Do you really need more information on those ones?

For the ones that have script code, you can put in a description as a /* comment */ like you have on these:


What I would like to do eventually is to have just the shortcut key and a description there and not anything else, that needs another mechanism like a "script library" set up first though where there can be some kind of list of scripts in different categories with descriptions along with them.

- Michael

  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged

Previous
Next
 From:  moritzbock (MORITZ)
9660.162 In reply to 9660.161 
... For the ones that have script code, you can put in a description as a /* comment */ like you have on these ...

Hi French Pilou, hi Michael, I was not aware of this possibility - thank you very much
-moritz
  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged

Previous
Next
 From:  Frenchy Pilou (PILOU)
9660.163 In reply to 9660.162 
PS you can call a function by of course a ShortCut but also
by Press TAB then write Rebuild or REbuild REBUILD or RebuilD or rebuild etc...but without espace :)
---
Pilou
Is beautiful that please without concept!
My Moi French Site My Gallery My MagicaVoxel Gallery
  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged

Previous
Next
 From:  Rich (-RB-)
9660.164 
Hi Michael,

May have already been mentioned (apologies if so the thread is quite lengthy now) but I'm getting aliasing issues when I add a dimension...(Windows 10, NVidia 1080TI)






  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged

Previous
Next
 From:  Michael Gibson
9660.165 In reply to 9660.164 
Hi Rich, that's a type of display artifact called "stippling" which can happen in various circumstances.

When MoI draws curves, it pulls them forward towards the eye point slightly so that they will draw on top surfaces that the curves are on.

It's difficult for the display engine to determine a perfect amount of "pull" without doing a lot of calculations that would slow down the display and if it isn't quite enough you will get that kind of display problem. When it pulls too much then it can get "bleed through" instead.

I have some ideas on how to improve that in the future but for now it's just something to ignore.

- Michael
  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged

Previous
Next
 From:  Michael Gibson
9660.166 In reply to 9660.164 
It probably happens in your case here because the dimension goes on the construction plane and maybe your object is some distance away from there?

When the bounding box size of the entire scene changes that tends to have an effect on the z-pull factor.

- Michael
  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged

Previous
Next
 From:  Rich (-RB-)
9660.167 In reply to 9660.166 
Ahhhh yes the bounding box does sound like a good explanation! All good just figured it may have been something to bring up!

- Rich
  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged

Previous
Next
 From:  wayne hill (WAYNEHILL5202)
9660.168 
Hi Michael,

I am working with curves and noticed there is no starting arc angle definition.

There is the "crv.conicEndAngleRadians". Is there a possibility of adding a "crv.conicStartAngleRadians" definition?

The start point angle radians can be calculated from the other definitions, but it would be simpler to use just one.

Thank you,

Wayne
  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged

Previous
Next
 From:  Michael Gibson
9660.169 In reply to 9660.168 
Hi Wayne, it should be orienting the frame of the arc so that the x-axis is pointing at the start of the arc so the start angle is always zero.

- Michael
  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged

Previous
Next
 From:  wayne hill (WAYNEHILL5202)
9660.170 In reply to 9660.169 
Hi Michael,

I am not familiar orienting the frame. Something for me to research today. What lead me to ask was while working with partial arcs in quadrants not starting at zero angle.

Thank you,

Wayne
  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged

Previous
Next
 From:  Michael Gibson
9660.171 In reply to 9660.170 
Hi Wayne, the frame is the plane that the arc is in. The plane has an xaxis and yaxis like this:




The arc starts on the frame's xaxis at an angle of 0, and travels counter-clockwise and ends at the end angle:



- Michael

  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged

Previous
Next
 From:  wayne hill (WAYNEHILL5202)
9660.172 In reply to 9660.171 
Thank you for the information.
Wayne
  Reply Reply More Options
Post Options
Reply as PM Reply as PM
Print Print
Mark as unread Mark as unread
Relationship Relationship
IP Logged
 

Reply to All Reply to All

 

 
Show messages:  1-12  …  93-112  113-132  133-152  153-172  173-178