C 滑动镜头并固定相机中的影像

2019-09-23 17:19 来源:未知
void ExtendedCamera::Update( Real elapsedTime, Vector3 cameraPosition, Vector3 targetPosition )
{
    Vector3 displacement;

    displacement = (cameraPosition - mCameraNode->getPosition()) * mTightness;
    mCameraNode->translate( displacement );

    displacement = (targetPosition - mTargetNode->getPosition()) * mTightness;
    mTargetNode->translate( displacement );
}
TAG标签:
版权声明:本文由美洲杯赌球发布于计算机教程,转载请注明出处:C 滑动镜头并固定相机中的影像