Flash 3D Function
GEN_putObjectIn3dScene = function (theClip, cameraDistanceFromTracerPlane, x, y, z, vanishingPointX, vanishingPointY) {
if (z<0) {
theClip._alpha = 0;
} else {
theClip._alpha = 100;
}
var zfactor = cameraDistanceFromTracerPlane/z;
theClip._x = x*zfactor+vanishingPointX;
theClip._y = y*zfactor+vanishingPointY;
theClip._xscale = 100*zfactor;
theClip._yscale = 100*zfactor;
theClip.cacheAsBitmap();
theClip.swapDepths(Math.floor(100000-z));
};
No comments:
Post a Comment