提交 b5537401 编写于 作者: M Mr.doob

WebGLRenderer: Renamed animate() to setAnimationLoop().

上级 c64a4527
......@@ -1329,6 +1329,13 @@ Object.defineProperties( ShaderMaterial.prototype, {
Object.assign( WebGLRenderer.prototype, {
animate: function ( callback ) {
console.warn( 'THREE.WebGLRenderer: .animate() is now .setAnimationLoop().' );
this.setAnimationLoop( callback );
},
getCurrentRenderTarget: function () {
console.warn( 'THREE.WebGLRenderer: .getCurrentRenderTarget() is now .getRenderTarget().' );
......
......@@ -1058,7 +1058,7 @@ function WebGLRenderer( parameters ) {
}
this.animate = function ( callback ) {
this.setAnimationLoop = function ( callback ) {
onAnimationFrame = callback;
onAnimationFrame !== null ? startAnimation() : stopAnimation();
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册