DOS graphics help!!

This is a discussion on DOS graphics help!! within the C++ Programming forums, part of the General Programming Boards category; Can neone possiby tell me the mode number to be passed on to the setmode() function to initialize high resolution ...

  1. #1
    Registered User kiss_psycho's Avatar
    Join Date
    Feb 2003
    Posts
    49

    Question DOS graphics help!!

    Can neone possiby tell me the mode number to be passed on to the setmode() function to initialize high resolution graphics mode in c++. 0x13 mode number increases the number of available colors to 256, but lowers the resolution to 320/200 pixels, significantly lower than even stangard BGI (640/480). But in 0x13 mode I can access video memory directly, at locaton 0xA000 which makes the refreshing of the screen super quick, compared with the slow BGI. I tried using different mode numbers, but the results are erratic. Sometimes resolution increases at the cost of the Y axis and (1152/150) pixels are allI get.

    Actually this is to improve a cricket game I made in BGI graphics. Higher resolution and a wider range of colors than the miserly 16 of BGI would do wonders for the game and the sport.
    Definition of Programmer : A red-eyed mumbling mammal capable of conversing with inanimate objects.

    Happy Hunting...
    The Root

  2. #2
    Registered User
    Join Date
    Sep 2002
    Posts
    1,640
    Don't cross post!

  3. #3
    Registered User kiss_psycho's Avatar
    Join Date
    Feb 2003
    Posts
    49
    Hell!! Whats that supposed to mean???
    Definition of Programmer : A red-eyed mumbling mammal capable of conversing with inanimate objects.

    Happy Hunting...
    The Root

  4. #4
    Registered User
    Join Date
    Sep 2002
    Posts
    1,640
    Originally posted by kiss_psycho
    Hell!! Whats that supposed to mean???
    It means don't post the same thread on different boards.

  5. #5
    RoD
    RoD is offline
    Redundantly Redundant RoD's Avatar
    Join Date
    Sep 2002
    Location
    Missouri
    Posts
    6,331
    dont post same topic twice or in two diff places, its in the rules. Read my sig readme's

  6. #6
    Registered User kiss_psycho's Avatar
    Join Date
    Feb 2003
    Posts
    49
    Sorry man, didn't notice. Now can someone help me out please, instead of all these warnings.
    Definition of Programmer : A red-eyed mumbling mammal capable of conversing with inanimate objects.

    Happy Hunting...
    The Root

  7. #7
    Confused Magos's Avatar
    Join Date
    Sep 2001
    Location
    Sweden
    Posts
    3,145
    As far as I know, those old DOS modes have only a max of 65536 bytes available, meaning you can't have both high-res and lots of colors.

    Mode 13 is 320x200 with 256 colors. Each color fits in one byte (2^8 = 256) so the total memory used for that is 1 * 320 * 200 = 64000 < 65536.

    I'm not an expert on BGI. Used it a little years ago, but IMO it stinks so I left it.

    There is SVGA for higher res, but don't ask me about that .

    I'd suggest DirectX or some similar API for high res multi color graphics.
    MagosX.com

    Give a man a fish and you feed him for a day.
    Teach a man to fish and you feed him for a lifetime.

  8. #8
    Registered User kiss_psycho's Avatar
    Join Date
    Feb 2003
    Posts
    49
    I cant use Direct X in Turbo C++, can I?? Is there no way out of this 640 kb limit mess? Far pointers didn't help either. Erratic allocations occur beyond conventional core memory.

    This is really hell!!!! and i am in it -- burning.
    Definition of Programmer : A red-eyed mumbling mammal capable of conversing with inanimate objects.

    Happy Hunting...
    The Root

  9. #9
    Confused Magos's Avatar
    Join Date
    Sep 2001
    Location
    Sweden
    Posts
    3,145
    Ever considered switching compiler?
    MagosX.com

    Give a man a fish and you feed him for a day.
    Teach a man to fish and you feed him for a lifetime.

  10. #10
    Registered User kiss_psycho's Avatar
    Join Date
    Feb 2003
    Posts
    49
    Borland 5.0? Did but can't access beyond conventional mem there as well.
    Definition of Programmer : A red-eyed mumbling mammal capable of conversing with inanimate objects.

    Happy Hunting...
    The Root

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. DOS graphics help!!
    By kiss_psycho in forum C Programming
    Replies: 2
    Last Post: 02-21-2003, 02:28 PM
  2. Graphics for DOS under Dev-C++
    By bubux in forum C Programming
    Replies: 16
    Last Post: 07-08-2002, 02:24 PM
  3. Dos graphics header
    By Vicious in forum A Brief History of Cprogramming.com
    Replies: 7
    Last Post: 05-14-2002, 01:24 PM
  4. Extremely Simple Graphics In Dos
    By Unregistered in forum A Brief History of Cprogramming.com
    Replies: 2
    Last Post: 03-07-2002, 07:25 PM
  5. VC++ graphics in dos.
    By StormySpike in forum C++ Programming
    Replies: 5
    Last Post: 09-28-2001, 11:24 AM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21