views:

11

answers:

0

Using e.g. the command line tool and creating a NSDictionary from the output of:

system_profiler -xml SPDisplaysDataType

it is possible to get to know the amount of video memory. The key spdisplays_vram contains e.g. the string "512 MB". However, on a graphic card with shared video memory only the identifier spdisplays_integrated_vram is returned. In the dictionary there is no key with that identifier and also no other values, which looks like the desired value.

In the GUI version of System-Profiler there is however the correct value represented (e.g. "64 MB of Shared System Memory").

How do I get this value with an C / C++ / Objective-C program?