Skip to content

Cpu times increasing over time indefinely when using postprocessing #58

@Agusmac

Description

@Agusmac

Hi again

Ive been using postprocessing over my whole site (just a landing page) and discovered that when global render is set to false (to use the effect)
the Cpu times increase over time, to the extent that in a couple of minutes, my site cpu times go from 0.5ms to 26ms
I tested some things and figured some things

the more elements rendered to the canvas, the faster this increase goes and some increase it more than other
-geometries: low/no impact (maybe if you add 10K cubes it might but not with a normal amount)
-Text: higher impact
-Images(textured planes): much higher impact

i checked all of this with R3f-Perf
and no other values(calls/polys) seemed to change
and no increase in gpu memory use

Noticed when using my custom postprocessing, but also happens with bloom and other defaults

Here is a sandbox with the issue, using the postprocessing sandbox from the docs:
https://codesandbox.io/p/sandbox/hello-post-processing-forked-wzdd5m?file=%2Fsrc%2FText.jsx%3A34%2C15
If needed i can provide other heavier examples that may show the issue faster (low loads may take 5-10 mins, but the site im building needs 2 to start dropping frames)

Any workarounds are welcome!
Thanks!

Image

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions