Creative Communities of the World Forums

The peer to peer support community for media production professionals.

Activity Forums Adobe After Effects Expressions Spotlights attached to sphere

  • Rutger

    October 23, 2007 at 1:23 am

    Hello Lars,

    Interesting idea. I would probably not use CC sphere for the position of the lights. Although it is very powerful, I have learned the hard way that when it comes to a rotating object, that CC sphere shows some unrealistic behavior. (see my Billiard pool ball question posted earlier). But, I would use it to render the earth itself obviously.

    I have never done a sphere with lights, but…I have done a very similar excercise where I had 30 or so lights in a circle pointing at a moving text in 3D. If you create a composition and add a spotlightlight. Then you create a null (named “Light Controls”) with a slider control named “Number of Lights” and a second control “Radius”. You can give in the following expression for position of the light (you may have to tweak it a bit):

    x=272+thisComp.layer(“Light Controls”).effect(“Radius”)(“Slider”)*Math.sin(Math.PI*2*index/thisComp.layer(“Light Controls”).effect(“Number of Lights”)(“Slider”));
    z=-500+thisComp.layer(“Light Controls”).effect(“Radius”)(“Slider”)*Math.cos(Math.PI*2*index/thisComp.layer(“Light Controls”).effect(“Number of Lights”)(“Slider”));
    y= thisComp.height/2;
    [x,y,z]

    create a second null “Light Point of Interest” and give in the following expression for Point of interest for the light:
    thisComp.layer(“Light Point of Interest”).transform.position

    Now copy the light 30 (or n) times. You should see a circle of light after you apply Lux to the Composition.

    Now to create a rotating circle you should probably create a 3rd null that is at the center of the circle and parent all the lights to this null, then you can simply rotate the entire circle by rotating the null.

    Now you should be able to remove some of the lights (and replace them with nulls to keep the index count the same).

    Now, I have not turned this into a sphere yet, for that I would probably adapt the following post by oscarus on http://www.aenhancers.com https://www.aenhancers.com/viewtopic.php?t=160&highlight=sphere

    Not sure if it will work, but that’s how I would go about it. I hope this helps.

    Rutger

We use anonymous cookies to give you the best experience we can.
Our Privacy policy | GDPR Policy