Mail Archives: djgpp/1998/06/04/19:30:44
IPityTheFo wrote:
>
> This is the code I use to create a pointer to the video buffer:
> char far *video_buffer = (char far)0xA0000000L;
> The compiler tells me that you can't convert a pointer to a char far.
> Can someone help me out with that?
>
> Also I use this to fill the screen with a certain color:
> #define SCREEN_WIDTH unsigned int
> #define SCREEN_HEIGHT
> void fill_screen(int value) {
> _fmemset(video_buffer,(char)value,SCREEN_WIDTH*SCREEN_HEIGHT+1);
> }
> The compiler tells me that the _fmemset line is so badly of a formed statement
> that it is impossible to compile. Can someone help me out with that?
>
> It may help to know that I'm using a DOS Pacific C compiler.
We can't give technical support for compilers other than DJGPP.
If you were using DJGPP, I'd tell you that DJGPP programs run in
protected mode; therefore, there is no such thing as a 'far' pointer,
you can't directly address conventional memory, and there is no
_fmemset() function (yet).
For your "new" compiler, I have no clue.
BTW, I think we've managed to isolate several cases where gcc 2.8.1 for
DJGPP appears to lock up when run under a Windows 95 DOS box. In some
of these cases, the DJGPP environment variable was not set (a bugfix for
this is in the works). There were other cases where DJGPP programs
would lock up after a child DJGPP program returned if they called
__dpmi_yield(). There is no solution for this as yet but it's being
worked on.
I really wish you'd tried to answer the questions I asked you instead of
complaining and running away, because I might have been able to solve
your problem. I guess we can't win them all...
--
---------------------------------------------------------------------
| John M. Aldrich | "Always listen to experts. They'll |
| aka Fighteer I | tell you what can't be done, and why.|
| mailto:fighteer AT cs DOT com | Then do it." |
| http://www.cs.com/fighteer/| - Lazarus Long |
---------------------------------------------------------------------
- Raw text -