首页 \ 问答 \ 是否可以使用five.grok在Plone 4.1中注册portlet?(Is it possible to use five.grok to register portlets in Plone 4.1?)

是否可以使用five.grok在Plone 4.1中注册portlet?(Is it possible to use five.grok to register portlets in Plone 4.1?)

我查看了five.grok,发现没有提到Portlets。 可以吗?


I looked into five.grok and found no reference to Portlets. Can it be done?


原文:https://stackoverflow.com/questions/6415585
更新时间:2019-11-17 19:03

最满意答案

每个动画完成后,您必须调用root.render函数。 因此,请在root.render函数中调用root.animate函数。 喜欢这个 -

var root = this;

    animate: function() {

            // Development
            console.log("init Animate");

            requestAnimationFrame( root.animate );

            root.mesh.rotation.x += .05;
            root.mesh.rotation.y += .05;
            root.render();
        }, 

另外,我不知道你为什么需要LoadingManager 。 我不认为它应该在animate函数中使用,它将被重复调用。

编辑:您必须在函数之外定义root变量。 您已在每个函数中定义了此变量。 相反,你必须在CubeController定义它。


You have to call the root.render function after each animation is done. So call the root.render function in your root.animate function. Like this -

var root = this;

    animate: function() {

            // Development
            console.log("init Animate");

            requestAnimationFrame( root.animate );

            root.mesh.rotation.x += .05;
            root.mesh.rotation.y += .05;
            root.render();
        }, 

Also, i dont know why do you need LoadingManager. I dont think it should be used in the animate function which will be called repeatedly.

Edit: You have to define the root variable outside of the functions. You have defined this variable in every function. Instead you have to define it in the CubeController.

相关问答

