I did it this way

private function getStagePosition(cam:Camera3D,
obj:ObjectContainer3D):Vector3D
{
    var camT:Matrix3D = cam.viewProjection.clone();
    var planT:Matrix3D = obj.sceneTransform.clone();
    camT.prepend(planT);

    var pv:Vector3D = Utils3D.projectVector(camT, new Vector3D());
    pv.x = (pv.x * stage.stageWidth / 2) + stage.stageWidth / 2
    pv.y  = (pv.y*-1 * stage.stageHeight / 2) + stage.stageHeight / 2
    return pv;
}

Not really fully tested, but "seemed" to work.

Reply via email to