简体   繁体   中英

How to get the total amount of memory used by OpenGL in mobile devices?

I've found the answer for desktops , but I could not find anything for Android/iOS (assume I can use up to OpenGL ES 3.0). So this is the same question for mobile devices: Is it possible to get the total memory in bytes used by OpenGL by my application programatically?

Note: I am OK with a non-universal solution (AFAIK universal solution does not exists), but something that works at least on popular devices (iOS/Snapdragon/..)

No, it's not possible via any standard API.

Most graphics drivers will account any graphics memory to the process, so you can always use the "top" command line utility to get total process memory. It's not able to isolate the graphics memory, but it should give you an idea how how much your process is using in total.

That said, you probably have a pretty good idea how much data you uploaded/allocated storage for using the GLES API, which is probably a good finger in the air estimate for total memory. Most of the bulk storage related to application assets.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM