Home › Forums › Programming › GPU usage
Tagged: gpu usage problem
- This topic has 13 replies, 5 voices, and was last updated 6 years, 9 months ago by Yorick. 
- 
		AuthorPosts
- 
		
			
				
2018-12-19 at 12:44 pm #10043dragosburian CustomerWe are having a GPU consumption problem the seems to come from the fact that the scene is continuously rendered even if the scene is still, which would leave users using integrated gpus at 100% usage. Is there any way to make the scene still(like a snapshot) until the user either changes something or manipulates the view? Among the code examples there is this one, which acts exactly how we would like it to, it uses the gpu only when being manipulated, then it goes to 0%, as if it would show a still image. https://cdn.soft8soft.com/demo/examples/index.html#webgl_clipping_intersection Also, we get notices in the console of this kind, can this be affecting performance as well?: v3d.WebGLProgram: gl.getProgramInfoLog() C:\fakepath(122,25-100): warning X3571: pow(f, e) will not work for negative f, use abs(f) or conditionally handle negative values if you expect them Thank you! 2018-12-19 at 2:37 pm #10044 Yuri KovelenovStaff Yuri KovelenovStaffHi, You can possibly override the default animate() method of the App class, which looks as follows animate: function() { 
 var scope = this;var cb = function() { var elapsed = scope.clock.getDelta(); 
 scope.elapsed = elapsed;if (scope.mixer) 
 scope.mixer.update(elapsed);if (scope.controls) 
 scope.controls.update(elapsed);var rbs = scope.renderCallbacks; 
 for (var i = 0; i < rbs.length; i++) rbs[i](elapsed, scope.clock.elapsedTime); scope.render(); scope.frame++; } scope.renderer.setAnimationLoop(cb); } to only run when you need it. We are aware of that WebGL warning on Window but I don't think it is a major cause. The integrated GPUs do not allow for highly parallel computing.2018-12-20 at 12:34 pm #10084dragosburian CustomerHi, Thanks you for the fast reply, is this code altering in the v3d.js file ? 
 Could you provide us with the altered file that runs the render on manipulating or changing prefs? Thank you!Dragos 2018-12-21 at 9:45 am #10106 Yuri KovelenovStaff2018-12-21 at 9:55 am #10107 Yuri KovelenovStaff2018-12-21 at 9:55 am #10107Yorick CustomerHi Yuri, Wouldn’t this be a great feature for Verge3D in general? Seems like a super feature to me. I understand your comment with regards to the dispose method. But in 10 days time we will have a lot of clients going live with our product and they will not be happy if their machines grind to a halt when using our application… 2018-12-21 at 2:54 pm #10119 Yuri KovelenovStaff Yuri KovelenovStaffWouldn’t this be a great feature for Verge3D in general? Seems like a super feature to me. Yes, but it can only work in the specific case when a scene is updated via user input. in 10 days time we will have a lot of clients going live with our product I understand. We can consider implementing this then. I’ll drop you a line. 2019-01-04 at 1:51 pm #10328 vladoCustomer vladoCustomerHey Yuri, How can i access setAnimationLoop function, i don’t have it on renderer object. It seams that is not supported by Three.js version which is bundled in v3d.js file, at least one we use. www.hivecpq.com 2019-01-05 at 1:50 pm #10345 Yuri KovelenovStaff2019-01-07 at 8:15 am #10395 Yuri KovelenovStaff2019-01-07 at 8:15 am #10395Yorick CustomerOn a side note Yuri: can you share how your team implemented it on https://cdn.soft8soft.com/demo/examples/index.html#webgl_clipping_intersection ? 
 Because there it seems to be already working.2019-01-07 at 10:07 am #10401 Yuri KovelenovStaff Yuri KovelenovStaffHi, an you share how your team implemented it on Please see the source code here: https://github.com/Soft8Soft/verge3d-code-examples/blob/master/webgl_clipping_intersection.html 2019-01-07 at 2:57 pm #10416 elkCustomer elkCustomerI would also like to add a vote for this as a feature. Would be great for applications where the user don’t constantly move around and interact, for instance when the application is just a small part of a page, like a product preview where there is a loot of other information to read and look at on the page. 2019-01-07 at 7:01 pm #10420 vladoCustomer vladoCustomerI tried with this: scope.renderer.setAnimationLoop(cb);but setAnimationLoop does not exists in my renderer object www.hivecpq.com 2019-01-08 at 8:54 am #10428 Yuri KovelenovStaff2019-01-08 at 8:55 am #10429 Yuri KovelenovStaff2019-01-08 at 8:55 am #10429Yorick CustomerThank you very much Yuri, we’ll start working on it. 
- 
		AuthorPosts
- You must be logged in to reply to this topic.
