Mail Archives: djgpp/1999/07/17/15:58:10
Mark wrote:
>
> Hello,
>
> I got this snippet from the DJGPP FAQ using short screen =
> __dpmi_segment_to_descriptor(0xa000) and the movedata() function.
>
> I tried to implement it in a simple program. But it gives me garbage on the
> screen. A sreen full of ramdom colored pixels while it suppose to put just
> a single vertical red line on the screen.
> Can anyone help me out here ?
> (See below for the source)
Your malloced buffer is filled with random bytes when you first allocate
it. You probably want to do
memset(double_buffer, 0, 320 * 200);
before drawing.
--
Nate Eldredge
nate AT cartsys DOT com
- Raw text -