gr_mappa.gml

来自「开放源码的编译器open watcom 1.6.0版的源代码」· GML 代码 · 共 40 行

GML
40
字号
.gfunc remapallpalette
.if '&lang' eq 'C' .do begin
short _FAR _remapallpalette( long _FAR *colors );
.do end
.el .do begin
integer*2 function _remapallpalette( colors )
integer*4 colors(*)
.do end
.gfuncend
.desc begin
The &func &routine sets (or remaps) all of the colors in the palette.
The color values in the palette are replaced by the array of
color values given by the argument
.arg colors.
This &routine is supported in all video modes, but only works
with EGA, MCGA and VGA adapters.
.np
The array
.arg colors
must contain at least as many elements as there are supported colors.
The newly mapped palette will cause the complete screen to change color
wherever there is a pixel value of a changed color in the palette.
.pp
The representation of colors depends upon the hardware being used.
The number of colors in the palette can be determined by using the
.kw _getvideoconfig
&routine..
.desc end
.return begin
The &func &routine returns (-1) if the palette is remapped successfully
and zero otherwise.
.return end
.see begin
.seelist &function. _remappalette _getvideoconfig
.see end
.grexam begin eg_mappa.&langsuff
.grexam end
.class &grfun
.system

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?