Message-ID: <01BBAE21.6FD4EE40@slip00-17.btx.dtag.de> From: Daniel Jungbluth To: "'DJGPP Mailing List'" Subject: Re: graphics Date: Sun, 29 Sep 1996 14:51:08 +-100 MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Ben Lewis wrote: >is there any graphics library for djgpp that uses 64K colors. I've = checked >books and the internet, but i can't find a dos graphics library or even >help on how to do more than 256 colors. if there is no library, i will >write one myself if sent the specs on VESA 64K colors.=20 First of all, I don't know, if there's a graphics library for djgpp = supporting 64k colours. But I can give you some information for writing = an own library. I expect, that you have some experience with programming VESA-cards. If = not, send me a email to get more information. It follows a short(!) = summary of VESA 64k modes: VESA spec v1.2 64k graphic modes and their resolutions: 0x10e - 320x200 0x111 - 640x480 0x114 - 800x600 0x117 - 1024x768 0x11a - 1280x1024 How to set a VESA graphic mode: int setVESAmode(unsigned short mode) { __dpmi_regs regs; regs.x.ax=3D0x4f02; regs.x.bx=3Dmode; __dpmi_simulate_real_mode_interrupt(0x10,®s); return(regs.x.ah); /* returns 0, if success */ } Set-up of the video-mem: ScreenOffset =3D ( Width * y + x ) * 2; /* ScreenOffset in bytes */ Set-up of one pixel (word): bits 0-4: blue bits 5-10: green bits 11-15: red This summary is very short, so if you want to know more, send me a = email. -Daniel Jungbluth email: danju AT t-online DOT de internet: http://www.t-online.de/home/danju/index.htm -semper fidelis