3.2.4 META_CREATEBRUSHINDIRECT Example

This section provides an example of a META_CREATEBRUSHINDIRECT Record (section 2.3.4.1).

 00000020:                               07 00 00 00 FC 02
 00000030: 02 00 00 FF 00 FF 04 00


0


1


2


3


4


5


6


7


8


9

1
0


1


2


3


4


5


6


7


8


9

2
0


1


2


3


4


5


6


7


8


9

3
0


1

RecordSize (0x00000007)

RecordFunction (0x02FC)

LogBrush Object (0x0000)

...

...

RecordSize (4 bytes): 0x00000007 specifies the number of WORD structures, defined in [MS-DTYP] section 2.2.61, in this record, which is equivalent to 14 (0x0000000E) bytes.

RecordFunction (2 bytes): 0x02FC specifies a META_CREATEBRUSHINDIRECT record from the RecordType Enumeration (section 2.1.1.1).

LogBrush Object (8 bytes): A LogBrush Object (section 2.2.2.10) that defines the brush to create.


0


1


2


3


4


5


6


7


8


9

1
0


1


2


3


4


5


6


7


8


9

2
0


1


2


3


4


5


6


7


8


9

3
0


1

BrushStyle (0x0002)

ColorRef Object

...

BrushHatch (0x0004)

BrushStyle (2 bytes): 0x0002 specifies the BS_HATCHED style from the BrushStyle Enumeration (section 2.1.1.4).

ColorRef Object (4 bytes): A ColorRef Object (section 2.2.2.8) that specifies a magenta brush color.


0


1


2


3


4


5


6


7


8


9

1
0


1


2


3


4


5


6


7


8


9

2
0


1


2


3


4


5


6


7


8


9

3
0


1

Reserved (0x00)

Blue (0xFF)

Green (0x00)

Red (0xFF)

Reserved (1 byte): 0x00 is not used.

Blue (1 byte): 0xFF specifies full intensity blue.

Green (1 byte): 0x00 specifies no green.

Red (1 byte): 0xFF specifies full intensity red.

BrushHatch (2 bytes): 0x0004 specifies the hatch style from the HatchStyle Enumeration (section 2.1.1.12), a horizontal and vertical cross-hatch.

Note  The Brush Object created by processing this record is assigned index 1 in the WMF Object Table (section 3.1.4.1).