align tool is a script?
it seems the align tool is basically a script?
we select two items (or more) and click a couple parameters and bingo stuff is aligned
And it's wonderful ... but it has limitations (or I may have them).
The picture is a wall I created and there's a door
Now what I want to do is align/snap to the position I want it but because of the nature of the wall I can't really use the align tool
but if I were able to select the polygon, that I have highed in green and then tell the align function put the door in front of the poly, align the bottoms, and center on the X,
There's no doubt the program knows how to align objects but I don't know how to tell it to align an object to a specific poly (or edge or vertex, maybe).
Mesh grabber can select a poly but how do we tell daz to align another object to that poly.
At one level I can code select poly A and align object B to it by calling the align_routine.
but I don't know what has to be in the align_routine.
That's more Richard H's paygrade
But it does seem like all the parts are in the program ... how do we tell the program that A can be a polygon instead of an object, does that happen deep or is it higher where it can be accessed.
++++++++++++++++++
another alternative for placing items would be able to select an object and then use the curser to click a spot and have the object move there .. possible with instructions to place above or beside or behind the point?
Comments
You would need to get the geoemtry for the node, then the selected polygon, and finally the coordinates for that - DzNode getObject(), DzObject getCurrentShape(), DzShape getCurrentGeometry() (I think), DzGeometry I think you would then want the Modifiable Assembly mes, and there you can get selected vertices.
thanks... I did find my collection of Java books, time to study again.
It's related to Javascript rather than Java.
Just to add, the Align pane (originally a separate product, Align Ace) is a plug-in not a script, but it is accessible to scripting through http://docs.daz3d.com/doku.php/public/software/dazstudio/4/referenceguide/scripting/api_reference/object_index/nodealigner_dz . See the sample script here http://docs.daz3d.com/doku.php/public/software/dazstudio/4/referenceguide/scripting/api_reference/samples/nodes/node_align/start . However, to align to part of an object you would need to write your own code (or perhaps spawn a cube to match the bounding box of the selected geometry and then use the Align methods on that)..
well duh I said.. great idea,. I use the default cube to center new work etc in the scene all the time.
===
are there any align scripts currently in existence? Is there a daz collection of scripts somewhere?
---
many times I only want/need to align one axis and having a script icon for an x,y or z setting only ... saving from having to turn off the ones you don't use ...
or having a way to open an align panel with just the one set x,y,or z options.
The first link is an align script.