dibeng.inc
来自「用于查询PC机上的USB端口是否有设备挂接上」· INC 代码 · 共 303 行 · 第 1/2 页
INC
303 行
dceBlue db ? ;*/ BYTE dceBlue; /*
dceGreen db ? ;*/ BYTE dceGreen; /*
dceRed db ? ;*/ BYTE dceRed; /*
dceFlags db ? ;*/ BYTE dceFlags; /*
DIBColorEntry ends ;*/ } DIBColorEntry; /*
;----------------------------------------------------------------------------
; Definitions for DIBColorEntry.dceFlags
;----------------------------------------------------------------------------
NONSTATIC equ 10000000b ;Inhibits color matching to this entry.
MAPTOWHITE equ 00000001b ;0=Black, 1=White
comment ~
*/
#define NONSTATIC 0x80
#define MAPTOWHITE 0x01
/*
end comment ~
;----------------------------------------------------------------------------
;----------------------------------------------------------------------------
; DIB Engine Physical Object Definitions
;----------------------------------------------------------------------------
DIB_Pen struc ;*/ typedef struct { /*
dpPenStyle dw ? ;*/ WORD dpPenStyle; /*
dpPenFlags db ? ;currently none undefined. ;*/ BYTE dpPenFlags; /*
dpPenBpp db ? ;*/ BYTE dpPenBpp; /*
dpPenMono dd ? ;*/ DWORD dpPenMono; /*
dpPenColor dd ? ;*/ DWORD dpPenColor; /*
DIB_Pen ends ;*/ } DIB_Pen; /*
DIB_Brush1 struc ;*/ typedef struct { /*
dp1BrushFlags db ? ;Accelerator for solids ;*/ BYTE dp1BrushFlags; /*
dp1BrushBpp db ? ;Brush Bits per pixel format ;*/ BYTE dp1BrushBpp; /*
dp1BrushStyle dw ? ;Style of the brush ;*/ WORD dp1BrushStyle; /*
dp1FgColor dd ? ;Physical fg color ;*/ DWORD dp1FgColor; /*
dp1Hatch dw ? ;Hatching style ;*/ WORD dp1Hatch; /*
dp1BgColor dd ? ;Physical bg color ;*/ DWORD dp1BgColor; /*
dp1BrushMono db BRUSHSIZE*4 dup (?) ;Mono portion ;*/ BYTE dp1BrushMono [BRUSHSIZE*4];/*
dp1BrushMask db BRUSHSIZE*4 dup (?) ;transparency mask (hatch pattern);*/ BYTE dp1BrushMask [BRUSHSIZE*4];/*
dp1BrushBits db BRUSHSIZE*4 dup (?) ;8 rows, 8 columns of 1 bit/pixel ;*/ BYTE dp1BrushBits [BRUSHSIZE*4];/*
DIB_Brush1 ends ;*/ } DIB_Brush1; /*
DIB_Brush4 struc ;*/ typedef struct { /*
dp4BrushFlags db ? ;Accelerator for solids ;*/ BYTE dp4BrushFlags; /*
dp4BrushBpp db ? ;Brush Bits per pixel format ;*/ BYTE dp4BrushBpp; /*
dp4BrushStyle dw ? ;Style of the brush ;*/ WORD dp4BrushStyle; /*
dp4FgColor dd ? ;Physical fg color ;*/ DWORD dp4FgColor; /*
dp4Hatch dw ? ;Hatching style ;*/ WORD dp4Hatch; /*
dp4BgColor dd ? ;Physical bg color ;*/ DWORD dp4BgColor; /*
dp4BrushMono db BRUSHSIZE*4 dup (?) ;Mono portion ;*/ BYTE dp4BrushMono [BRUSHSIZE*4];/*
dp4BrushMask db BRUSHSIZE*4 dup (?) ;transparency mask (hatch pattern);*/ BYTE dp4BrushMask [BRUSHSIZE*4];/*
dp4BrushBits db BRUSHSIZE*4 dup (?) ;8 rows, 8 columns of 4 bit/pixel ;*/ BYTE dp4BrushBits [BRUSHSIZE*4];/*
DIB_Brush4 ends ;*/ } DIB_Brush4; /*
DIB_Brush8 struc ;*/ typedef struct { /*
dp8BrushFlags db ? ;Accelerator for solids ;*/ BYTE dp8BrushFlags; /*
dp8BrushBpp db ? ;Brush Bits per pixel format ;*/ BYTE dp8BrushBpp; /*
dp8BrushStyle dw ? ;Style of the brush ;*/ WORD dp8BrushStyle; /*
dp8FgColor dd ? ;Physical fg color ;*/ DWORD dp8FgColor; /*
dp8Hatch dw ? ;Hatching style ;*/ WORD dp8Hatch; /*
dp8BgColor dd ? ;Physical bg color ;*/ DWORD dp8BgColor; /*
dp8BrushMono db BRUSHSIZE*4 dup (?) ;Mono portion ;*/ BYTE dp8BrushMono [BRUSHSIZE*4];/*
dp8BrushMask db BRUSHSIZE*4 dup (?) ;transparency mask (hatch pattern);*/ BYTE dp8BrushMask [BRUSHSIZE*4];/*
dp8BrushBits db BRUSHSIZE*8 dup (?) ;8 rows,8 columns of 8 bit/pixel ;*/ BYTE dp8BrushBits [BRUSHSIZE*8];/*
DIB_Brush8 ends ;*/ } DIB_Brush8; /*
DIB_Brush16 struc ;*/ typedef struct { /*
dp16BrushFlags db ? ;Accelerator for solids ;*/ BYTE dp16BrushFlags; /*
dp16BrushBpp db ? ;Brush Bits per pixel format ;*/ BYTE dp16BrushBpp; /*
dp16BrushStyle dw ? ;Style of the brush ;*/ WORD dp16BrushStyle; /*
dp16FgColor dd ? ;Physical fg color ;*/ DWORD dp16FgColor; /*
dp16Hatch dw ? ;Hatching style ;*/ WORD dp16Hatch; /*
dp16BgColor dd ? ;Physical bg color ;*/ DWORD dp16BgColor; /*
dp16BrushMono db BRUSHSIZE*4 dup (?) ;Mono portion ;*/ BYTE dp16BrushMono [BRUSHSIZE*4];/*
dp16BrushMask db BRUSHSIZE*4 dup (?) ;transparency mask (hatch pattern);*/ BYTE dp16BrushMask [BRUSHSIZE*4];/*
dp16BrushBits db BRUSHSIZE*16 dup (?);8 rows,8 columns of 16 bit/pixel;*/ BYTE dp16BrushBits [BRUSHSIZE*16];/*
DIB_Brush16 ends ;*/ } DIB_Brush16; /*
DIB_Brush24 struc ;*/ typedef struct { /*
dp24BrushFlags db ? ;Accelerator for solids ;*/ BYTE dp24BrushFlags; /*
dp24BrushBpp db ? ;Brush Bits per pixel format ;*/ BYTE dp24BrushBpp; /*
dp24BrushStyle dw ? ;Style of the brush ;*/ WORD dp24BrushStyle; /*
dp24FgColor dd ? ;Physical fg color ;*/ DWORD dp24FgColor; /*
dp24Hatch dw ? ;Hatching style ;*/ WORD dp24Hatch; /*
dp24BgColor dd ? ;Physical bg color ;*/ DWORD dp24BgColor; /*
dp24BrushMono db BRUSHSIZE*4 dup (?) ;Mono portion ;*/ BYTE dp24BrushMono [BRUSHSIZE*4];/*
dp24BrushMask db BRUSHSIZE*4 dup (?) ;transparency mask (hatch pattern);*/ BYTE dp24BrushMask [BRUSHSIZE*4];/*
dp24BrushBits db BRUSHSIZE*24 dup (?);8 rows,8 columns of 24 bit/pixel ;*/ BYTE dp24BrushBits [BRUSHSIZE*24];/*
DIB_Brush24 ends ;*/ } DIB_Brush24; /*
DIB_Brush32 struc ;*/ typedef struct { /*
dp32BrushFlags db ? ;Accelerator for solids ;*/ BYTE dp32BrushFlags; /*
dp32BrushBpp db ? ;Brush Bits per pixel format ;*/ BYTE dp32BrushBpp; /*
dp32BrushStyle dw ? ;Style of the brush ;*/ WORD dp32BrushStyle; /*
dp32FgColor dd ? ;Physical fg color ;*/ DWORD dp32FgColor; /*
dp32Hatch dw ? ;Hatching style ;*/ WORD dp32Hatch; /*
dp32BgColor dd ? ;Physical bg color ;*/ DWORD dp32BgColor; /*
dp32BrushMono db BRUSHSIZE*4 dup (?) ;Mono portion ;*/ BYTE dp32BrushMono [BRUSHSIZE*4];/*
dp32BrushMask db BRUSHSIZE*4 dup (?) ;transparency mask (hatch pattern);*/ BYTE dp32BrushMask [BRUSHSIZE*4];/*
dp32BrushBits db BRUSHSIZE*32 dup (?);8 rows,8 columns of 32 bit/pixel ;*/ BYTE dp32BrushBits [BRUSHSIZE*32];/*
DIB_Brush32 ends ;*/ } DIB_Brush32; /*
;----------------------------------------------------------------------------
; Definitions for DIB_Brushxx.dpxxBrushFlags
;----------------------------------------------------------------------------
COLORSOLID equ 00000001b ;Color part is solid.
MONOSOLID equ 00000010b ;Mono part is solid.
PATTERNMONO equ 00000100b ;Pattern brush came from a mono bitmap.
MONOVALID equ 00001000b ;Mono part is valid.
MASKVALID equ 00010000b ;Transparency Mask part is valid.
PRIVATEDATA equ 00100000b ;Vendor specific bit for Pens, Brushes
BRUSH40 equ 01000000b ;
DIBENGBRUSH equ 10000000b ;the DIBENG created this brush
comment ~
*/
#define COLORSOLID 0x01
#define MONOSOLID 0x02
#define PATTERNMONO 0x04
#define MONOVALID 0x08
#define MASKVALID 0x10
#define PRIVATEDATA 0x20
#define BRUSH40 0x40
#define DIBENGBRUSH 0x80
/*
end comment ~
;----------------------------------------------------------------------------
; ColorToMono
; Entry: red, green, blue
; Exit: blue = intensity.
;----------------------------------------------------------------------------
ColorToMono macro red, green, blue
add blue,red ;R+B
rcr blue,1 ;(R+B)/2
add blue,green ;pitch in Green
rcr blue,1 ;G/2 + (R+B)/4
endm ColorToMono
;----------------------------------------------------------------------------
; ColorToMonoBit
; Entry: red, green, blue
; Exit: blue = 0 if color maps to black
; blue = 1 if color maps to white
;----------------------------------------------------------------------------
ColorToMonoBit macro red, green, blue
ColorToMono red,green,blue ; Call ColorToMono to derive intensity.
cmp blue,127
setnc blue
endm ColorToMonoBit
;*/
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?