MK_FP
raw OCR
Makes a far pointer.
Defined in header <dos.h>
Syntax
#include <dos.h>
void far * MK_FP(unsigned seg, unsigned ofs);
Portability
| DOS | UNIX | Windows | ANSI C | C++ only |
|---|---|---|---|---|
| ■ | ■ |
Remarks
| l\/IK_FP is a macro that makes a far pointer from its component | segment |
(seg) and offset (ofs) parts.
Return value
MK_FP returns a far pointer.
See also
Example
#include <dos.h>
#include <graphics.h>
int main(void)
{
int gd, gm, i;
unsigned int far *screen;
detectgraph(&gd,' &gm);
if (gd == HERCMONO)
screen = MK_FP(OxBOOO, 0);
else
screen = MK_FP(0xB800, 0);
for (i = 0; i < 26; i++)
screen[i] - 0x0700 + ('a' +
return 0;
Differences from modern implementations
Nothing recorded yet.
Modern references
These are search links, not yet checked by hand.
Extraction notes
- heading `MK FP` read as `MK_FP`
Stable link: /3.1/dos.h/MK_FP/
· short form /3.1/MK_FP/