New Camera Tool : Kite Camera

Moho allows users to write new tools and plugins. Discuss scripting ideas and problems here.

Moderators: Fahim, Distinct Sun, Víctor Paredes, erey, Belgarath, slowtiger

New Camera Tool : Kite Camera

Postby Peteroid » Sat Sep 25, 2010 12:57 am

Kite Camera

WHAT IT DOES: Select a Layer, specify a Frame Range, specify a Distance Range.... EXECUTE... the result is the Camera will animate through the distance range during the frame range.

For example, setting frame range to 1 to 48 and the distance from 1 to 2, the camera will move from distance 1 to distance 2 from the selected Layer in the first 2 seconds.

The direction of motion is directly from the layer to the camera. A way to think of this is this: if the camera was directly facing the layer, then it will look as if it is backing away of moving closer visually.

Note that this does this by moving the camera ONLY. It does not affect the camera's pan or tilt or the layer position.

NOTE that Point Camera and Kite Camera were designed to be used together, though they both have a lot of uses separately. Plus, Point Camera and Kite Camera are COMMUTATIVE: it makes no difference which one you perform first.

Warning: Do not start the distance range at zero, because it has no way of knowing which direction to move the camera away from the layer! In this case the tool will do nothing.

installation: http://www.peteroid.com/share/pao_kite_camera.zip

Tutorial:

Bring up Tutorial 5.8.

Select tree 2.

Use Point Camera for frames 1 - 192.

Watch video (camera is always pointing at tree, but varies distance in a complex way).

Apply Kite Camera for frames 1 to 192 with distance range 1.0 to 1.0

Watch video. (camera stays at fixed distance 1)

Apply Kite Camera again to frames 1 to 192, but set distance range from 3 to 1. Now it moves closer during animation smoothly. Try it again with distance range from 1 to 3, now it backs away.

Experiment! :)

Video Example

Using 'Tutorial 5.8 Final', this is the result of applying Point Camera and Kite Camera to Tree 9, with the Kite Camera distance range set from 10 to 1. I also turned off 'facing the camera' for Tree 9 to show how it is actually looking at Tree 9 from different angles. Turn it back on and you'll see what was 'missing'.

YouTube video: http://www.youtube.com/watch?v=Xby3AVFGHY4

---------------------------

NEXT:

Lock Camera
: This will match the motion of the layer (3D position only). Thus, the camera will be locked to the Layer. Only effects the position of the camera.

Lock Camera will allow some interesting affects. It can be combined with Point Camera and Kite Camera (and to a lesser degree Float Camera) for some interesting effects...

Best to think of them this way (so far):

Point Camera: face layer
Float Camera: match layer height
Kite Layer: control layer distance
Lock Camera: follow layer

Lock Camera is what 2D projects will want to use most. The others tend to 'liberate' the camera into the third dimension (and are really 3D camera operations meant to exist in a 3D world). So if you are doing 2D work and you use the other camera tools and say...hey, wait a minute! this just destroyed my 2D feel... wait till Lock Camera... it should help.

Some of these are independent of each other (Point Camera and Kite Camera), but most depend GREATLY on order of application. So should be fun to find cool combos! :)

Should have Lock Camera tomorrow...
Last edited by Peteroid on Sat Sep 25, 2010 3:18 am, edited 6 times in total.
[==Peter==]
User avatar
Peteroid
 
Posts: 162
Joined: Thu Aug 12, 2010 3:57 am
Location: las vegas, NV

Postby patricia3d » Sat Sep 25, 2010 1:42 am

Many Many Thanks for your development, but will this work in 6.2
User avatar
patricia3d
 
Posts: 725
Joined: Thu May 31, 2007 4:38 am
Location: India

Postby Peteroid » Sat Sep 25, 2010 1:55 am

kkrawal wrote:Many Many Thanks for your development, but will this work in 6.2


I can't test it... I only have ASP7... I know how to make an AS5 version since I have sample AS5 scripts, but I can't test these either. I rely on those who have AS5 to do this for me (DK for instance).

I know AS5 and AS7 have to have different versions. AS7 is not backwards compatible to AS5.

AS6 might be compatible with AS5, it might be compatible with AS7, it might not be compatible with either.
[==Peter==]
User avatar
Peteroid
 
Posts: 162
Joined: Thu Aug 12, 2010 3:57 am
Location: las vegas, NV

Postby funksmaname » Sat Sep 25, 2010 3:28 am

nice work Peter! pretty funky new camera possibilities...
User avatar
funksmaname
 
Posts: 3103
Joined: Tue May 29, 2007 11:31 am
Location: Nelson, New Zealand

Postby ulrik » Sat Sep 25, 2010 9:22 am

Hi Peter, you are really expanding the possibilities for AS with your camera scripts! Nice work! :D
ulrik
 
Posts: 1061
Joined: Thu Aug 11, 2005 10:32 pm
Location: Stockholm Sweden

Postby DK » Sat Sep 25, 2010 11:36 am

Sorry, a bit flat out at the moment.

Confirmed to work with 5.6 :)

Thanks Peteroid
User avatar
DK
 
Posts: 2288
Joined: Mon Aug 09, 2004 6:06 am
Location: Australia

Postby Peteroid » Tue Sep 28, 2010 1:42 am

kkrawal wrote:Many Many Thanks for your development, but will this work in 6.2


I finally found an AS version 6 script.... it looks like it is the same format as AS version 7 scripts as far as I can tell.

So, you might try using the AS7 versions of the camera tools, they just might work! :)
[==Peter==]
User avatar
Peteroid
 
Posts: 162
Joined: Thu Aug 12, 2010 3:57 am
Location: las vegas, NV

Postby patricia3d » Tue Sep 28, 2010 3:26 am

I have taken the script from your first post and installed see the error

Image

Thanks for taking interest in 6.2
User avatar
patricia3d
 
Posts: 725
Joined: Thu May 31, 2007 4:38 am
Location: India

Postby Peteroid » Tue Sep 28, 2010 3:52 am

kkrawal wrote:I have taken the script from your first post and installed see the error

Image

Thanks for taking interest in 6.2


I can see from your screen capture you are using the AS5 version (pao_kite_camera_AS5.lua).

I believe it is the AS7 version that is compatible with AS6, so use 'pao_kite_camera.lua' instead.

You MUST remove 'pao_kite_camera_AS5.lua' from 'tool' first if it is still there!!!
[==Peter==]
User avatar
Peteroid
 
Posts: 162
Joined: Thu Aug 12, 2010 3:57 am
Location: las vegas, NV

Postby patricia3d » Tue Sep 28, 2010 7:21 am

Yes Many Many Thanks. Its Working. No Problem at all.
User avatar
patricia3d
 
Posts: 725
Joined: Thu May 31, 2007 4:38 am
Location: India

Postby Peteroid » Tue Sep 28, 2010 2:14 pm

kkrawal wrote:Yes Many Many Thanks. Its Working. No Problem at all.


Cool! :)
[==Peter==]
User avatar
Peteroid
 
Posts: 162
Joined: Thu Aug 12, 2010 3:57 am
Location: las vegas, NV


Return to Scripting

Who is online

Users browsing this forum: No registered users and 1 guest