how to display a .bmp if i dont want to use...

Started by
3 comments, last by apocalexiz 21 years, 1 month ago
any asm, windows function, opengl, directx. But i dont know how, i cant write into the memory of my graphics board so that the .bmp appears onto my screen, right? So i need information about this. I''d like a good internet site or some pretty well done tutorials thx for help bye apo
Advertisement
Well, you will obviously have to write SOME kind of code to output a bitmap on the screen.
The easiest way is to code it in DOS, using mode13, but the problem there is that you can only use 256 color bitmaps in 320x200...
If you choose that approach all you have to do is load the bitmap, set the palette of the bitmap and simply copy the bitmap into the vga memory (0xA0000).
If you would like to view higher resolution and more color bitmaps, you will have to either use svga mode (which is a bit tricky) or use windows functions to create a window and put the bitmap in there.
As far as I know you can''t access the videomemory which is used by the windows graphics driver directly...
Another approach is to write it in linux instead, using either the framebuffer or svgalib, or even write it in xlib.
erim
****

ok, i want to use svga where should i start? do you know any good tutorial about this?

thx for help

bye

apo
You''d pretty much have to use asm for SVGA.

You could look into SDL - it''s cross-platform so you can run it on PC, Linux, Mac etc.

Helpful links:
How To Ask Questions The Smart Way | Google can help with your question | Search MSDN for help with standard C or Windows functions
Well if your writing code under windows you are going to have to use an API. This means GDI, OpenGL, DirectX or other variants. There are a few reasons why..first and foremost is that any of the new windows os''s such as Windows XP and Windows 2k have completely phased DOS out. This means there is no real way to access mode 13h anymore. Now you can''t access the video card directly under windows either because the OS has control of it for drawing windows/icons and the rest of that stuff. So that leaves you to choose an API as stated above in order to load and display a bitmap.

This topic is closed to new replies.

Advertisement