We use cookies to ensure that we give you the best experience on our website. If you continue to use this site we will assume that you are happy with it.

GPU usage

Home Forums Programming GPU usage

Viewing 14 posts - 1 through 14 (of 14 total)
  • Author
    Posts
  • #10043
    dragosburian
    Customer

    We 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!

    #10044

    Hi,

    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.

    Chief 3D Verger | LinkedIn | Twitter

    #10084
    dragosburian
    Customer

    Hi,

    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

    #10106

    Hi,

    As we started working on the implementation of the dispose method for cleaning up GPU resources, I suggest we wait until its ready and first see how it works for your project. Then we can try the approach with skipping the rendering frames.

    Chief 3D Verger | LinkedIn | Twitter

    #10107
    Yorick
    Customer

    Hi 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…

    #10119

    Wouldn’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.

    Chief 3D Verger | LinkedIn | Twitter

    #10328
    vlado
    Customer

    Hey 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

    #10345

    Hi,

    How do you access the setAnimationLoop function?

    Chief 3D Verger | LinkedIn | Twitter

    #10395
    Yorick
    Customer

    On 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.

    #10401

    Hi,

    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

    Chief 3D Verger | LinkedIn | Twitter

    #10416
    elk
    Customer

    I 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.

    #10420
    vlado
    Customer

    I tried with this:

    scope.renderer.setAnimationLoop(cb);

    but setAnimationLoop does not exists in my renderer object

    www.hivecpq.com

    #10428

    Emailed the code snippet as per the conference call.

    Chief 3D Verger | LinkedIn | Twitter

    #10429
    Yorick
    Customer

    Thank you very much Yuri, we’ll start working on it.

Viewing 14 posts - 1 through 14 (of 14 total)
  • You must be logged in to reply to this topic.