Category Archives: animation

1ucasvb: Given two vectors in three dimensions, one can define…

1ucasvb:

Given two vectors in three dimensions, one can define their vector or cross product as new vector, perpendicular to both original vectors, and with magnitude proportional to the sine of the angle from the first to the second vector.

In this animation, the cross product of two vectors a (blue) and b (red) are used, and their cross-product (vertical, in purple) is shown varying as the angle between both vectors changes.

As you can see, when both vectors are separated by a right angle (90° = π/2 radians or τ/4 radians), their cross product’s vector reaches a maximum length, and when both vectors are parallel, their cross product is zero. (Here, both vectors a and b are unit vectors, so the magnitude of their cross product doesn’t grow beyond 1 either)

Similar to the way the dot product can be used to find if two vectors are perpendicular, one can use the cross product to find out if two vectors are parallel. You just have to check if these products are zero in each case.

The mathematics

In mathematical notation, we write |v| or ||v|| as the norm or magnitude of a vector v. With that notation, we can say that |a × b| = |a| |b| sin(θ)

, where θ is the angle from a to b.

The cross product is said to be “anticommutative”, that is, the order used is important (so it is not commutative, in which case the order wouldn’t matter), and the “anti-” bit says that switching the order switches the sign of the product. Mathematically, a × b = -(b × a)

To be precise, the vector that results from the cross product is said to be a pseudovector, as it is not invariant through reflections: if you see your coordinate axes from a mirror, your right-handed coordinate system would become left-handed, so the definition of the vector breaks down. Vectors are extremely useful because they don’t depend on your system of coordinates, but pseudovectors do, and that’s why they are a caveat worthy of note. This is usually not a problem as long as you stick within the same handed-ness in different system of coordinates, by avoiding such reflections.

There are several ways to actually compute the value of the cross product between two vectors, but the most common one and easier to remember is by finding the determinant of a particular matrix.

Curiously enough, the definition of a vector product returning another vector is unique to 3 and 7 dimensions. More general but similar objects can be defined for other dimensions.

In physics

The cross product is very useful in physics for describing things such as torques (the rotational equivalent of a force), angular momentum (the rotational equivalent of linear momentum), and magnetic forces on charged particles (which act perpendicular to both the velocity of the particle and the magnetic field).

The physical nature of the vector quantity in such cases as torque or angular momentum can be tricky to understand without the proper insight, which is something that is rarely addressed by physics text books.

It is common for students to get stuck to the idea that a vector, as represented by the arrow, points to the direction the force or whatever it is acting or “going towards”. But for angular momentum and torque, this intuition breaks down.

Angular momentum

The proper way to think about the vector for angular momentum is that the vector gives you an axis of rotation. The way the arrow is pointing tells you which of two possible ways the rotation is going (clockwise or counterclockwise, depending on your choice of coordinates and point of view). Using the right-hand rule (for a right-handed coordinate system), you can figure this out easily.

The magnitude of the vector is the actual magnitude of the momentum. So the vector is just a compact way to merge both bits of information on angular momentum in a single mathematical object. The consistency in all of the definitions is what makes it all work nicely, not coincidence.

Torque

The idea of a vector representing the axis and direction of rotation is the same here, but you can also, alternatively, consider it a plane in which the torque is acting on. The vector is normal to this plane.

But another tricky idea here is the dimensions of the torque vector. Remember that in physics, we say length, time and mass, for instance, are dimensions for a physical quantity. We say a meter, a second and a kilogram are units with the dimensions described before, respectively. This difference in terms (units vs. dimensions) is very important, and a lot of people don’t get it right the first time.

So, the dimensions of the torque vector are pretty weird: Newton-meter. A lot of students realize that this is the same thing as a Joule, which is a unit of energy. So why not say torque has the same dimension as energy, call it Joule, and get rid of the Newton-meter thing?

The answer is that while the dimensions match, the concepts don’t. Torque and energy are entirely different concepts, entirely different physical quantities, so they shouldn’t be treated the same even though their dimensions seem to match. But in my opinion, this difference is dogmatic if taken as Newton-meter vs. Joule, because it hides a very important detail.

I think torque makes more sense in units of Joules per radian. The radian is a dimensionless unit, which means it was hidden in there all along in our dimensional analysis. We were not comparing Joules with Joules, but Joules per radians with Joules! The radians bit comes from the fact torques act along an arc.

This is easy to see if we consider the work done by a torque τ: W = τθ, where θ is the angle the torque acted around, rotating an object. In this case, if you consider the dimensions of radians as non-disposable, you can easily see that it all works out.

