Forum

Rotation on local axis

27 March 2015 04:03
Ok, I am not very knowledgeable in the animation area in general, and I am not very familiar with animation in Blender in specific, so this may be a very trivial thing but I always have difficulty accomplishing it.

Forgive me if this is a stupid question, but i a trying to make a very simple basic animation of an object rotating around its local Z axis, like this: TheSpaceCakeLogo3D

If I use Euler ZXY in blender viewport the animation looks ok, but when I export I to Blend4Web I always get this unexpected result where the object rotates over the global Z axis : TheSpaceCakeLogo3D_wrong

So I always have to use Quaternion rotation to have it behave in Blend4web identically to what happens in the viewport. Only problem is quaternions are a bit complex for my simple mind, it is not so trivial to tweak values and make adjustments to the curves in the Graph Editor. Also it would be desirable if the behavior in the web player mimicked the viewport more closely.
So is there a way to use Euler rotations, or correctly use transformations so that they work equally both in Blender Viewport and Blend4Web or am I just doing something wrong?
27 March 2015 04:16
Oh sorry, one more thing, I a (still) on Blender 2.72b/Blend4Web 14.11.0, I've been busy, but intend to upgrade very soon.
One thing I noticed is that when one exports Blend4web to html it automatically saves the .blend file without warning or the user permission which I find a bit destructive.

Some times I am just experimenting with a file, doing all sorts of messy things I do not wish to keep, but when I quit I notice the file as been saved and I inadvertently ruined my work without possibility to undo.
Is this a known issue, intentional functionality or a requirement for correctly exporting? Has this changed in later versions or are there nay plans to alter this behavior?
27 March 2015 10:24
Hi,
If I use Euler ZXY in blender viewport the animation looks ok, but when I export I to Blend4Web I always get this unexpected result where the object rotates over the global Z axis : TheSpaceCakeLogo3D_wrong
As it is described in documentation, Blend4Web properly supports only XYZ Euler and Quaternions. Other combinations are pretty difficult to support, but we have such plans anyway.

Some times I am just experimenting with a file, doing all sorts of messy things I do not wish to keep, but when I quit I notice the file as been saved and I inadvertently ruined my work without possibility to undo.
Is this a known issue, intentional functionality or a requirement for correctly exporting? Has this changed in later versions or are there nay plans to alter this behavior?
You can always disable this behavior. There is an Autosave blend File flag to the left of the files' list during export.
27 March 2015 22:06
As it is described in documentation, Blend4Web properly supports only XYZ Euler and Quaternions. Other combinations are pretty difficult to support, but we have such plans anyway.

Thanks, I'll look into this more carefully, but I have been using simple regular Euler transformations with LocRot keyframes and what Blend4Web shows always behaves differently from what Blender viewport animation, hence my question.
Check out the attached files, in viewport local Z axis is used, but in HTML it's the global Z.

You can always disable this behavior. There is an Autosave blend File flag to the left of the files' list during export.
Cool, how have missed this? Works like a charm, this will be very helpul.

Thanks a lot for the tips
28 March 2015 06:46
Hi Duarte,

Your cube is animated in ZYX Euler rotation mode. Blend4Web currently supports "XYZ Euler" and "Quaternion WXYZ" modes only.
Thanks for the feedback!
The Founder | Twitter | Facebook | Linkedin
29 March 2015 05:02
Oh right sorry, I misread Evgeny Rodygin post. Looking forward for more modes support.

Thanks for the answer. Keep up the great work.
 
Please register or log in to leave a reply.