Resetting bounding box after resetting origin
Moderators: Víctor Paredes, Belgarath, slowtiger
Resetting bounding box after resetting origin
Is there anyway to reset or redraw a layers bounding box after resetting the origin? I've got a couple of layers that after resetting the origin point, the bounding box for the layer doesn't make much sense. In one example, a bone layer holding some image layers. It's a character, but the bounding box is a long horizontal slice instead of a bounding box surrounding my character. Is there some way to set the actual bounds of the bounding box?
Re: Resetting bounding box after resetting origin
The "bounding box" is just a visible indication of the scaling you applied to that layer. Select the layer scale tool (2) and check the values in the top of the window, none of these should be zero. There's a reset button.
AS 9.5 MacPro Quadcore 3GHz 16GB OS 10.6.8 Quicktime 7.6.6
AS 11 MacPro 12core 3GHz 32GB OS 10.11 Quicktime 10.7.3
Moho 13.5 iMac Quadcore 2,9GHz 16GB OS 10.15
Moho 14.1 Mac Mini M2 Pro OS 13.7.6
AS 11 MacPro 12core 3GHz 32GB OS 10.11 Quicktime 10.7.3
Moho 13.5 iMac Quadcore 2,9GHz 16GB OS 10.15
Moho 14.1 Mac Mini M2 Pro OS 13.7.6
Re: Resetting bounding box after resetting origin
I'm not talking about resetting the scaling, but the actual bounding box itself. After resetting the origin of the layer, the bounding box itself doesn't really encapsulate my layer contents. I realize it doesn't necessarily affect anything, I can still scale, rotate, and translate fine; it's just one of those things that bugs me when the bounding box appears so inconsisitent and random.
https://www.dropbox.com/s/yju920ddxyz9x ... ingBox.png
https://www.dropbox.com/s/yju920ddxyz9x ... ingBox.png
Re: Resetting bounding box after resetting origin
There is no bounding box. What you see are the "handles" for the scale tool. It's always centered around the point of origin.
AS 9.5 MacPro Quadcore 3GHz 16GB OS 10.6.8 Quicktime 7.6.6
AS 11 MacPro 12core 3GHz 32GB OS 10.11 Quicktime 10.7.3
Moho 13.5 iMac Quadcore 2,9GHz 16GB OS 10.15
Moho 14.1 Mac Mini M2 Pro OS 13.7.6
AS 11 MacPro 12core 3GHz 32GB OS 10.11 Quicktime 10.7.3
Moho 13.5 iMac Quadcore 2,9GHz 16GB OS 10.15
Moho 14.1 Mac Mini M2 Pro OS 13.7.6
- Víctor Paredes
- Site Admin
- Posts: 5842
- Joined: Tue Jan 25, 2005 3:18 pm
- Location: Barcelona/Chile
- Contact:
Re: Resetting bounding box after resetting origin
I don't agree. In version 9 AS tries to adapt that handles to the layer size. Unfortunately, it doesn't get the right shape sometimes and I haven't found a solution yet.slowtiger wrote:There is no bounding box. What you see are the "handles" for the scale tool. It's always centered around the point of origin.
Moho co-owner
Previously Rigged animation supervisor: My father's dragon, Wolfwalkers & Star Wars Visions "Screecher's Reach"
My personal Youtube Channel
Re: Resetting bounding box after resetting origin
I think the image I linked in my post shows this as being untrue, it most certainly does not center itself around the point of origin. And those handles you're referring too? They fall upon a bounding box. It's not a bounding box in the sense of a 3D bounding box, but it is a bounding box. Anytime there is a box with transform handles around an object, it's called a bounding box.slowtiger wrote:There is no bounding box. What you see are the "handles" for the scale tool. It's always centered around the point of origin.
As I said, functionally it performs and does all the things it's supposed to, it's just slightly irksome it doesn't doesn't surround the object in question as expected, just seems to be rather random in it's shape and size.
Re: Resetting bounding box after resetting origin
I have found the bounding box is puzzling too. In other softwares this always forms the edges of the layer. It drives me crazy that i sometimes have a little character that has basically square dimensions but the bounding box becomes really narrow and wide. It is very confusing when trying to apply the translate layer tool to a walk cycle. I wish there was a way to refit the box to the edges of the object as you can In Indesign. Related to this (I think) is the way the origin point - and hence the bounding box - seems to wander away from the object in the course of the animation. When I try to use the set origin tool, my chararacter goes flying off the screen, to the edges of the known universe and beyond. Does this happen to anyone else?
- hayasidist
- Posts: 3907
- Joined: Wed Feb 16, 2011 11:12 am
- Location: Kent, England
Re: Resetting bounding box after resetting origin
oh yes! Layer Origin. Bless it. yep -that's a one-time choice. You can't animate its value. When you invoke the transform layer tool, yes - it does produce what most folks would refer to as an illogical bounding box. but, as Wizaerd said, I think it's functionally the same in 9.5 with its "all in one" layer tool as the individual tools in AS8. And, as ST says, it is just a set of handles. You might argue that the AS8 scale bounding box, which was centred on the origin without regard to where the points in the layer were was differently, but just as, illogical..
to Cynthia's issue about things wandering off... when you move the points by whatever means the layer origin doesn't move. It's the point around which layer rotations take place and from which layer displacements occur (I really won't go into the maths of the transform matrix). So if you have the origin in the middle of the object and rotate its layer, it'll spin on the spot; but if you have the origin the other side of the screen and rotate the layer the object will fly off in a big orbit. If you have layers within layers, then the layer transforms accumulate. To repeat: origin is a one-time choice, you can't animate it - so if you move it the transform matrix will be recalculated. This is part of the reason that, if you *need* to do *layer* manipulation - especially rotations around any of the x,y or z axes, but still want to move the points, it's better (essential!) to keep the points in that layer in one place relative to the **fixed** origin (depends what you want to do whether you centre or edge align or ...) and move the other layers relative to it (in AS or in a compositor).
to Cynthia's issue about things wandering off... when you move the points by whatever means the layer origin doesn't move. It's the point around which layer rotations take place and from which layer displacements occur (I really won't go into the maths of the transform matrix). So if you have the origin in the middle of the object and rotate its layer, it'll spin on the spot; but if you have the origin the other side of the screen and rotate the layer the object will fly off in a big orbit. If you have layers within layers, then the layer transforms accumulate. To repeat: origin is a one-time choice, you can't animate it - so if you move it the transform matrix will be recalculated. This is part of the reason that, if you *need* to do *layer* manipulation - especially rotations around any of the x,y or z axes, but still want to move the points, it's better (essential!) to keep the points in that layer in one place relative to the **fixed** origin (depends what you want to do whether you centre or edge align or ...) and move the other layers relative to it (in AS or in a compositor).
Re: Resetting bounding box after resetting origin
Got it, Hayasidist - had to read it 3X to get my brain around it, but that finally makes sense. It is the best reason I've read so far against trying to move a large cast of hopping, rotating characters across a very wide background in a single project.
Re: Resetting bounding box after resetting origin
That's the one thing I've learned over the years... keep the points and bones centered on the layer as much as possible. Translate the entire character layer when a character has to move for a walk cycle or similar action. keeping everything centered to start avoids the need to change the origin points of the layer.
So when creating a bone rig for a character I always create the bones "centered" on the layer. The root top bone is always at "0, 0" which is the center of the bone layer. That means that translating the character top group bone layer will be consistent with the root bone as well.
Another situation where this is helpful are switch layers for hands and feet and the head. I always try to position the vector points relative to the center of the layer even though bone binding rotates based on the bone base, it just keeps things logical visually. A benefit of this is that each opposite hand can have perfectly aligned layer origins that are the same. Makes it easier to edit both sides later because they are the "same". Also I can align the position of the layer for a hand at the exact same position as the hand bone. If the hand layer needs to scale for exaggerated foreshortening (like the hand coming towards the camera) the layer scale origin is correct without needing to change the layer origin.
For the head group layer in the main character bone layer, I position this layer so the group layer center is lined up at the base of the head bone, then draw and position the vectors centered to the head groups center. Makes everything so much easier later. No misaligned layer "bounding boxes", no need to change origin.
Layer origin for me anyway, only needs to change when rotating or scaling the layer. You need the origin at a specific point so the scale and rotation is in the right spot. Generally I only rotate layers using a bone if possible, but uniform scaling has to be done on the layer so the origin location is important.
For example I use a layer script to control the scale of hands and feet based on the scale of a bone. This means the origin of the hands layers has to match the hand bone base exactly to get the right scale origin... which is why I like to keep the locations of the layers centered relative to the layer origin.
I almost never need to change the origin point of layers. The only time I do this is "in an emergency"
, when I'm too lazy to go back and recenter all the vectors to a new center point.
All of this can be a bit tricky with image layers. Images can't be "offset" from the layer origin. If you need an image layer to rotate at a spot not centered you MUST change the layer origin. In those cases that origin offset works fine and isn't horrifically problematic. In some cases I create a transparent PNG with the image actually offset intentionally to put the origin in a specific location.
To make a long story short... it's much easier to keep all the layers "lined up" first as much as possible so that layer origin doesn't need to be changed to "fix" stuff later.
So when creating a bone rig for a character I always create the bones "centered" on the layer. The root top bone is always at "0, 0" which is the center of the bone layer. That means that translating the character top group bone layer will be consistent with the root bone as well.
Another situation where this is helpful are switch layers for hands and feet and the head. I always try to position the vector points relative to the center of the layer even though bone binding rotates based on the bone base, it just keeps things logical visually. A benefit of this is that each opposite hand can have perfectly aligned layer origins that are the same. Makes it easier to edit both sides later because they are the "same". Also I can align the position of the layer for a hand at the exact same position as the hand bone. If the hand layer needs to scale for exaggerated foreshortening (like the hand coming towards the camera) the layer scale origin is correct without needing to change the layer origin.
For the head group layer in the main character bone layer, I position this layer so the group layer center is lined up at the base of the head bone, then draw and position the vectors centered to the head groups center. Makes everything so much easier later. No misaligned layer "bounding boxes", no need to change origin.
Layer origin for me anyway, only needs to change when rotating or scaling the layer. You need the origin at a specific point so the scale and rotation is in the right spot. Generally I only rotate layers using a bone if possible, but uniform scaling has to be done on the layer so the origin location is important.
For example I use a layer script to control the scale of hands and feet based on the scale of a bone. This means the origin of the hands layers has to match the hand bone base exactly to get the right scale origin... which is why I like to keep the locations of the layers centered relative to the layer origin.
I almost never need to change the origin point of layers. The only time I do this is "in an emergency"
All of this can be a bit tricky with image layers. Images can't be "offset" from the layer origin. If you need an image layer to rotate at a spot not centered you MUST change the layer origin. In those cases that origin offset works fine and isn't horrifically problematic. In some cases I create a transparent PNG with the image actually offset intentionally to put the origin in a specific location.
To make a long story short... it's much easier to keep all the layers "lined up" first as much as possible so that layer origin doesn't need to be changed to "fix" stuff later.