Wrapping up

The cross product is a very handy tool for defining some more complicated physical quantities. It may seem arbitrary at first, but the reasoning behind its definition is mathematically sound and extremely useful in practice.

In order to fully appreciate it, one must first get rid of a few intuitions on what vectors represent in physics. Vectors can represent a lot of things that are not explicitly directional, as you first start getting used to them, so the sooner you abandon that intuition the better.

Reblog cool maths animations every time because to many people tried to hide how awesome maths is by sticking at teaching it.

Continue reading

Posted in animation, cross product, educational, maths | Comments Off

Dragon game update: additive blending, contorted transformer and slender dragon

Hello again!This has been a pretty big week for my game.I’ve refactored the rendering engine simplifying some stuff and improving performance a lot. I’ve also added smooth shading to my dragon model and had a fight with blender over exporting models (I… Continue reading

Posted in animation, Animation Engine, Dragon Game, game dev, Game Progress, Litterbox, programming | Comments Off

Working on a new game

Hey!I’ve been neglecting this blog for quite some time since I was thinking of moving to wordpress but without ever actually committing.So I decided that for the time being I’ll keep updating this blog with the news of the game I;m currently developing… Continue reading

Posted in animation, Animation Engine, Announcement, Dragon Game, game dev, Game Progress, Litterbox, programming | Comments Off

Full Circle

Remember those documentaries from Valve Software that say that the Team Fortress 2 art style was inspired by popular Hollywood animated movies? And remember how there was a clear resemblance between that art style and The Incredibles? Well, it looks like things have come full circle now that Valve’s Source Filmmaker beta is out in [...]
Continue reading

Posted in animation, games, Links, Team Fortress 2, The Incredibles, Valve Corporation | Comments Off

The joints are turning

Hello!Luck is not always on our side and so the animation tutorial will be delayed a little. I do have it completely planned out though so pretty soon you’ll see the first chapter. The complete tutorial will have 9 chapters ranging from vector transfor… Continue reading

Posted in animation, Animation Engine, Announcment, game dev, tutorial | Comments Off

The joints are turning

Hello!Luck is not always on our side and so the animation tutorial will be delayed a little. I do have it completely planned out though so pretty soon you’ll see the first chapter. The complete tutorial will have 9 chapters ranging from vector transfor… Continue reading

Posted in animation, Animation Engine, Announcment, game dev, tutorial | Comments Off

I’m back from the dead, and with some good news!

Hello Ludum-Dare-ians and people who randomly found this blog on Google looking for game save tutorial!

I’m back from my slumber, and what slumber it was!
I did get the job at the company I was making those challenges for, I’m even on our company’s pa… Continue reading

Posted in animation, Animation Engine, Announcement, Litterbox | Comments Off

I’m back from the dead, and with some good news!

Hello Ludum-Dare-ians and people who randomly found this blog on Google looking for game save tutorial!I’m back from my slumber, and what slumber it was!I did get the job at the company I was making those challenges for, I’m even on our company’s page … Continue reading

Posted in animation, Animation Engine, Announcement, Litterbox | Comments Off

The Hand of….. Me So now that I have the multiple…

[Flash 10 is required to watch video.]renderVideo(“video_player_538160278″,’http://kimau.tumblr.com/video_file/538160278/tumblr_l187xjwuI41qbssk5′,400,300,’poster=http%3A%2F%2Fmedia.tumblr.com%2Ftumblr_l187xjwuI41qbssk5_frame1.jpg,http%3A%2F%2Fmedia.tumblr.com%2Ftumblr_l187xjwuI41qbssk5_frame2.jpg,http%3A%2F%2Fmedia.tumblr.com%2Ftumblr_l187xjwuI41qbssk5_frame3.jpg,http%3A%2F%2Fmedia.tumblr.com%2Ftumblr_l187xjwuI41qbssk5_frame4.jpg,http%3A%2F%2Fmedia.tumblr.com%2Ftumblr_l187xjwuI41qbssk5_frame5.jpg’)

The Hand of….. Me

So now that I have the multiple animation system in place I need something to test it with. So the key things in the game are Frank & The hand. So I quickly threw together a hand which does the following.

  • Idle
  • Pick Up
  • Idle Holding
  • Put Down
  • Drop
  • Pet
  • Tell Off

So now that’s done I need to use the dummy (the ball) and attach an object to that so the animation of the picked up object matches the motion of the hand.

So next steps

  • Hand in Game
  • Ball in Game
  • Move Hand
  • Play Separate Animations based on Input
  • Location Based Picking
  • Dummy Attachment

Continue reading

Posted in animation, modelling, petgame, university | Comments Off

Woooot! Final version of the animation. There is massive room…

[Flash 10 is required to watch video.]renderVideo(“video_player_528401278″,’http://kimau.tumblr.com/video_file/528401278/tumblr_l113d3gPoL1qbssk5′,400,300,’poster=http%3A%2F%2Fmedia.tumblr.com%2Ftumblr_l113d3gPoL1qbssk5_frame1.jpg,http%3A%2F%2Fmedia.tumblr.com%2Ftumblr_l113d3gPoL1qbssk5_frame2.jpg,http%3A%2F%2Fmedia.tumblr.com%2Ftumblr_l113d3gPoL1qbssk5_frame3.jpg,http%3A%2F%2Fmedia.tumblr.com%2Ftumblr_l113d3gPoL1qbssk5_frame4.jpg,http%3A%2F%2Fmedia.tumblr.com%2Ftumblr_l113d3gPoL1qbssk5_frame5.jpg’)

Woooot! Final version of the animation.

There is massive room for improvement and parts make me wince. I don’t have the time to work on it or time to render it so I’m having to end it.

So thoughts?

Continue reading

Posted in animation, draft, frank, university | Comments Off

The opening shot. This is followed by some static, a few screen…

[Flash 10 is required to watch video.]renderVideo(“video_player_522792386″,’http://kimau.tumblr.com/video_file/522792386/tumblr_l0wpqoavOw1qbssk5′,400,300,’poster=http%3A%2F%2Fmedia.tumblr.com%2Ftumblr_l0wpqoavOw1qbssk5_frame1.jpg,http%3A%2F%2Fmedia.tumblr.com%2Ftumblr_l0wpqoavOw1qbssk5_frame2.jpg,http%3A%2F%2Fmedia.tumblr.com%2Ftumblr_l0wpqoavOw1qbssk5_frame3.jpg,http%3A%2F%2Fmedia.tumblr.com%2Ftumblr_l0wpqoavOw1qbssk5_frame4.jpg,http%3A%2F%2Fmedia.tumblr.com%2Ftumblr_l0wpqoavOw1qbssk5_frame5.jpg’)

The opening shot.

This is followed by some static, a few screen announcements then the lights flick on and the background changes as required.

After those, we play the drainage shot. Followed by some close ups of red lights changing to green. Finally the walk up anim plays.

Continue reading

Posted in animation, frank, university | Comments Off

Final render of walk-up. The blink didn’t work for some…

[Flash 10 is required to watch video.]renderVideo(“video_player_520446408″,’http://kimau.tumblr.com/video_file/520446408/tumblr_l0v0kquzwa1qbssk5′,400,300,’poster=http%3A%2F%2Fmedia.tumblr.com%2Ftumblr_l0v0kquzwa1qbssk5_frame1.jpg,http%3A%2F%2Fmedia.tumblr.com%2Ftumblr_l0v0kquzwa1qbssk5_frame2.jpg,http%3A%2F%2Fmedia.tumblr.com%2Ftumblr_l0v0kquzwa1qbssk5_frame3.jpg,http%3A%2F%2Fmedia.tumblr.com%2Ftumblr_l0v0kquzwa1qbssk5_frame4.jpg,http%3A%2F%2Fmedia.tumblr.com%2Ftumblr_l0v0kquzwa1qbssk5_frame5.jpg’)

Final render of walk-up. The blink didn’t work for some reason. Going to see if I can fake it.

Continue reading

Posted in animation, frank, university | Comments Off

So the second biggest shot, the walk up and meep sequence needs…

So the second biggest shot, the walk up and meep sequence needs some polish.

  • I need to re-render it at a higher quality
  • The little guy needs to blink
  • I wasn’t happy with light balls

Now the real question… 

White or Green lighting strip?

Continue reading

Posted in animation, frank, university | Comments Off

Okay so this is only one shot of a greater sequence, but it is…

[Flash 10 is required to watch video.]renderVideo(“video_player_507740382″,’http://kimau.tumblr.com/video_file/507740382/tumblr_l0lm5zFGaj1qbssk5′,400,300,’poster=http%3A%2F%2Fmedia.tumblr.com%2Ftumblr_l0lm5zFGaj1qbssk5_frame1.jpg,http%3A%2F%2Fmedia.tumblr.com%2Ftumblr_l0lm5zFGaj1qbssk5_frame2.jpg,http%3A%2F%2Fmedia.tumblr.com%2Ftumblr_l0lm5zFGaj1qbssk5_frame3.jpg,http%3A%2F%2Fmedia.tumblr.com%2Ftumblr_l0lm5zFGaj1qbssk5_frame4.jpg,http%3A%2F%2Fmedia.tumblr.com%2Ftumblr_l0lm5zFGaj1qbssk5_frame5.jpg’)

Okay so this is only one shot of a greater sequence, but it is the longest shot. Also the most complex, effects wise.

  • Mistake #1: Forgot to check the noise frequency on the goo
  • The pipe on the left sucks but I’ve left it like that for academic interest as thats the IK pipe the one of the right is animated by hand using splines and loft.
  • I like how the particles turned out.
  • I think once a sound track is laid on top of this it will be a lot better.
  • I might add some smoke ect… in the compositing stage

Thoughts?

Continue reading

Posted in animation, frank, university | Comments Off

I am back at work. My laptop is 20hrs into a 90hr render. Post…

I am back at work. My laptop is 20hrs into a 90hr render. Post from iPhone as my laptop is locked in the grasp of uber render.

Continue reading

Posted in animation, frank, university | Comments Off

So I set off this short shot off to render, as I was out last…

[Flash 10 is required to watch video.]

So I set off this short shot off to render, as I was out last night at an event. This is just a the final short shot. The camera passes, tube dropped down, camera checks, then final walk up and reveal. This is just the final walk up and reveal. 20 hours later I realise.

  • I need a higher quality render
  • The look up animation needs some tweak
  • The final render time is going to kill me

Continue reading

Posted in animation, frank, university | Comments Off

Lets put a pin on it Well the animation on the screen, I had…





Lets put a pin on it

Well the animation on the screen, I had ideas of really complex animations and stuff but it doesn’t really need it an time is short. So I just made a quick avi of scrolling code, it seems to fit.

Also the cuteness of Frank is in the tube. Considered modelling the cute features so the Final Gather worked better and the highlights were more relevant. Again time is short and it would be hard to reproduce exactly.

So all done, lets put it to bed until I can throw hours and hours of render time. Then compose the video and link audio to it.

Continue reading

Posted in animation, frank, modelling, university | Comments Off

All done The pipes are cleaned up. I’m not cleaning the IK…











All done

The pipes are cleaned up. I’m not cleaning the IK pipe as its a messy mangle, but I’m leaving it in because its educational and this is a university assignment. I’ll just make sure the camera avoids it.

Tried making the red lights wash more to the nearby materials. It works nicely on the top light with the pipes and the stair lights but the angles aren’t quite right for the down lights on the base unit. Also the tube light doesn’t have much to bounce off. So I’m leaving it as is.

The Goo falloff diffuse shader works well I think. I just need to compile the 2D animation for the big screen TV and the scene will be complete. The 3D work for this shot is all done.

Continue reading

Posted in animation, frank, university | Comments Off

Overnight Okay so some serious progress with texturing, cameras,…





















Overnight

Okay so some serious progress with texturing, cameras, materials and the like. The render times are getting silly though. I rendered an overnight job at full quality every 45th frame (not all included due to Tumblr limit). 

  • The big TV screen is going to have some pre-rendered animation on via animated texture
  • There are one or two intersecting wires which need cleaning up.
  • The Green Goo and bubbles I’m going to introduce some colour difference based on camera facing normal if I can. Maybe up their emission in lumen.

This is the longest continuous, and most complex shot. Other shots include.

  • Some initial close-up fly bys of machinery and screens, finally doing full reveal of machine in frame. Lots of small bitty shots which will need compositing.
  • The green lights change to red
  • After this long shot one quick look at some screens.
  • Some shots of the red lights switching back to green.
  • Walk up, stairs, camera using walking bob animation for first person feel. To reveal cute frank inside.
  • Meep Shot.

Sounds like loads but its mostly camera animation so no biggie there. The only thing that worries me are my render times are silly numbers. Which means I might need to postpone the final render to when I’m back at work and can leave my computer running a 30+ render.

Please comment below or tweet @EvilKimau for your thoughts if you have any.

Good to be making progress :)

Continue reading

Posted in animation, frank, modelling, university | Comments Off

Success!!! Doesn’t look very different but its VERY…







Success!!!

Doesn’t look very different but its VERY different.

  1. The wires animate around the pipes
  2. The second pipe is in using spline & loft (animates nicer than my messy IK)
  3. Everything without a proper UV map has been mapped

No full blown render as it takes too much time out of my productive cycle

Continue reading

Posted in animation, frank, modelling, texture, university | Comments Off