Return-Path: Received: from mail-vc0-f177.google.com ([209.85.220.177] verified) by media-motion.tv (CommuniGate Pro SMTP 4.2.10) with ESMTP-TLS id 5291616 for AE-List@media-motion.tv; Tue, 19 Nov 2013 21:48:10 +0100 Received: by mail-vc0-f177.google.com with SMTP id hv10so2108717vcb.22 for ; Tue, 19 Nov 2013 12:50:09 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:content-type; bh=Nk+5ErTE6MWY2DXDIvPZ7UHfLyDHGZvU+RMeRRyf6nw=; b=ZMW5er0TmvVz+BkP6dsPmyqpw5d6XSlhgfoV3pgTAavJeWr5P1LM4OD9xKDxZP9vKU tDMNz3toY0fqatwbWJgMfm/8GPkfd47mPU1Z7rXyQkOZ8IqjRrDzYNwCO23BQ8x1aDb3 7lnBWZiR/H85GfNEeoG66tPmNUoo5cssDwiAVjwRfs20FN+IiJCD0j35VSX34zTyTkQa 180PqughGRuBkY2OTUgEv/oRJSdXL6F6RJP09YXfBz8Oze8Eef6TdvaKf/MEvEIT0LlM DPH2AubNBltFmMRGxdAxtrRpCiE0C1LAy4Cz9ADSe3usgqjqijvX53KtFA0hgWJwbwVG +S9Q== X-Gm-Message-State: ALoCoQkuRzP0zG70MQOL9DKkjB4YWdKYaXZaYrVtCVa9sA3L022utDJ82lWObNP48LUv+WuW+N9f X-Received: by 10.220.186.202 with SMTP id ct10mr23193715vcb.14.1384894209297; Tue, 19 Nov 2013 12:50:09 -0800 (PST) MIME-Version: 1.0 Received: by 10.58.45.66 with HTTP; Tue, 19 Nov 2013 12:49:48 -0800 (PST) In-Reply-To: References: From: Robert Kjettrup Date: Tue, 19 Nov 2013 21:49:48 +0100 Message-ID: Subject: Re: [AE] Expression to orient a layer to same direction a Camera To: After Effects Mail List Content-Type: multipart/alternative; boundary=047d7b676fd065a56c04eb8dcf99 --047d7b676fd065a56c04eb8dcf99 Content-Type: text/plain; charset=ISO-8859-1 Ok... i got the paralell orientation to work like i wanted, but have now stumbled over another problem related to this. I now need it to work with the camera parented to a null. Should be relatively simple, right? use toWorld to get the absolute position of the camera set as a child of the 3d null, or that is how i understood that toWorld worked. But i cant get it to return the correct values. Put the following expression on a 3d Point Control on any layer, and have a 3d camera parented to a 3d null. cam = thisComp.activeCamera; cam.toWorld(cam.position) this gives back some position that seems totally wrong. I have tried toWorld, fromWorld, toWorldVec... etc and nothing gives back the absolute position of the camera in the world space. Is there something i just dont understand with this, or??? - Robert 2013/11/18 Robert Kjettrup > doh...!!! > Dead simple when i figured it out. > > Just use the built in expression function LookAt, but put in the camera > position and its target into the fromPoint and atPoint instead of the > layers own position and the camera position. > Of course i figure this out soon after i had sent the mail before after > having struggled with way too complex expressions :-D > > just a head-up to anyone that might find this useful info :-) > > - Robert > > --047d7b676fd065a56c04eb8dcf99 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable
Ok... i got the paralell = orientation to work like i wanted, but have now stumbled over another probl= em related to this.

I now need it to work with the camera parented to a n= ull. Should be relatively simple, right?
use toWorld to get the absolute position of the camera set as a child= of the 3d null, or that is how i understood that toWorld worked. But i can= t get it to return the correct values.=A0
Put the following expression on a 3d Point Control on any layer, and = have a 3d camera parented to a 3d null.

cam =3D thisComp.activeCamera;
cam.toWorld(cam.position)

this gives back some position that seems totally wrong.
I have tried toWorld, fromWorld, toWorldVec... etc and nothing gives back t= he absolute position of the camera in the world space.
Is there = something i just dont understand with this, or???

- Robert



2013/11/18 Robert = Kjettrup <robert@stvmayday.dk>
doh...!= !!
Dead simple when i figured it out.

Just use th= e built in expression function LookAt, but put in the camera position and i= ts target into the fromPoint and atPoint instead of the layers own position= and the camera position.
Of course i figure this out soon after i had sent the mail before afte= r having struggled with way too complex expressions :-D

just a head-up to anyone that might find this useful info :-)

- Robert

<= /div>
--047d7b676fd065a56c04eb8dcf99--