Results 1 to 5 of 5

Thread: Detecting Video Memory Available

  1. #1

    Detecting Video Memory Available

    Is this possible? Also, how many 800 x 600 x 16 bit surfaces would you expect to be able to fit into an 8Mb gfx card? Does Windows hog some of it, or can I use all of the 8Mb for surfaces?
    http://www.c5software.co.uk (site is being developed at the moment)

  2. #2

    Detecting Video Memory Available

    There are 2 bytes for 16 bits (16/8 ), so you get each surface taking up: 800x600x2 = 960000 bytes. 8 Mb = 8 * 1024 * 1024 bytes = 8388608. So dividing them gives you approximately 8.7 (i.e., 8 ) textures then. This ain't taking account of the pitch of the surfaces, which may cause them to use up a little more memory, or mipmaps in 3d (which again will consume a fair bit of memory if used). Hope my calculations aren't wrong -- I'm a little tired.

    The easiest way would be to get hold of an 8meg graphics card and see for yourself.
    "All paid jobs absorb and degrade the mind."
    <br />-- Aristotle

  3. #3

    Detecting Video Memory Available

    Quote Originally Posted by Alimonster
    There are 2 bytes for 16 bits (16/8 ), so you get each surface taking up: 800x600x2 = 960000 bytes. 8 Mb = 8 * 1024 * 1024 bytes = 8388608. So dividing them gives you approximately 8.7 (i.e., 8 ) textures then. This ain't taking account of the pitch of the surfaces, which may cause them to use up a little more memory, or mipmaps in 3d (which again will consume a fair bit of memory if used). Hope my calculations aren't wrong -- I'm a little tired.

    The easiest way would be to get hold of an 8meg graphics card and see for yourself.
    Thanks, I worked it out the same myself, I just don't seem to be able to fit more than 4 or 5 Mb worth of surfaces into 8Mb... I think I need an 8Mb card to test myself.

    http://www.c5software.co.uk (site is being developed at the moment)

  4. #4

    Detecting Video Memory Available

    Is it possible to read out through directx or opengl how much memory is available on a graphics card? When that is known you can use optimized textures.
    http://3das.noeska.com - create adventure games without programming

  5. #5

    Detecting Video Memory Available

    I know this is an old post, but I thought I should reply with the solution:-

    Device.GetAvailableVideoMemory

    If you do this at the start you can decide what to put into VRAM

    NOTE: Value returned will also include AGP Aperture RAM! So if it's 128Mb, and you have a 128Mb card, 256Mb will be reported!
    http://www.c5software.co.uk (site is being developed at the moment)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •