This is a very simple DLL to return three things about the video card:
All of the video memory and other video card informations are located in the Windows registry. Unfortunately, pre-NT Windows versions have the information in a different location. I'll go over how to get both, and at the end, I'll post the DLL. If you want to learn something, read on. If you really don't give a hoot, just download the DLL.
Like I said before the video card informations are located in the registry, but not in a given location. That's the tricky part. First, we need to find the registry key for the video card. To do that, we go to the HARDWARE\DEVICEMAP\VIDEO in HKEY_LOCAL_MACHINE. We then search for the key labeled \Device\Video0. In this key, you will find the location of the video card information, but it's not so straightforward.
The text in this key should look something like this:
(The numbers/text in the brackets may differ)
To use this, we need to cut off the "\Registry\Machine" part. After we do that, we have the location of the video card information.
If you're manually viewing this in regedit, you will now see a list of keys in the 0000 subkey. To find the video memory, we need to search for this key: HardwareInformation.MemorySize. Unfortunately, the type of this key is is REG_BINARY, which Game Maker can't return with it's own functions, which is why I'll write you a small DLL. If I missed something huge and didn't realize Game Maker could return such values, please correct me.
Anyways, when you get the data from HardwareInformation.MemorySize it's not going to be in MB form, it will be in bytes. To put it in MB form, simply divide it by 1024 twice. If you want it in KB form, divide it by 1024 once.
Now, getting this information in a pre-NT environment is relatively easier. We do not need to hunt for the information, because it's in a nice convenient location. Locate to this key: System\CurrentControlSet\Services\Class\Display\0000\INFO, and this subkey: VideoMemory.
Retrieving the other information in this DLL is the same as getting the memory. They are just located in different keys.
This DLL was quickly made in response to this topic:
VideoCardDLL.zip (~5 KB)