screen space move

Next
 From:  pior (PIOR_O)
10112.1 
Hello Michael and congratulations on the V4 release.

I'd like to bring up again a point raised a little while ago, regarding the usefulness of a screen-space move mode. This is mostly related to click-drag move, but could also apply to scale and rotate. Here is some footage of what happens when attempting to do it in MOI, as opposed to the expected behavior in 3d programs.

https://www.youtube.com/watch?v=lQgE2HlWVFs&feature=youtu.be&ab_channel=PiorO

Of course I understand that the MOI behavior when manipulating things in the 3d viewport is not a bug, as it is performing the move on the floor plane as intended. I also understand that screen-space editing is not a very "CAD-esque" action.

Still, it would be extremely useful for freeform hardsurface modeling, which in many regards does overlap with the mission statement of MOI.
Maybe there could be some clever scripting to work around the current limitation of the move tool ? For instance assigning keys to move along +x -x +y -y by one unit, on a plane calculated as being perpendicular to the aim of the 3d viewport camera.

If anything, for UX sake the argument could be made that the click and drag move *should* be in screen mode to begin with, and be limited to a plane only in ortho views ...

I hope this makes sense ! And a happy new year to you all :)
  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
10112.2 In reply to 10112.1 
Hi pior, there's a script here that will set the cplane to the view plane:

http://moi3d.com/forum/index.php?webtag=MOI&msg=2599.8

For assigning keys to move objects, try the Nudge scripts:
http://kyticka.webzdarma.cz/3d/moi/#Nudge

- 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:  pior (PIOR_O)
10112.3 In reply to 10112.2 
Hello !

That does look like a good workaround indeed.
What would be the script for CPlace reset ? Either standalone (just the reset itself), or as a toggle for this camera CPlane script :

script:/* Orient cplane to 3D view direction, keep same origin */ var frame = moi.ui.mainWindow.viewpanel.getViewport('3D').targetFrame; frame.origin = moi.view.getCPlane().origin; moi.view.setCPlane( frame );

Thanks !
  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
10112.4 In reply to 10112.3 
Hi pior, cplane reset would be:

script: moi.view.resetCPlane();

- 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:  pior (PIOR_O)
10112.5 In reply to 10112.4 
Well that's pretty much perfect, I wish I had asked sooner :)
Thanks again !
  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:  pior (PIOR_O)
10112.6 In reply to 10112.4 
Hi there again - this has proven extremely useful so far, it makes freeform modeling a MOI an absolute breeze.
Diving deeper into this, Is there also a way to create the temporary plane at the world location of the currently selected component ? With a fallback if nothing is selected.
  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
10112.7 In reply to 10112.6 
Hi Pior,

re:
> Diving deeper into this, Is there also a way to create the temporary plane at the world location of the
> currently selected component ? With a fallback if nothing is selected.

What does the "world location" mean, is it the center of the selected object's bounding box?

And you mean with the view direction as the plane's normal?

And what should the fallback do?

- 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:  pior (PIOR_O)
10112.8 In reply to 10112.7 
Hello Michael ! Thank you for the follow up-as always. I'll try to clarify.

- Indeed that's what I mean by "world location" : the location of the bounding box of the currently selected object (or objects). That way the plane would appear right where it is needed for drafting, as screen space sketching very often relates to an existing element of a design (like for instance drafting the outline of a headlight at the location where it will be ultimately be, near the front of the body of a car.)

- As for the fallback if no object is selected : that would be the behavior of the script from just earlier, which is to have the custom, view-aligned Cplane by place at the world origin. But maybe that's self-evident and/or already built into the command.

Btw, is there an api/command reference page out there for all the tools ? Like for instance how to add options in scripts/shortcuts for things like "apply to all views", and so on.
[edit] Probably this ? http://kyticka.webzdarma.cz/3d/moi/

EDITED: 20 Jan 2021 by PIOR_O

  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
10112.9 In reply to 10112.8 
Hi Pior, try this one for targeting it on selected objects:

script:/* Orient cplane to 3D view direction, origin on selected objecs */ var frame = moi.ui.mainWindow.viewpanel.getViewport('3D').targetFrame; frame.origin = moi.view.getCPlane().origin; var objs = moi.geometryDatabase.getSelectedObjects(); if ( objs.length > 0 ) { frame.origin = objs.getHighAccuracyBoundingBox().center; } moi.view.setCPlane( frame );


> Btw, is there an api/command reference page out there for all the tools ? Like for instance how to add
> options in scripts/shortcuts for things like "apply to all views", and so on.

There is some at http://moi3d.com/wiki/Scripting but it's not complete.

- 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:  pior (PIOR_O)
10112.10 In reply to 10112.9 
Hello Michael -

Well, what can I say ... this is brilliant really !! So snappy and useful, that's exactly it.
Is the custom Cplane feature (as run like in this script) always tied to all views, or can it be related to the perspective view only, leaving the other (orthos) unaffected ?

Anyways, really great stuff. It opens up a lot of doors for freeform cuts, and so on.
  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
10112.11 In reply to 10112.10 
Hi Pior,

re:
> Is the custom Cplane feature (as run like in this script) always tied to all views, or can it be related to
> the perspective view only, leaving the other (orthos) unaffected ?

It can be set just for the 3D view without changing the ortho views. Try this:

script:/* Orient cplane to 3D view direction, origin on selected objects */ var frame = moi.ui.mainWindow.viewpanel.getViewport('3D').targetFrame; frame.origin = moi.view.getCPlane().origin; var objs = moi.geometryDatabase.getSelectedObjects(); if ( objs.length > 0 ) { frame.origin = objs.getHighAccuracyBoundingBox().center; } moi.view.setCPlane( frame, false /*ApplyToAllViews*/ );

- 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
 From:  pior (PIOR_O)
10112.12 In reply to 10112.11 
Well, as per usual this seems to be working perfectly. Thank you so much !!
  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