Snap to Plane

Discussions regarding modelling with SOFTIMAGE©
User avatar
druitre
Posts: 471
Joined: 25 Jun 2009, 21:35

Snap to Plane

Post by druitre » 31 Jul 2013, 10:55

Hi,

I'm trying to do some hardsurface modeling and would like to be able to snap polygons to other polygons - like this plugin. Problem is, the plugin doesn't seem to work (I'm in 2014 SP1).

Is this possible in some other way, in SI 2014?

thanks, Jasper

User avatar
gaboraa
Posts: 317
Joined: 16 Apr 2010, 21:14

Re: Snap to Plane

Post by gaboraa » 31 Jul 2013, 11:23

Do you try using surface snap?

User avatar
druitre
Posts: 471
Joined: 25 Jun 2009, 21:35

Re: Snap to Plane

Post by druitre » 31 Jul 2013, 12:22

Yep, but that doesn't do what snap to plane does. (the examples on the page I referenced)

User avatar
rray
Moderator
Posts: 1810
Joined: 26 Sep 2009, 13:51
Location: Bonn, Germany

Re: Snap to Plane

Post by rray » 31 Jul 2013, 14:18

That plugin did work for me (was on 2014 sp1 too)

Shows some updates to the snapping tools would be nice.
Moving a point along a custom axis with 'snap to surface' on should move the point so it snaps to the surface, not what we have which is something like "height measured along the axis where the mouse pointer would intersect the surface"

(which is only useful for snapping to points imo)
softimage resources section updated Sep 26th 2026

User avatar
druitre
Posts: 471
Joined: 25 Jun 2009, 21:35

Re: Snap to Plane

Post by druitre » 31 Jul 2013, 14:55

Thanks Rray, I Agree. The options within snapping are not enough, I'm only getting what I want in some (a few) cases.

How do you get the plugin to work? Maybe I'm doing something wrong. Initially, I didn't even see the command listed when trying to make a button for it (restarted several times and all) but somehow that's working now. So I've created a button by dragging the command onto a toolbar. But if I try to use it (after I select two objects, enter polyselect mode and select 1 poly, then enter vertselectmode and select 4 verts) by clicking on my button, nothing happens. The script editor shows only this:

Code: Select all

Application.jjSnapToPlane()
When running the command 'Application.jjSnapToPlane(0)' from the editor I get this:

Code: Select all

# ERROR : Traceback (most recent call last):
#   File "<Script Block >", line 1, in <module>
#     Application.jjSnapToPlane(0)
#   File "<COMObject Application>", line 2, in jjSnapToPlane
# COM Error: Invalid number of parameters. (0x-7ffdfff2) - [line 1]
So, obviously I'm not doing this the way I should. Any ideas?

-Jasper

User avatar
rray
Moderator
Posts: 1810
Joined: 26 Sep 2009, 13:51
Location: Bonn, Germany

Re: Snap to Plane

Post by rray » 31 Jul 2013, 15:01

i just copied it into myworkgroup/plugins and then ran the jj_Snap..(1) command in the command line

could it be the missing underscore?
softimage resources section updated Sep 26th 2026

User avatar
druitre
Posts: 471
Joined: 25 Jun 2009, 21:35

Re: Snap to Plane

Post by druitre » 31 Jul 2013, 15:33

Hi Rray, I started over, this time putting the script in myworkgroup/application/plugins instead of myworkgroup/data/scripts (or should I make a folder myworkgroup/plugins?) and it shows up in plugin manager (after refreshing all). But entering the command 'jj_SnapToPlane(0)' in the script editor gets me this:

Code: Select all

# ERROR : Traceback (most recent call last):
#   File "<Script Block >", line 1, in <module>
#     jj_SnapToPlane(0)
# NameError: name 'jj_SnapToPlane' is not defined
#  - [line 1]
And ' jjSnapToPlane(0)' this:

Code: Select all

# ERROR : Traceback (most recent call last):
#   File "<Script Block >", line 1, in <module>
#     jjSnapToPlane(0)
# NameError: name 'jjSnapToPlane' is not defined
#  - [line 1]
Opening the .py in the script editor and then running it does nothing... as you can probably see, I don't know what I'm doing and I'm just guessing. I have no idea what to do with a plugin like this if it's not simply working. Can you give me a step-by-step, from where to put the .py to what to select in SI to how to run what command?

User avatar
rray
Moderator
Posts: 1810
Joined: 26 Sep 2009, 13:51
Location: Bonn, Germany

Re: Snap to Plane

Post by rray » 31 Jul 2013, 16:36

Installation worked fine if it's in the plugin manager.
Problem might be that I had Jscript in my quotes, in python you should use
Application.jj_SnapToPlane(0)
Works fine here with Python too, without the 'Application' I get similiar errors as you.
softimage resources section updated Sep 26th 2026

User avatar
druitre
Posts: 471
Joined: 25 Jun 2009, 21:35

Re: Snap to Plane

Post by druitre » 31 Jul 2013, 20:14

Hello rray, let me get back on this when i have time to check, sometime friday i hope. Thanks so far for the help.

User avatar
druitre
Posts: 471
Joined: 25 Jun 2009, 21:35

Re: Snap to Plane

Post by druitre » 01 Aug 2013, 14:08

OK! I added Application. and now it works - made a button for all three functions.

Thanks,
Jasper

User avatar
ActionArt
Posts: 853
Joined: 25 Nov 2010, 17:23
Location: Canada

Re: Snap to Plane

Post by ActionArt » 02 Aug 2013, 03:56

That is a very cool function, something I've been looking for a long time. This is something that really should be part of the stock toolset.

I'll have to give that a try! Thanks for posting.