更多
  • 每个动画完成后,您必须调用root.render函数。 因此,请在root.render函数中调用root.animate函数。 喜欢这个 - var root = this; animate: function() { // Development console.log("init Animate"); requestAnimationFrame( root.animate ); root.m ...
  • 弄清楚如何使其工作并希望帮助他人。 首先,我需要使用基本的require define函数包装OrbitControls.js define(['threejs'], function(THREE) { /* OrbitControls.js */ }); 然后在课堂上使用控件的必须定义'orbitControls' define(['orbitControls'], function() { var controls = new THREE.OrbitControls(this.came ...
  • camera.lookAt( object.position )将完成你想要的大部分。 将摄像机定位在合适的距离是更主观的。 我通常做这样的事情: object.updateMatrixWorld(); const box = new THREE.Box3().setFromObject(object); const size = box.getSize().length(); const center = box.getCenter(); object.position.x += (object.pos ...
  • 以下是如何找到要使用的字体名称: 打开typeface.js文件 寻找font_family属性: "font_family_name":"Trebuchet MS" 将其更改为全部小写 。 空间很好。 所以在你的例子中: var textGeo = new THREE.TextGeometry( "THREE.JS", { size: 200, height: 50, curveSegments: 12, font: "trebuchet ms", // wei ...
  • Object3D.translateX (和其他翻译方法)是可加的。 这意味着如果你的X值已经是5,并且你打电话给myMesh.translateX(5) ,你的新myMesh.position.x将是10 。 为此,您需要计算拖动对象的原始position.x x与其新position.x x之间的差异,然后将其应用于所有其他对象。 这里有一些代码/伪代码是一个非常宽松的例子。 如果您希望在拖动时发生这种情况,则需要计算每帧的差异(或者经常打算更新)。 // start dragging original ...
  • 以下是Three.js和Blender的简单教程。 最简单的方法就是使用Three.ColladaLoader 。 将您的.dae文件放在您的/root目录中标题为models的文件夹中。 在init()函数内调用Collada函数。 function init(){ scene = new THREE.scene; ... var object1 = new PinaCollada('model1', 1); scene.add(object1); var obj ...
  • 您所要做的就是在渲染循环中添加以下行: airplane.translateZ( 1 ); 更新小提琴: http : //jsfiddle.net/Lc8gH/21/享受! 顺便说一句,你不能“翻译四元数”。 继续学习直到你理解这段代码的作用。 All you have to do is add the following line in your render loop: airplane.translateZ( 1 ); Updated Fiddle: http://jsfiddle.net/Lc ...
  • 您需要在网格上设置receiveShadow标志。 查看Object3D的文档,它是Mesh的父级。 https://jsfiddle.net/woa7kzz1/ You need to set the receiveShadow flag on your meshes. Look at the documentation of Object3D which is the parent of Mesh. https://jsfiddle.net/woa7kzz1/
  • 是的,在three.js中支持删除剪切平面的交叉点 。 你可以使用这样的模式: // clipping planes var localPlanes = [ new THREE.Plane( new THREE.Vector3( - 1, 0, 0 ), 1 ), new THREE.Plane( new THREE.Vector3( 0, - 1, 0 ), 1 ) ]; // material var material = new THREE.MeshPhongMaterial( { ...
  • 我发现只有这一个: https://github.com/mrdoob/three.js/blob/master/examples/webgl_animation_scene.html 还有,能够自己写一个: //Let's create a mesh this.mesh = new THREE.Mesh( geometry, material ); this.clock = new THREE.Clock(); //Save this mixer somewhere this.mixer = new ...

相关文章

更多

最新问答

更多
  • 如何使用自由职业者帐户登录我的php网站?(How can I login into my php website using freelancer account? [closed])
  • 如何打破按钮上的生命周期循环(How to break do-while loop on button)
  • C#使用EF访问MVC上的部分类的自定义属性(C# access custom attributes of a partial class on MVC with EF)
  • 如何获得facebook app的publish_stream权限?(How to get publish_stream permissions for facebook app?)
  • 如何并排放置两个元件?(How to position two elements side by side?)
  • 在MySQL和/或多列中使用多个表用于Rails应用程序(Using multiple tables in MySQL and/or multiple columns for a Rails application)
  • 如何隐藏谷歌地图上的登录按钮?(How to hide the Sign in button from Google maps?)
  • Mysql左连接旋转90°表(Mysql Left join rotate 90° table)
  • 带有ImageMagick和许多图像的GIF动画(GIF animation with ImageMagick and many images)
  • 电脑高中毕业学习去哪里培训
  • 电脑系统专业就业状况如何啊?
  • IEnumerable linq表达式(IEnumerable linq expressions)
  • 如何在Spring测试中连接依赖关系(How to wire dependencies in Spring tests)
  • Solr可以在没有Lucene的情况下运行吗?(Can Solr run without Lucene?)
  • 如何保证Task在当前线程上同步运行?(How to guarantee that a Task runs synchronously on the current thread?)
  • 在保持每列的类的同时向数据框添加行(Adding row to data frame while maintaining the class of each column)
  • 的?(The ? marks in emacs/haskell and ghc mode)
  • 一个线程可以调用SuspendThread传递自己的线程ID吗?(Can a thread call SuspendThread passing its own thread ID?)
  • 延迟socket.io响应,并“警告 - websocket连接无效”(Delayed socket.io response, and “warn - websocket connection invalid”)
  • 悬停时的图像转换(Image transition on hover)
  • IIS 7.5仅显示homecontroller(IIS 7.5 only shows homecontroller)
  • 没有JavaScript的复选框“关闭”值(Checkbox 'off' value without JavaScript)
  • java分布式框架有哪些
  • Python:填写表单并点击按钮确认[关闭](Python: fill out a form and confirm with a button click [closed])
  • PHP将文件链接到根文件目录(PHP Linking Files to Root File Directory)
  • 我如何删除ListView中的项目?(How I can remove a item in my ListView?)
  • 您是否必须为TFS(云)中的每个BUG创建一个TASK以跟踪时间?(Do you have to create a TASK for every BUG in TFS (Cloud) to track time?)
  • typoscript TMENU ATagParams小写(typoscript TMENU ATagParams lowercase)
  • 武陟会计培训类的学校哪个好点?
  • 从链接中删除文本修饰(Remove text decoration from links)