Inkscape
Vector Graphics Editor
Loading...
Searching...
No Matches
uemf.h
Go to the documentation of this file.
1
96/*
97File: uemf.h
98Version: 0.0.34
99Date: 03-JAN-2017
100Author: David Mathog, Biology Division, Caltech
101email: mathog@caltech.edu
102Copyright: 2017 David Mathog and California Institute of Technology (Caltech)
103*/
104
105#ifndef _UEMF_
106#define _UEMF_
107
108#ifdef __cplusplus
109extern "C" {
110#endif
111
112#include <stdlib.h>
113#include <stdio.h>
114#include <stdint.h>
115#include <string.h>
116#include <stdbool.h>
117#include "uemf_utf.h"
118#include "uemf_endian.h"
119
120
122// ***********************************************************************************
123// defines not placed yet
124
125#define U_PAN_CULTURE_LATIN 0
126
127#define U_SYSPAL_ERROR 0
128#define U_SYSPAL_STATIC 1
129#define U_SYSPAL_NOSTATIC 2
130
131#define U_ELF_VENDOR_SIZE 4
132
133#define UNUSED_PARAMETER(x) (void)(x)
136// ***************************************************************************
140#define U_NONE 0
141#define U_PI 3.14159265358979323846
142#define U_READ 1
143#define U_WRITE 0
144#define U_DV_SGNTR 0x08007664
145#define U_LP_VERSION 0x0300
146#define U_RDH_RECTANGLES 1
147#define U_RDH_OBJSIZE 0x20
148#define U_RGB_GAMMA_MIN (uint16_t)02500
149#define U_RGB_GAMMA_MAX (uint16_t)65000
150#define U_REFERENCE_WHITE_MIN (uint16_t)6000
151#define U_REFERENCE_WHITE_MAX (uint16_t)10000
152#define U_REFERENCE_BLACK_MIN (uint16_t)0
153#define U_REFERENCE_BLACK_MAX (uint16_t)4000
154#define U_COLOR_ADJ_MIN ((int16_t)-100)
155#define U_COLOR_ADJ_MAX (int16_t) 100
156#define U_MAX_PATH 1024
157#define U_LCS_SIGNATURE 0x50534F43
158#define U_LCS_VERSION 0x400
159#define U_REC_FREE 1
160#define U_REC_KEEP 0
161#define U_ROW_ORDER_INVERT 1
162#define U_ROW_ORDER_SAME 0
163#define U_CT_NO 0
164#define U_CT_BGRA 1
165#define U_CT_ARGB 1
166#define U_EMR_COMMENT_SPOOLFONTDEF 0x544F4E46
168#define U_ROUND(A) ( (A) > 0 ? floor((A)+0.5) : ( (A) < 0 ? -floor(-(A)+0.5) : (A) ) )
169
170#define MAKE_MIN_PTR(A,B) ( A < B ? A : B)
171/* IS_MEM_UNSAFE takes 3 parameters:
172 A start address of a block of allocated memory
173 B offset into this block starting at A
174 C address of final byte of a block of allocated memory.
175 Returns
176 1 if B cannot be an int or size_t
177 1 if C > A
178 1 if A+B is not in the range A to C, inclusive
179 0 otherwise.
180 B may be an int, an unsigned int, or a size_t. An int can be negative,
181 which is obviously wrong, but testing for that means that the size
182 of B cannot be more than INT_MAX/2. Accept that limitation since
183 no reasonable EMF record or file should ever be that large.
184 If B is a uint16_t gcc complains about the first test.
185 This Macro must not be used where B needs more than 32 bits!
186*/
187#define IS_MEM_UNSAFE(A,B,C) ( (sizeof(B) < sizeof(int) || (int)(B) < 0) ? 1 : ((int8_t *)(A) > (int8_t *)(C) ? 1 : ((int8_t *)(C) - (int8_t *)(A) >= (int)(B) ? 0 : 1 )))
188
192typedef float U_FLOAT;
193
194typedef uint32_t U_CBBITS;
195typedef uint32_t U_CBBITSMSK;
196typedef uint32_t U_CBBITSSRC;
197typedef uint32_t U_CBBMI;
198typedef uint32_t U_CBBMIMSK;
199typedef uint32_t U_CBBMISRC;
200typedef uint32_t U_CBDATA;
201typedef uint32_t U_CBNAME;
202typedef uint32_t U_CBPLENTRIES;
203typedef uint32_t U_CBPXLFMT;
204typedef uint32_t U_CBRGNDATA;
205typedef uint32_t U_CBSTR;
206
207typedef uint32_t U_OFFBITS;
208typedef uint32_t U_OFFBITSMSK;
209typedef uint32_t U_OFFBITSSRC;
210typedef uint32_t U_OFFBMI;
211typedef uint32_t U_OFFBMIMSK;
212typedef uint32_t U_OFFBMISRC;
213typedef uint32_t U_OFFDATA;
214typedef uint32_t U_OFFDESC;
215typedef uint32_t U_OFFDX;
216typedef uint32_t U_OFFPLENTRIES;
217typedef uint32_t U_OFFPXLFMT;
218typedef uint32_t U_OFFSTR;
219typedef uint8_t U_DATA;
220
221// "Types" For array components in structures, where not otherwise defined as a structure
222typedef uint32_t U_FNTAXES;
223typedef uint32_t U_STYLEENTRY;
224typedef uint32_t U_POLYCOUNTS;
225
226// "Counts" for array components in structures
227typedef uint32_t U_NUM_FNTAXES;
228typedef uint32_t U_NUM_LOGPLTNTRY;
229typedef uint32_t U_NUM_RECTL;
230typedef uint32_t U_NUM_POINTL;
231typedef uint32_t U_NUM_POINT16;
232typedef uint32_t U_NUM_STYLEENTRY;
233typedef uint32_t U_NUM_POLYCOUNTS;
234typedef uint32_t U_NUM_EMRTEXT;
235typedef uint32_t U_NUM_STR;
236typedef uint32_t U_NUM_TRIVERTEX;
237typedef uint32_t U_NUM_GRADOBJ;
238typedef uint32_t U_NUM_RGBQUAD;
239
240
241
242/* ************************ WMF pieces used in EMF or EMF+ ****************************** */
243
262#define U_R2_BLACK 1
263#define U_R2_NOTMERGEPEN 2
264#define U_R2_MASKNOTPEN 3
265#define U_R2_NOTCOPYPEN 4
266#define U_R2_MASKPENNOT 5
267#define U_R2_NOT 6
268#define U_R2_XORPEN 7
269#define U_R2_NOTMASKPEN 8
270#define U_R2_MASKPEN 9
271#define U_R2_NOTXORPEN 10
272#define U_R2_NOP 11
273#define U_R2_MERGENOTPEN 12
274#define U_R2_COPYPEN 13
275#define U_R2_MERGEPENNOT 14
276#define U_R2_MERGEPEN 15
277#define U_R2_WHITE 16
278#define U_R2_LAST 16
287#define U_BCBM_EXPLICIT 0
288#define U_BCBM_MONOCHROME 1
289#define U_BCBM_COLOR4 4
290#define U_BCBM_COLOR8 8
291#define U_BCBM_COLOR16 16
292#define U_BCBM_COLOR24 24
293#define U_BCBM_COLOR32 32
302#define U_BI_UNKNOWN -1
303#define U_BI_RGB 0
304#define U_BI_RLE8 1
305#define U_BI_RLE4 2
306#define U_BI_BITFIELDS 3
307#define U_BI_JPEG 4
308#define U_BI_PNG 5
317#define U_LCS_GM_BUSINESS 0x00000001L
318#define U_LCS_GM_GRAPHICS 0x00000002L
319#define U_LCS_GM_IMAGES 0x00000004L
320#define U_LCS_GM_ABS_COLORIMETRIC 0x00000008L
329#define U_LCS_CALIBRATED_RGB 0x00000000L
330#define U_LCS_DEVICE_RGB 0x00000001L
331#define U_LCS_DEVICE_CMYK 0x00000002L
354#define U_SRCCOPY 0x00cc0020
355#define U_SRCPAINT 0x00ee0086
356#define U_SRCAND 0x008800c6
357#define U_SRCINVERT 0x00660046
358#define U_SRCERASE 0x00440328
359#define U_NOTSRCCOPY 0x00330008
360#define U_NOTSRCERASE 0x001100a6
361#define U_MERGECOPY 0x00c000ca
362#define U_MERGEPAINT 0x00bb0226
363#define U_PATCOPY 0x00f00021
364#define U_PATPAINT 0x00fb0a09
365#define U_PATINVERT 0x005a0049
366#define U_DSTINVERT 0x00550009
367#define U_BLACKNESS 0x00000042
368#define U_WHITENESS 0x00ff0062
369#define U_NOOP 0x00aa0029
370#define U_NOMIRRORBITMAP 0x80000000
395// Horizontal text flags
396#define U_TA_DEFAULT 0x00
397#define U_TA_NOUPDATECP 0x00
398#define U_TA_UPDATECP 0x01
399#define U_TA_LEFT 0x00
400#define U_TA_RIGHT 0x02
401#define U_TA_CENTER 0x06
402#define U_TA_TOP 0x00
403#define U_TA_BOTTOM 0x08
404#define U_TA_BASEBIT 0x10
405#define U_TA_BASELINE 0x18
406#define U_TA_RTLREADING 0x100
407#define U_TA_MASK U_TA_BASELINE+U_TA_CENTER+U_TA_UPDATECP+U_TA_RTLREADING
408// Vertical text flags
409#define U_VTA_BASELINE U_TA_BASELINE
410#define U_VTA_LEFT U_TA_BOTTOM
411#define U_VTA_RIGHT U_TA_TOP
412#define U_VTA_CENTER U_TA_CENTER
413#define U_VTA_BOTTOM U_TA_RIGHT
414#define U_VTA_TOP U_TA_LEFT
422typedef struct {
423 uint32_t biSize;
424 int32_t biWidth;
425 int32_t biHeight;
430 uint16_t biPlanes;
431 uint16_t biBitCount;
432 uint32_t biCompression;
433 uint32_t biSizeImage;
437 uint32_t biClrImportant;
440#define U_SIZE_BITMAPINFOHEADER (sizeof(U_BITMAPINFOHEADER))
441
447typedef struct {
448 int32_t ciexyzX;
449 int32_t ciexyzY;
450 int32_t ciexyzZ;
451} U_CIEXYZ,
453
467
474typedef struct {
475 uint8_t Red;
476 uint8_t Green;
477 uint8_t Blue;
478 uint8_t Reserved;
479} U_COLORREF,
481
487typedef struct {
488 unsigned ignoreHi :8;
489 unsigned intPart :8;
490 unsigned fracPart :8;
491 unsigned ignoreLo :8;
494
506
512typedef struct {
513 uint32_t lcsSignature;
514 uint32_t lcsVersion;
515 uint32_t lcsSize;
516 int32_t lcsCSType;
517 int32_t lcsIntent;
520 char lcsFilename[U_MAX_PATH];
523
529typedef struct {
530 uint32_t lcsSignature;
531 uint32_t lcsVersion;
532 uint32_t lcsSize;
533 int32_t lcsCSType;
534 int32_t lcsIntent;
537 uint16_t lcsFilename[U_MAX_PATH];
540
546typedef struct {
547 int32_t x;
548 int32_t y;
549} U_PAIR,
555
556
563typedef struct {
564 int16_t x;
565 int16_t y;
566} U_POINT16,
568
576typedef struct {
577 int32_t left;
578 int32_t top;
579 int32_t right;
580 int32_t bottom;
581} U_RECT,
585
592typedef struct {
593 uint8_t Blue;
594 uint8_t Green;
595 uint8_t Red;
596 uint8_t Reserved;
597} U_RGBQUAD,
599
600#define U_RCL_DEF (U_RECTL){0,0,-1,-1}
601
608typedef struct {
609 int32_t cx;
610 int32_t cy;
611} U_SIZE,
615
616
617
618/* ************************ EMF or common to EMF and EMF+ ****************************** */
619
620// ***********************************************************************************
621// Value enumerations and other predefined constants, alphabetical order by group
622
623
628#define U_LF_FACESIZE 32
629#define U_LF_FULLFACESIZE 64
638#define U_EMR_HEADER 1
639#define U_EMR_POLYBEZIER 2
640#define U_EMR_POLYGON 3
641#define U_EMR_POLYLINE 4
642#define U_EMR_POLYBEZIERTO 5
643#define U_EMR_POLYLINETO 6
644#define U_EMR_POLYPOLYLINE 7
645#define U_EMR_POLYPOLYGON 8
646#define U_EMR_SETWINDOWEXTEX 9
647#define U_EMR_SETWINDOWORGEX 10
648#define U_EMR_SETVIEWPORTEXTEX 11
649#define U_EMR_SETVIEWPORTORGEX 12
650#define U_EMR_SETBRUSHORGEX 13
651#define U_EMR_EOF 14
652#define U_EMR_SETPIXELV 15
653#define U_EMR_SETMAPPERFLAGS 16
654#define U_EMR_SETMAPMODE 17
655#define U_EMR_SETBKMODE 18
656#define U_EMR_SETPOLYFILLMODE 19
657#define U_EMR_SETROP2 20
658#define U_EMR_SETSTRETCHBLTMODE 21
659#define U_EMR_SETTEXTALIGN 22
660#define U_EMR_SETCOLORADJUSTMENT 23
661#define U_EMR_SETTEXTCOLOR 24
662#define U_EMR_SETBKCOLOR 25
663#define U_EMR_OFFSETCLIPRGN 26
664#define U_EMR_MOVETOEX 27
665#define U_EMR_SETMETARGN 28
666#define U_EMR_EXCLUDECLIPRECT 29
667#define U_EMR_INTERSECTCLIPRECT 30
668#define U_EMR_SCALEVIEWPORTEXTEX 31
669#define U_EMR_SCALEWINDOWEXTEX 32
670#define U_EMR_SAVEDC 33
671#define U_EMR_RESTOREDC 34
672#define U_EMR_SETWORLDTRANSFORM 35
673#define U_EMR_MODIFYWORLDTRANSFORM 36
674#define U_EMR_SELECTOBJECT 37
675#define U_EMR_CREATEPEN 38
676#define U_EMR_CREATEBRUSHINDIRECT 39
677#define U_EMR_DELETEOBJECT 40
678#define U_EMR_ANGLEARC 41
679#define U_EMR_ELLIPSE 42
680#define U_EMR_RECTANGLE 43
681#define U_EMR_ROUNDRECT 44
682#define U_EMR_ARC 45
683#define U_EMR_CHORD 46
684#define U_EMR_PIE 47
685#define U_EMR_SELECTPALETTE 48
686#define U_EMR_CREATEPALETTE 49
687#define U_EMR_SETPALETTEENTRIES 50
688#define U_EMR_RESIZEPALETTE 51
689#define U_EMR_REALIZEPALETTE 52
690#define U_EMR_EXTFLOODFILL 53
691#define U_EMR_LINETO 54
692#define U_EMR_ARCTO 55
693#define U_EMR_POLYDRAW 56
694#define U_EMR_SETARCDIRECTION 57
695#define U_EMR_SETMITERLIMIT 58
696#define U_EMR_BEGINPATH 59
697#define U_EMR_ENDPATH 60
698#define U_EMR_CLOSEFIGURE 61
699#define U_EMR_FILLPATH 62
700#define U_EMR_STROKEANDFILLPATH 63
701#define U_EMR_STROKEPATH 64
702#define U_EMR_FLATTENPATH 65
703#define U_EMR_WIDENPATH 66
704#define U_EMR_SELECTCLIPPATH 67
705#define U_EMR_ABORTPATH 68
706#define U_EMR_UNDEF69 69
707#define U_EMR_COMMENT 70
708#define U_EMR_FILLRGN 71
709#define U_EMR_FRAMERGN 72
710#define U_EMR_INVERTRGN 73
711#define U_EMR_PAINTRGN 74
712#define U_EMR_EXTSELECTCLIPRGN 75
713#define U_EMR_BITBLT 76
714#define U_EMR_STRETCHBLT 77
715#define U_EMR_MASKBLT 78
716#define U_EMR_PLGBLT 79
717#define U_EMR_SETDIBITSTODEVICE 80
718#define U_EMR_STRETCHDIBITS 81
719#define U_EMR_EXTCREATEFONTINDIRECTW 82
720#define U_EMR_EXTTEXTOUTA 83
721#define U_EMR_EXTTEXTOUTW 84
722#define U_EMR_POLYBEZIER16 85
723#define U_EMR_POLYGON16 86
724#define U_EMR_POLYLINE16 87
725#define U_EMR_POLYBEZIERTO16 88
726#define U_EMR_POLYLINETO16 89
727#define U_EMR_POLYPOLYLINE16 90
728#define U_EMR_POLYPOLYGON16 91
729#define U_EMR_POLYDRAW16 92
730#define U_EMR_CREATEMONOBRUSH 93
731#define U_EMR_CREATEDIBPATTERNBRUSHPT 94
732#define U_EMR_EXTCREATEPEN 95
733#define U_EMR_POLYTEXTOUTA 96
734#define U_EMR_POLYTEXTOUTW 97
735#define U_EMR_SETICMMODE 98
736#define U_EMR_CREATECOLORSPACE 99
737#define U_EMR_SETCOLORSPACE 100
738#define U_EMR_DELETECOLORSPACE 101
739#define U_EMR_GLSRECORD 102
740#define U_EMR_GLSBOUNDEDRECORD 103
741#define U_EMR_PIXELFORMAT 104
742#define U_EMR_DRAWESCAPE 105
743#define U_EMR_EXTESCAPE 106
744#define U_EMR_UNDEF107 107
745#define U_EMR_SMALLTEXTOUT 108
746#define U_EMR_FORCEUFIMAPPING 109
747#define U_EMR_NAMEDESCAPE 110
748#define U_EMR_COLORCORRECTPALETTE 111
749#define U_EMR_SETICMPROFILEA 112
750#define U_EMR_SETICMPROFILEW 113
751#define U_EMR_ALPHABLEND 114
752#define U_EMR_SETLAYOUT 115
753#define U_EMR_TRANSPARENTBLT 116
754#define U_EMR_UNDEF117 117
755#define U_EMR_GRADIENTFILL 118
756#define U_EMR_SETLINKEDUFIS 119
757#define U_EMR_SETTEXTJUSTIFICATION 120
758#define U_EMR_COLORMATCHTOTARGETW 121
759#define U_EMR_CREATECOLORSPACEW 122
760
761#define U_EMR_MIN 1
762#define U_EMR_MAX 122
763
764#define U_EMR_INVALID 0xFFFFFFFF
772#define U_DRAW_NOTEMPTY 0x001
773#define U_DRAW_VISIBLE 0x002
774#define U_DRAW_CLOSED 0x004
775#define U_DRAW_ONLYTO 0x008
776#define U_DRAW_FORCE 0x010
777#define U_DRAW_ALTERS 0x020
778#define U_DRAW_PATH 0x040
779#define U_DRAW_TEXT 0x080
780#define U_DRAW_OBJECT 0x100
781#define U_DRAW_NOFILL 0x200
782
790#define U_AD_COUNTERCLOCKWISE 1
791#define U_AD_CLOCKWISE 2
800#define U_PAN_STRAIGHT_ARMS_HORZ 2
801#define U_PAN_STRAIGHT_ARMS_WEDGE 3
802#define U_PAN_STRAIGHT_ARMS_VERT 4
803#define U_PAN_STRAIGHT_ARMS_SINGLE_SERIF 5
804#define U_PAN_STRAIGHT_ARMS_DOUBLE_SERIF 6
805#define U_PAN_BENT_ARMS_HORZ 7
806#define U_PAN_BENT_ARMS_WEDGE 8
807#define U_PAN_BENT_ARMS_VERT 9
808#define U_PAN_BENT_ARMS_SINGLE_SERIF 10
809#define U_PAN_BENT_ARMS_DOUBLE_SERIF 11
818#define U_TRANSPARENT 1
819#define U_OPAQUE 2
828#define U_CA_NEGATIVE 0x0001
829#define U_CA_LOG_FILTER 0x0002
838#define U_COLORMATCHTOTARGET_NOTEMBEDDED 0
839#define U_COLORMATCHTOTARGET_EMBEDDED 1
848#define U_CS_ENABLE 1
849#define U_CS_DISABLE 2
850#define U_CS_DELETE_TRANSFORM 3
858#define U_PAN_ANY 0
859#define U_PAN_NO_FIT 1
868#define U_PAN_CONTRAST_NONE 2
869#define U_PAN_CONTRAST_VERY_LOW 3
870#define U_PAN_CONTRAST_LOW 4
871#define U_PAN_CONTRAST_MEDIUM_LOW 5
872#define U_PAN_CONTRAST_MEDIUM 6
873#define U_PAN_CONTRAST_MEDIUM_HIGH 7
874#define U_PAN_CONTRAST_HIGH 8
875#define U_PAN_CONTRAST_VERY_HIGH 9
884#define U_DIB_RGB_COLORS 0
885#define U_DIB_PAL_COLORS 1
886#define U_DIB_PAL_INDICES 2
895#define U_EMR_COMMENT_WINDOWS_METAFILE 0x80000001
896#define U_EMR_COMMENT_BEGINGROUP 0x00000002
897#define U_EMR_COMMENT_ENDGROUP 0x00000003
898#define U_EMR_COMMENT_MULTIFORMATS 0x40000004
899#define U_EMR_COMMENT_UNICODE_STRING 0x00000040
900#define U_EMR_COMMENT_UNICODE_END 0x00000080
909#define U_ETO_NONE 0x00000000
910#define U_ETO_GRAYED 0x00000001
911#define U_ETO_OPAQUE 0x00000002
912#define U_ETO_CLIPPED 0x00000004
913#define U_ETO_GLYPH_INDEX 0x00000010
914#define U_ETO_RTLREADING 0x00000080
915#define U_ETO_NO_RECT 0x00000100
916#define U_ETO_SMALL_CHARS 0x00000200
917#define U_ETO_NUMERICSLOCAL 0x00000400
918#define U_ETO_NUMERICSLATIN 0x00000800
919#define U_ETO_IGNORELANGUAGE 0x00001000
920#define U_ETO_PDY 0x00002000
921#define U_ETO_REVERSE_INDEX_MAP 0x00010000
930#define U_PAN_FAMILY_TEXT_DISPLAY 2
931#define U_PAN_FAMILY_SCRIPT 3
932#define U_PAN_FAMILY_DECORATIVE 4
933#define U_PAN_FAMILY_PICTORIAL 5
942#define U_FLOODFILLBORDER 0x00000000
943#define U_FLOODFILLSURFACE 0x00000001
952#define U_ENHMETA_SIGNATURE 0x464D4520
953#define U_EPS_SIGNATURE 0x46535045
962#define U_GRADIENT_FILL_RECT_H 0x00000000
963#define U_GRADIENT_FILL_RECT_V 0x00000001
964#define U_GRADIENT_FILL_TRIANGLE 0x00000002
973#define U_GM_COMPATIBLE 1
974#define U_GM_ADVANCED 2
975#define U_GM_LAST 2
984#define U_HS_HORIZONTAL 0
985#define U_HS_VERTICAL 1
986#define U_HS_FDIAGONAL 2
987#define U_HS_BDIAGONAL 3
988#define U_HS_CROSS 4
989#define U_HS_DIAGCROSS 5
990#define U_HS_SOLIDCLR 6
991#define U_HS_DITHEREDCLR 7
992#define U_HS_SOLIDTEXTCLR 8
993#define U_HS_DITHEREDTEXTCLR 9
994#define U_HS_SOLIDBKCLR 10
995#define U_HS_DITHEREDBKCLR 11
1004#define U_ICM_OFF 1
1005#define U_ICM_ON 2
1006#define U_ICM_QUERY 3
1015#define U_ILLUMINANT_DEVICE_DEFAULT 0
1016#define U_ILLUMINANT_A 1
1017#define U_ILLUMINANT_B 2
1018#define U_ILLUMINANT_C 3
1019#define U_ILLUMINANT_D50 4
1020#define U_ILLUMINANT_D55 5
1021#define U_ILLUMINANT_D65 6
1022#define U_ILLUMINANT_D75 7
1023#define U_ILLUMINANT_F2 8
1024#define U_ILLUMINANT_MAX_INDEX ILLUMINANT_F2
1025#define U_ILLUMINANT_TUNGSTEN ILLUMINANT_A
1026#define U_ILLUMINANT_DAYLIGHT ILLUMINANT_C
1027#define U_ILLUMINANT_FLUORESCENT ILLUMINANT_F2
1028#define U_ILLUMINANT_NTSC ILLUMINANT_C
1037#define U_PAN_LETT_NORMAL_COMPACT 2
1038#define U_PAN_LETT_NORMAL_WEIGHTED 3
1039#define U_PAN_LETT_NORMAL_BOXED 4
1040#define U_PAN_LETT_NORMAL_FLATTENED 5
1041#define U_PAN_LETT_NORMAL_ROUNDED 6
1042#define U_PAN_LETT_NORMAL_OFF_CENTER 7
1043#define U_PAN_LETT_NORMAL_SQUARE 8
1044#define U_PAN_LETT_OBLIQUE_COMPACT 9
1045#define U_PAN_LETT_OBLIQUE_WEIGHTED 10
1046#define U_PAN_LETT_OBLIQUE_BOXED 11
1047#define U_PAN_LETT_OBLIQUE_FLATTENED 12
1048#define U_PAN_LETT_OBLIQUE_ROUNDED 13
1049#define U_PAN_LETT_OBLIQUE_OFF_CENTER 14
1050#define U_PAN_LETT_OBLIQUE_SQUARE 15
1059#define U_MM_TEXT 1
1060#define U_MM_LOMETRIC 2
1061#define U_MM_HIMETRIC 3
1062#define U_MM_LOENGLISH 4
1063#define U_MM_HIENGLISH 5
1064#define U_MM_TWIPS 6
1065#define U_MM_ISOTROPIC 7
1066#define U_MM_ANISOTROPIC 8
1067#define U_MM_MIN U_MM_TEXT
1068#define U_MM_MAX U_MM_ANISOTROPIC
1069#define U_MM_MAX_FIXEDSCALE U_MM_TWIPS
1078#define U_ENHMETA_VERSION 0x00010000
1087#define U_PAN_MIDLINE_STANDARD_TRIMMED 2
1088#define U_PAN_MIDLINE_STANDARD_POINTED 3
1089#define U_PAN_MIDLINE_STANDARD_SERIFED 4
1090#define U_PAN_MIDLINE_HIGH_TRIMMED 5
1091#define U_PAN_MIDLINE_HIGH_POINTED 6
1092#define U_PAN_MIDLINE_HIGH_SERIFED 7
1093#define U_PAN_MIDLINE_CONSTANT_TRIMMED 8
1094#define U_PAN_MIDLINE_CONSTANT_POINTED 9
1095#define U_PAN_MIDLINE_CONSTANT_SERIFED 10
1096#define U_PAN_MIDLINE_LOW_TRIMMED 11
1097#define U_PAN_MIDLINE_LOW_POINTED 12
1098#define U_PAN_MIDLINE_LOW_SERIFED 13
1107#define U_MWT_IDENTITY 1
1108#define U_MWT_LEFTMULTIPLY 2
1109#define U_MWT_RIGHTMULTIPLY 3
1110#define U_MWT_MIN U_MWT_IDENTITY
1111#define U_MWT_MAX U_MWT_RIGHTMULTIPLY
1120#define U_PS_SOLID 0x00000000
1121#define U_PS_DASH 0x00000001
1122#define U_PS_DOT 0x00000002
1123#define U_PS_DASHDOT 0x00000003
1124#define U_PS_DASHDOTDOT 0x00000004
1125#define U_PS_NULL 0x00000005
1126#define U_PS_INSIDEFRAME 0x00000006
1127#define U_PS_USERSTYLE 0x00000007
1128#define U_PS_ALTERNATE 0x00000008
1129#define U_PS_STYLE_MASK 0x0000000f
1130
1131#define U_PS_ENDCAP_ROUND 0x00000000
1132#define U_PS_ENDCAP_SQUARE 0x00000100
1133#define U_PS_ENDCAP_FLAT 0x00000200
1134#define U_PS_ENDCAP_MASK 0x00000f00
1135
1136#define U_PS_JOIN_ROUND 0x00000000
1137#define U_PS_JOIN_BEVEL 0x00001000
1138#define U_PS_JOIN_MITER 0x00002000
1139#define U_PS_JOIN_MASK 0x0000f000
1140
1141#define U_PS_COSMETIC 0x00000000
1142#define U_PS_GEOMETRIC 0x00010000
1143#define U_PS_TYPE_MASK 0x000f0000
1151#define U_PT_CLOSEFIGURE 0x0001
1152#define U_PT_LINETO 0x0002
1153#define U_PT_BEZIERTO 0x0004
1154#define U_PT_MOVETO 0x0006
1163#define U_ALTERNATE 1
1164#define U_WINDING 2
1165#define U_POLYFILL_LAST 2
1174#define U_PAN_PROP_OLD_STYLE 2
1175#define U_PAN_PROP_MODERN 3
1176#define U_PAN_PROP_EVEN_WIDTH 4
1177#define U_PAN_PROP_EXPANDED 5
1178#define U_PAN_PROP_CONDENSED 6
1179#define U_PAN_PROP_VERY_EXPANDED 7
1180#define U_PAN_PROP_VERY_CONDENSED 8
1181#define U_PAN_PROP_MONOSPACED 9
1190#define U_RGN_NONE 0
1191#define U_RGN_AND 1
1192#define U_RGN_OR 2
1193#define U_RGN_XOR 3
1194#define U_RGN_DIFF 4
1195#define U_RGN_COPY 5
1196#define U_RGN_MIN U_RGN_AND
1197#define U_RGN_MAX U_RGN_COPY
1206#define U_PAN_SERIF_COVE 2
1207#define U_PAN_SERIF_OBTUSE_COVE 3
1208#define U_PAN_SERIF_SQUARE_COVE 4
1209#define U_PAN_SERIF_OBTUSE_SQUARE_COVE 5
1210#define U_PAN_SERIF_SQUARE 6
1211#define U_PAN_SERIF_THIN 7
1212#define U_PAN_SERIF_BONE 8
1213#define U_PAN_SERIF_EXAGGERATED 9
1214#define U_PAN_SERIF_TRIANGLE 10
1215#define U_PAN_SERIF_NORMAL_SANS 11
1216#define U_PAN_SERIF_OBTUSE_SANS 12
1217#define U_PAN_SERIF_PERP_SANS 13
1218#define U_PAN_SERIF_FLARED 14
1219#define U_PAN_SERIF_ROUNDED 15
1228#define U_STOCK_OBJECT 0x80000000
1229#define U_WHITE_BRUSH 0x80000000
1230#define U_LTGRAY_BRUSH 0x80000001
1231#define U_GRAY_BRUSH 0x80000002
1232#define U_DKGRAY_BRUSH 0x80000003
1233#define U_BLACK_BRUSH 0x80000004
1234#define U_NULL_BRUSH 0x80000005
1235#define U_HOLLOW_BRUSH 0x80000005
1236#define U_WHITE_PEN 0x80000006
1237#define U_BLACK_PEN 0x80000007
1238#define U_NULL_PEN 0x80000008
1239#define U_OEM_FIXED_FONT 0x8000000A
1240#define U_ANSI_FIXED_FONT 0x8000000B
1241#define U_ANSI_VAR_FONT 0x8000000C
1242#define U_SYSTEM_FONT 0x8000000D
1243#define U_DEVICE_DEFAULT_FONT 0x8000000E
1244#define U_DEFAULT_PALETTE 0x8000000F
1245#define U_SYSTEM_FIXED_FONT 0x80000010
1246#define U_DEFAULT_GUI_FONT 0x80000011
1247#define U_STOCK_LAST 0x80000011
1256#define U_BLACKONWHITE 1
1257#define U_WHITEONBLACK 2
1258#define U_COLORONCOLOR 3
1259#define U_HALFTONE 4
1260#define U_MAXSTRETCHBLTMODE 4
1261#define U_STRETCH_ANDSCANS 1
1262#define U_STRETCH_ORSCANS 2
1263#define U_STRETCH_DELETESCANS 3
1264#define U_STRETCH_HALFTONE 4
1273#define U_PAN_STROKE_GRADUAL_DIAG 2
1274#define U_PAN_STROKE_GRADUAL_TRAN 3
1275#define U_PAN_STROKE_GRADUAL_VERT 4
1276#define U_PAN_STROKE_GRADUAL_HORZ 5
1277#define U_PAN_STROKE_RAPID_VERT 6
1278#define U_PAN_STROKE_RAPID_HORZ 7
1279#define U_PAN_STROKE_INSTANT_VERT 8
1287#define U_PAN_WEIGHT_VERY_LIGHT 2
1288#define U_PAN_WEIGHT_LIGHT 3
1289#define U_PAN_WEIGHT_THIN 4
1290#define U_PAN_WEIGHT_BOOK 5
1291#define U_PAN_WEIGHT_MEDIUM 6
1292#define U_PAN_WEIGHT_DEMI 7
1293#define U_PAN_WEIGHT_BOLD 8
1294#define U_PAN_WEIGHT_HEAVY 9
1295#define U_PAN_WEIGHT_BLACK 10
1296#define U_PAN_WEIGHT_NORD 11
1304#define U_PAN_XHEIGHT_CONSTANT_SMALL 2
1305#define U_PAN_XHEIGHT_CONSTANT_STANDARD 3
1306#define U_PAN_XHEIGHT_CONSTANT_LARGE 4
1307#define U_PAN_XHEIGHT_DUCKING_SMALL 5
1308#define U_PAN_XHEIGHT_DUCKING_STANDARD 6
1309#define U_PAN_XHEIGHT_DUCKING_LARGE 7
1317#define U_FW_DONTCARE 0
1318#define U_FW_THIN 100
1319#define U_FW_EXTRALIGHT 200
1320#define U_FW_ULTRALIGHT 200
1321#define U_FW_LIGHT 300
1322#define U_FW_NORMAL 400
1323#define U_FW_REGULAR 400
1324#define U_FW_MEDIUM 500
1325#define U_FW_SEMIBOLD 600
1326#define U_FW_DEMIBOLD 600
1327#define U_FW_BOLD 700
1328#define U_FW_EXTRABOLD 800
1329#define U_FW_ULTRABOLD 800
1330#define U_FW_HEAVY 900
1331#define U_FW_BLACK 900
1340#define U_FW_NOITALIC 0
1341#define U_FW_ITALIC 1
1350#define U_FW_NOUNDERLINE 0
1351#define U_FW_UNDERLINE 1
1359#define U_FW_NOSTRIKEOUT 0
1360#define U_FW_STRIKEOUT 1
1368#define U_ANSI_CHARSET (uint8_t)0
1369#define U_DEFAULT_CHARSET (uint8_t)1
1370#define U_SYMBOL_CHARSET (uint8_t)2
1371#define U_SHIFTJIS_CHARSET (uint8_t)128
1372#define U_HANGEUL_CHARSET (uint8_t)129
1373#define U_HANGUL_CHARSET U_HANGEUL_CHARSET
1374#define U_GB2312_CHARSET (uint8_t)134
1375#define U_CHINESEBIG5_CHARSET (uint8_t)136
1376#define U_GREEK_CHARSET (uint8_t)161
1377#define U_TURKISH_CHARSET (uint8_t)162
1378#define U_HEBREW_CHARSET (uint8_t)177
1379#define U_ARABIC_CHARSET (uint8_t)178
1380#define U_BALTIC_CHARSET (uint8_t)186
1381#define U_RUSSIAN_CHARSET (uint8_t)204
1382#define U_EE_CHARSET (uint8_t)238
1383#define U_EASTEUROPE_CHARSET U_EE_CHARSET
1384#define U_THAI_CHARSET (uint8_t)222
1385#define U_JOHAB_CHARSET (uint8_t)130
1386#define U_MAC_CHARSET (uint8_t)77
1387#define U_OEM_CHARSET (uint8_t)255
1388#define U_VISCII_CHARSET (uint8_t)240
1389#define U_TCVN_CHARSET (uint8_t)241
1390#define U_KOI8_CHARSET (uint8_t)242
1391#define U_ISO3_CHARSET (uint8_t)243
1392#define U_ISO4_CHARSET (uint8_t)244
1393#define U_ISO10_CHARSET (uint8_t)245
1394#define U_CELTIC_CHARSET (uint8_t)246
1402#define U_OUT_DEFAULT_PRECIS 0
1403#define U_OUT_STRING_PRECIS 1
1404#define U_OUT_CHARACTER_PRECIS 2
1405#define U_OUT_STROKE_PRECIS 3
1406#define U_OUT_TT_PRECIS 4
1407#define U_OUT_DEVICE_PRECIS 5
1408#define U_OUT_RASTER_PRECIS 6
1409#define U_OUT_TT_ONLY_PRECIS 7
1410#define U_OUT_OUTLINE_PRECIS 8
1418#define U_CLIP_DEFAULT_PRECIS 0x00
1419#define U_CLIP_CHARACTER_PRECIS 0x01
1420#define U_CLIP_STROKE_PRECIS 0x02
1421#define U_CLIP_MASK 0x0F
1422#define U_CLIP_LH_ANGLES 0x10
1423#define U_CLIP_TT_ALWAYS 0x20
1424#define U_CLIP_EMBEDDED 0x80
1432#define U_DEFAULT_QUALITY 0
1433#define U_DRAFT_QUALITY 1
1434#define U_PROOF_QUALITY 2
1435#define U_NONANTIALIASED_QUALITY 3
1436#define U_ANTIALIASED_QUALITY 4
1444#define U_DEFAULT_PITCH 0x00
1445#define U_FIXED_PITCH 0x01
1446#define U_VARIABLE_PITCH 0x02
1447#define U_MONO_FONT 0x08
1448#define U_FF_DONTCARE 0x00
1449#define U_FF_ROMAN 0x10
1450#define U_FF_SWISS 0x20
1451#define U_FF_MODERN 0x30
1452#define U_FF_SCRIPT 0x40
1453#define U_FF_DECORATIVE 0x50
1461#define U_BS_SOLID 0
1462#define U_BS_NULL 1
1463#define U_BS_HOLLOW 1
1464#define U_BS_HATCHED 2
1465#define U_BS_PATTERN 3
1466#define U_BS_INDEXED 4
1467#define U_BS_DIBPATTERN 5
1468#define U_BS_DIBPATTERNPT 6
1469#define U_BS_PATTERN8X8 7
1470#define U_BS_DIBPATTERN8X8 8
1471#define U_BS_MONOPATTERN 9
1480#define U_PAN_FAMILYTYPE_INDEX 0
1481#define U_PAN_SERIFSTYLE_INDEX 1
1482#define U_PAN_WEIGHT_INDEX 2
1483#define U_PAN_PROPORTION_INDEX 3
1484#define U_PAN_CONTRAST_INDEX 4
1485#define U_PAN_STROKEVARIATION_INDEX 5
1486#define U_PAN_ARMSTYLE_INDEX 6
1487#define U_PAN_LETTERFORM_INDEX 7
1488#define U_PAN_MIDLINE_INDEX 8
1489#define U_PAN_XHEIGHT_INDEX 9
1490#define U_PAN_COUNT 10
1500#define U_PFD_MAIN_PLANE 0
1501#define U_PFD_OVERLAY_PLANE 1
1502#define U_PFD_UNDERLAY_PLANE (-1)
1511#define U_PFD_TYPE_RGBA 0
1512#define U_PFD_TYPE_COLORINDEX 1
1520#define U_PFD_DOUBLEBUFFER 0x00000001
1521#define U_PFD_STEREO 0x00000002
1522#define U_PFD_DRAW_TO_WINDOW 0x00000004
1523#define U_PFD_DRAW_TO_BITMAP 0x00000008
1524#define U_PFD_SUPPORT_GDI 0x00000010
1525#define U_PFD_SUPPORT_OPENGL 0x00000020
1526#define U_PFD_GENERIC_FORMAT 0x00000040
1527#define U_PFD_NEED_PALETTE 0x00000080
1528#define U_PFD_NEED_SYSTEM_PALETTE 0x00000100
1529#define U_PFD_SWAP_EXCHANGE 0x00000200
1530#define U_PFD_SWAP_COPY 0x00000400
1531#define U_PFD_SWAP_LAYER_BUFFERS 0x00000800
1532#define U_PFD_GENERIC_ACCELERATED 0x00001000
1540#define U_EMR_COMMENT_PUBLIC 0x43494447
1541#define U_EMR_COMMENT_SPOOL 0x00000000
1542#define U_EMR_COMMENT_EMFPLUSRECORD 0x2B464D45
1550#define U_LAYOUT_LTR 0x00000000
1551#define U_LAYOUT_RTL 0x00000001
1552#define U_LAYOUT_BITMAPORIENTATIONPRESERVED 0x00000008
1560#define U_AC_SRC_GLOBAL 0
1561#define U_AC_SRC_CONST 0
1562#define U_AC_SRC_ALPHA 1
1566// ***************************************************************************
1567// Macros
1568
1572// Note, many of these were originally defined using C99 (type){val,val,val} format, but that turned out to
1573// have incompatibilities with C++, so use functions as the basis to avoid this.
1574
1575// Set/Get for U_RGBQUAD Colors, which are stored in byte order: {B,G,R,A}.
1576// These are used in EMF structures and the byte order must be the same in memory or on disk.
1577#define U_BGR(r,g,b) rgbquad_set(r, g, b, 0)
1578#define U_BGRA(r,g,b,a) rgbquad_set(r, g, b, a)
1579#define U_WHITE U_BGR(255,255,255)
1580#define U_BLACK U_BGR(0,0,0)
1581#define U_BGRAGetR(rgb) (rgb.Red )
1582#define U_BGRAGetG(rgb) (rgb.Green )
1583#define U_BGRAGetB(rgb) (rgb.Blue )
1584#define U_BGRAGetA(rgb) (rgb.Reserved)
1585
1586
1587// Set/Get for U_COLORREF Color, which are stored in byte order:: {R,G,B,A}.
1588// These are used in EMF structures and the byte order must be the same in memory or on disk.
1589// These MAY be used in PNG and other libraries if these enforce byte order in memory, otherwise
1590// U_swap4 may need to also be employed.
1591//
1592
1593#define colorref_set colorref3_set
1594#define U_RGB(r,g,b) colorref3_set(r, g, b)
1595#define U_RGBA(r,g,b,a) colorref4_set(r, g, b, a)
1596#define U_RGBAGetR(rgb) (rgb.Red )
1597#define U_RGBAGetG(rgb) (rgb.Green )
1598#define U_RGBAGetB(rgb) (rgb.Blue )
1599#define U_RGBAGetA(rgb) (rgb.Reserved)
1600
1601// color type conversions
1602#define U_RGB2BGR(rgb) U_BGR(U_RGBAGetR(rgb),U_RGBAGetG(rgb),U_RGBAGetB(rgb))
1603#define U_BGR2RGB(rgb) U_RGB(U_BGRAGetR(rgb),U_BGRAGetG(rgb),U_BGRAGetB(rgb))
1604#define U_RGBA2BGRA(rgb) U_BGRA(U_RGBAGetR(rgb),U_RGBAGetG(rgb),U_RGBAGetB(rgb),U_RGBAGetA(rgb)}
1605#define U_BGRA2RGBA(rgb) U_RGBA(U_BGRAGetR(rgb),U_BGRAGetG(rgb),U_BGRAGetB(rgb),U_BGRAGetA(rgb)}
1606
1607// Color CMYK Get/Set Macros
1608#define U_CMYK(c,m,y,k)\
1609 ((COLOREF)((((uint8_t)(k)|((uint16_t)((uint8_t)(y))<<8))|(((uint32_t)(uint8_t)(m))<<16))|(((uint32_t)(uint8_t)(c))<<24))) \
1610
1611#define U_GetKValue(cmyk) ((uint8_t) (cmyk) )
1612#define U_GetYValue(cmyk) ((uint8_t) ((cymk) >> 8))
1613#define U_GetMValue(cmyk) ((uint8_t) ((cymk) >> 16))
1614#define U_GetCValue(cmyk) ((uint8_t) ((cymk) >> 24))
1615
1616// Other macros
1617#define U_Gamma(A) (A < U_RGB_GAMMA_MIN ? U_RGB_GAMMA_MIN : (A > U_RGB_GAMMA_MAX ? U_RGB_GAMMA_MAX: A)) \
1618
1619#define U_PM(A,B) ((A)<-(B)?-(B):((A)>(B)?(B):(A)))
1620#define U_MNMX(A,B,C) ((A)<(B)?(B):((A)>(C)?(C):(A)))
1621#define U_MIN(A,B) ((A)>(B)?(B):(A))
1622#define U_MAX(A,B) ((A)>(B)?(A):(B))
1623
1624// basic EMR macros.
1625#define U_EMRTYPE(A) (((PU_EMR)A)->iType)
1626#define U_EMRSIZE(A) (((PU_EMR)A)->nSize)
1627
1628// Utility macros
1629#define UP4(A) (4 * ((A + 3 ) / 4))
1630
1637typedef struct {
1638 float x;
1639 float y;
1640} U_PAIRF,
1642
1643
1644/* ************************************************************
1645 EMF structures OTHER than those corresponding to complete U_EMR_* records
1646 ************************************************************ */
1647
1653typedef struct {
1654 signed IntValue :28;
1655 unsigned FracValue :4;
1656} U_BITFIX28_4,
1658
1666typedef struct {
1667 uint16_t caSize;
1668 uint16_t caFlags;
1670 uint16_t caRedGamma;
1671 uint16_t caGreenGamma;
1672 uint16_t caBlueGamma;
1675 int16_t caContrast;
1681
1687typedef struct {
1688 uint32_t Signature;
1690 U_FNTAXES Values[1];
1693#define U_SIZE_DESIGNVECTOR (sizeof(uint32_t) + sizeof(U_NUM_FNTAXES))
1694
1707
1736
1747
1753typedef struct {
1754 uint32_t sizeData;
1755 uint32_t version;
1756 U_POINT28_4 Points[3];
1758} U_EPS_DATA,
1760
1766typedef struct {
1767 int32_t x;
1768 int32_t y;
1769 uint16_t Red;
1770 uint16_t Green;
1771 uint16_t Blue;
1772 uint16_t Alpha;
1773} U_TRIVERTEX,
1775
1781typedef struct {
1782 uint32_t UpperLeft;
1783 uint32_t LowerRight;
1784} U_GRADIENT4,
1786
1797typedef struct {
1798 uint32_t Vertex1;
1799 uint32_t Vertex2;
1800 uint32_t Vertex3;
1801} U_GRADIENT3,
1803
1804//Microsoft name: Header object, EMF manual 2.2.9 defined below with record structs
1805//Microsoft name: HeaderExtension1 object, EMF manual 2.2.10 defined below with record structs
1806//Microsoft name: HeaderExtension1 object, EMF manual 2.2.11 defined below with record structs
1807
1813typedef struct {
1814 uint32_t lbStyle;
1816 uint32_t lbHatch;
1817} U_LOGBRUSH,
1821
1827typedef struct {
1828 int32_t lfHeight;
1829 int32_t lfWidth;
1832 int32_t lfWeight;
1833 uint8_t lfItalic;
1834 uint8_t lfUnderline;
1835 uint8_t lfStrikeOut;
1836 uint8_t lfCharSet;
1839 uint8_t lfQuality;
1841 uint16_t lfFaceName[U_LF_FACESIZE];
1842} U_LOGFONT,
1844
1845// Microsoft name: LogFontEx Object (not implemented) EMF manual 2.2.14
1846// Microsoft name: LogFontExDv Object (not implemented) EMF manual 2.2.15
1847
1853// out of order, needed for 2.2.16
1854typedef struct {
1855 uint8_t bFamilyType;
1856 uint8_t bSerifStyle;
1857 uint8_t bWeight;
1858 uint8_t bProportion;
1859 uint8_t bContrast;
1861 uint8_t bArmStyle;
1862 uint8_t bLetterform;
1863 uint8_t bMidline;
1864 uint8_t bXHeight;
1865} U_PANOSE,
1867
1868#define U_PAN_ALL0 (U_PANOSE){0,0,0,0,0,0,0,0,0,0}
1869#define U_PAN_ALL1 (U_PANOSE){1,1,1,1,1,1,1,1,1,1}
1870
1876typedef struct {
1878 uint16_t elfFullName[U_LF_FULLFACESIZE];
1879 uint16_t elfStyle[U_LF_FACESIZE];
1880 uint32_t elfVersion;
1881 uint32_t elfStyleSize;
1882 uint32_t elfMatch;
1883 uint32_t elfReserved;
1884 uint8_t elfVendorId[U_ELF_VENDOR_SIZE];
1885 uint32_t elfCulture;
1887 uint16_t elfPadding;
1890
1896// out of order, needed for 2.2.17
1897typedef struct {
1898 uint8_t peReserved;
1899 uint8_t peRed;
1900 uint8_t peGreen;
1901 uint8_t peBlue;
1902} U_LOGPLTNTRY,
1904
1911typedef struct {
1912 uint16_t palVersion;
1913 uint16_t palNumEntries;
1914 U_LOGPLTNTRY palPalEntry[1];
1915} U_LOGPALETTE,
1917#define U_SIZE_LOGPALETTE (2*sizeof(uint16_t))
1918
1919// Microsoft name: LogPaletteEntry Object, EMF manual 2.2.18, defined above, before 2.2.17
1920
1932
1933// Microsoft name: LogPenEx Object (not implemented) EMF manual 2.2.20
1934// Microsoft name: Panose Object, EMF manual 2.2.21, defined above, before 2.2.16
1935
1941typedef struct {
1942 uint16_t nSize;
1943 uint16_t nVersion;
1944 uint32_t dwFlags;
1945 uint8_t iPixelType;
1946 uint8_t cColorBits;
1947 uint8_t cRedBits;
1948 uint8_t cRedShift;
1949 uint8_t cGreenBits;
1950 uint8_t cGreenShift;
1951 uint8_t cBlueBits;
1952 uint8_t cBlueShift;
1953 uint8_t cAlphaBits;
1954 uint8_t cAlphaShift;
1955 uint8_t cAccumBits;
1960 uint8_t cDepthBits;
1962 uint8_t cAuxBuffers;
1963 uint8_t iLayerType;
1964 uint8_t bReserved;
1965 uint32_t dwLayerMask;
1966 uint32_t dwVisibleMask;
1967 uint32_t dwDamageMask;
1970
1971// Microsoft name: Point28_4 Object. EMF manual 2.2.23, defined above, before 2.2.6
1972
1978// out of order, needed for 2.2.24
1987#define U_SIZE_RGNDATAHEADER (sizeof(U_RGNDATAHEADER))
1988
1995typedef struct {
1997 U_RECTL Buffer[1];
1998} U_RGNDATA,
2000#define U_SIZE_RGNDATA U_SIZE_RGNDATAHEADER
2001
2002// Microsoft name: RegionDataHeader Object. EMF manual 2.2.25, defined above, before 2.2.24
2003// Microsoft name: TriVertex Object. EMF manual 2.2.26, defined above, before 2.2.7
2004// Microsoft name: UniversalFontId Object. EMF manual 2.2.27 (not implemented)
2005
2020
2036#define U_SIZE_EXTLOGPEN (sizeof(U_EXTLOGPEN) - sizeof(U_STYLEENTRY)) // there may not be any style entries
2037
2045typedef struct {
2047 U_RGBQUAD bmiColors[1];
2048} U_BITMAPINFO,
2050#define U_SIZE_BITMAPINFO U_SIZE_BITMAPINFOHEADER
2051
2057typedef struct {
2058 uint8_t Operation;
2059 uint8_t Flags;
2060 uint8_t Global;
2061 uint8_t Op;
2062} U_BLEND,
2064#
2065
2071typedef struct {
2072 uint32_t iType;
2073 uint32_t nSize;
2074 uint32_t dParm[1];
2077#define U_SIZE_ENHMETARECORD (2*sizeof(uint32_t))
2078
2084typedef struct {
2085 uint32_t iType;
2086 uint32_t nSize;
2087} U_EMR,
2089
2098
2099
2100
2101
2102// ***********************************************************************************
2103// The following have U_EMR_# records. They are ordered by their record index, not by EMF manual position.
2104
2105// records which are documented but not implemented
2106#define U_SIZE_EMRNOTIMPLEMENTED 2048
2107
2108/* Index 1 */
2150#define U_SIZE_EMRHEADER sizeof(U_EMRHEADER) // modern EMF files, for _really_ old ones the _MIN size applies
2151#define U_SIZE_EMRHEADER_MIN (U_SIZE_EMRHEADER - sizeof(U_CBPXLFMT) - sizeof(U_OFFPXLFMT) - sizeof(uint32_t) - sizeof(U_SIZEL))
2152
2153/* Index 2,3,4,5,6 */
2171
2172#define U_SIZE_EMRPOLYBEZIER (sizeof(U_EMR) + sizeof(U_RECTL) + sizeof(U_NUM_POINTL) )
2173#define U_SIZE_EMRPOLYGON U_SIZE_EMRPOLYBEZIER
2174#define U_SIZE_EMRPOLYLINE U_SIZE_EMRPOLYBEZIER
2175#define U_SIZE_EMRPOLYBEZIERTO U_SIZE_EMRPOLYBEZIER
2176#define U_SIZE_EMRPOLYLINETO U_SIZE_EMRPOLYBEZIER
2177/* Index 7,8 */
2193#define U_SIZE_EMRPOLYPOLYLINE (sizeof(U_EMR) + sizeof(U_RECTL) + sizeof(U_NUM_POLYCOUNTS) + sizeof(U_NUM_POINTL))
2194#define U_SIZE_EMRPOLYPOLYGON U_SIZE_EMRPOLYPOLYLINE
2195
2196/* Index 9,11 (numbers interleave with next one) */
2206#define U_SIZE_EMRSETWINDOWEXTEX (sizeof(U_EMRSETWINDOWEXTEX ))
2207#define U_SIZE_EMRSETVIEWPORTEXTEX (sizeof(U_EMRSETVIEWPORTEXTEX))
2208
2209/* Index 10,12,13 */
2221#define U_SIZE_EMRSETWINDOWORGEX (sizeof(U_EMRSETWINDOWORGEX ))
2222#define U_SIZE_EMRSETVIEWPORTORGEX (sizeof(U_EMRSETVIEWPORTORGEX))
2223#define U_SIZE_EMRSETBRUSHORGEX (sizeof(U_EMRSETBRUSHORGEX ))
2224
2225/* Index 14 */
2243#define U_SIZE_EMREOF (sizeof(U_EMREOF))
2244
2245/* Index 15 */
2254#define U_SIZE_EMRSETPIXELV (sizeof(U_EMRSETPIXELV))
2255
2256/* Index 16 */
2259typedef struct {
2261 uint32_t dwFlags;
2264#define U_SIZE_EMRSETMAPPERFLAGS (sizeof(U_EMRSETMAPPERFLAGS))
2265
2266/* Index 17,18,19,20,21,22,67,98,115
2267*/
2270typedef struct {
2272 uint32_t iMode;
2291
2292#define U_SIZE_EMRSETMAPMODE (sizeof(U_EMRSETMAPMODE ))
2293#define U_SIZE_EMRSETBKMODE (sizeof(U_EMRSETBKMODE ))
2294#define U_SIZE_EMRSETPOLYFILLMODE (sizeof(U_EMRSETPOLYFILLMODE ))
2295#define U_SIZE_EMRSETROP2 (sizeof(U_EMRSETROP2 ))
2296#define U_SIZE_EMRSETSTRETCHBLTMODE (sizeof(U_EMRSETSTRETCHBLTMODE))
2297#define U_SIZE_EMRSETTEXTALIGN (sizeof(U_EMRSETTEXTALIGN ))
2298#define U_SIZE_EMRSELECTCLIPPATH (sizeof(U_EMRSELECTCLIPPATH ))
2299#define U_SIZE_EMRSETICMMODE (sizeof(U_EMRSETICMMODE ))
2300#define U_SIZE_EMRSETLAYOUT (sizeof(U_EMRSETLAYOUT ))
2301
2302/* Index 23 */
2310#define U_SIZE_EMRSETCOLORADJUSTMENT (sizeof(U_EMRSETCOLORADJUSTMENT))
2311
2312/* Index 24, 25 */
2322#define U_SIZE_EMRSETTEXTCOLOR (sizeof(U_EMRSETTEXTCOLOR))
2323#define U_SIZE_EMRSETBKCOLOR (sizeof(U_EMRSETBKCOLOR ))
2324
2325/* Index 26 */
2333#define U_SIZE_EMROFFSETCLIPRGN (sizeof(U_EMROFFSETCLIPRGN))
2334
2335/* Index 27, 54 */
2347#define U_SIZE_EMRMOVETOEX (sizeof(U_EMRMOVETOEX))
2348#define U_SIZE_EMRLINETO (sizeof(U_EMRLINETO ))
2349
2350/* Index 28,33,52,59,60,61,65,66,68 */
2353typedef struct {
2355}
2374#define U_SIZE_EMRSETMETARGN (sizeof(U_EMRSETMETARGN ))
2375#define U_SIZE_EMRSAVEDC (sizeof(U_EMRSAVEDC ))
2376#define U_SIZE_EMRREALIZEPALETTE (sizeof(U_EMRREALIZEPALETTE))
2377#define U_SIZE_EMRBEGINPATH (sizeof(U_EMRBEGINPATH ))
2378#define U_SIZE_EMRENDPATH (sizeof(U_EMRENDPATH ))
2379#define U_SIZE_EMRCLOSEFIGURE (sizeof(U_EMRCLOSEFIGURE ))
2380#define U_SIZE_EMRFLATTENPATH (sizeof(U_EMRFLATTENPATH ))
2381#define U_SIZE_EMRWIDENPATH (sizeof(U_EMRWIDENPATH ))
2382#define U_SIZE_EMRABORTPATH (sizeof(U_EMRABORTPATH ))
2383
2384/* Index 29,30 */
2394#define U_SIZE_EMREXCLUDECLIPRECT (sizeof(U_EMREXCLUDECLIPRECT ))
2395#define U_SIZE_EMRINTERSECTCLIPRECT (sizeof(U_EMRINTERSECTCLIPRECT ))
2396
2397/* Index 31,32 */
2400typedef struct {
2402 int32_t xNum;
2403 int32_t xDenom;
2404 int32_t yNum;
2405 int32_t yDenom;
2410#define U_SIZE_EMRSCALEVIEWPORTEXTEX (sizeof(U_EMRSCALEVIEWPORTEXTEX))
2411#define U_SIZE_EMRSCALEWINDOWEXTEX (sizeof(U_EMRSCALEWINDOWEXTEX ))
2412
2413/* Index 33 (see 28) */
2414
2415/* Index 34 */
2418typedef struct {
2420 int32_t iRelative;
2423#define U_SIZE_EMRRESTOREDC (sizeof(U_EMRRESTOREDC))
2424
2425/* Index 35 */
2433#define U_SIZE_EMRSETWORLDTRANSFORM (sizeof(U_EMRSETWORLDTRANSFORM))
2434
2435/* Index 36 */
2444#define U_SIZE_EMRMODIFYWORLDTRANSFORM (sizeof(U_EMRMODIFYWORLDTRANSFORM))
2445
2446/* Index 37,40 */
2449typedef struct {
2451 uint32_t ihObject;
2456#define U_SIZE_EMRDELETEOBJECT (sizeof(U_EMRDELETEOBJECT))
2457#define U_SIZE_EMRSELECTOBJECT (sizeof(U_EMRSELECTOBJECT))
2458
2459/* Index 38 */
2462typedef struct {
2464 uint32_t ihPen;
2468#define U_SIZE_EMRCREATEPEN (sizeof(U_EMRCREATEPEN))
2469
2470/* Index 39 */
2479#define U_SIZE_EMRCREATEBRUSHINDIRECT (sizeof(U_EMRCREATEBRUSHINDIRECT))
2480
2481/* Index 40 see 37 */
2482
2483/* Index 41 */
2494#define U_SIZE_EMRANGLEARC (sizeof(U_EMRANGLEARC))
2495
2496/* Index 42,43 */
2506#define U_SIZE_EMRELLIPSE (sizeof(U_EMRELLIPSE ))
2507#define U_SIZE_EMRRECTANGLE (sizeof(U_EMRRECTANGLE))
2508
2509/* Index 44 */
2518#define U_SIZE_EMRROUNDRECT (sizeof(U_EMRROUNDRECT))
2519
2520/* Index 45, 46 ,47, 55 */
2536#define U_SIZE_EMRARC (sizeof(U_EMRARC ))
2537#define U_SIZE_EMRCHORD (sizeof(U_EMRCHORD))
2538#define U_SIZE_EMRPIE (sizeof(U_EMRPIE ))
2539#define U_SIZE_EMRARCTO (sizeof(U_EMRARCTO))
2540
2541/* Index 48 */
2544typedef struct {
2546 uint32_t ihPal;
2549#define U_SIZE_EMRSELECTPALETTE (sizeof(U_EMRSELECTPALETTE))
2550
2551/* Index 49 */
2560#define U_SIZE_EMRCREATEPALETTE (sizeof(U_EMR) + sizeof(uint32_t) + U_SIZE_LOGPALETTE)
2561
2562/* Index 50 */
2573#define U_SIZE_EMRSETPALETTEENTRIES (sizeof(U_EMR) + 2*sizeof(uint32_t) + sizeof(U_NUM_LOGPLTNTRY))
2574
2575/* Index 51 */
2578typedef struct {
2580 uint32_t ihPal;
2581 uint32_t cEntries;
2584#define U_SIZE_EMRRESIZEPALETTE (sizeof(U_EMRRESIZEPALETTE))
2585
2586/* Index 52 (see 28) */
2587
2588/* Index 53 */
2598#define U_SIZE_EMREXTFLOODFILL (sizeof(U_EMREXTFLOODFILL))
2599
2600/* Index 54 (see 27) */
2601
2602/* Index 55 (see 45) */
2603
2604/* Index 56 */
2617#define U_SIZE_EMRPOLYDRAW (sizeof(U_EMR) + sizeof(U_RECTL) + sizeof(U_NUM_POINTL))
2618
2619/* Index 57 */
2622typedef struct {
2624 uint32_t iArcDirection;
2627#define U_SIZE_EMRSETARCDIRECTION (sizeof(U_EMRSETARCDIRECTION))
2628
2629/* Index 58 */
2635typedef struct {
2637 uint32_t eMiterLimit;
2640#define U_SIZE_EMRSETMITERLIMIT (sizeof(U_EMRSETMITERLIMIT))
2641
2642/* Index 59,60,61 (see 28) */
2643
2644/* Index 62,63,64 */
2656#define U_SIZE_EMRFILLPATH (sizeof(U_EMRFILLPATH ))
2657#define U_SIZE_EMRSTROKEANDFILLPATH (sizeof(U_EMRSTROKEANDFILLPATH))
2658#define U_SIZE_EMRSTROKEPATH (sizeof(U_EMRSTROKEPATH ))
2659
2660/* Index 65,66 (see 28) */
2661/* Index 67 (see 17) */
2662/* Index 68 (see 28) */
2663/* Index 69 (not a defined U_EMR record type ) */
2664
2665
2666/* Index 70 */
2669typedef struct {
2672 uint8_t Data[1];
2673} U_EMRCOMMENT,
2675#define U_SIZE_EMRCOMMENT (sizeof(U_EMR) + sizeof(U_CBDATA))
2676
2677/* variant comment types */
2680typedef struct {
2683 uint32_t cIdent;
2684 uint8_t Data[1];
2687#define U_SIZE_EMRCOMMENT_EMFPLUS (sizeof(U_EMR) + sizeof(U_CBDATA) + sizeof(uint32_t))
2688
2691typedef struct {
2694 uint32_t cIdent;
2695 uint32_t esrIdent;
2696 uint8_t Data[1];
2699#define U_SIZE_EMRCOMMENT_SPOOL (sizeof(U_EMR) + sizeof(U_CBDATA) + 2*sizeof(uint32_t))
2700
2703typedef struct {
2706 uint32_t cIdent;
2707 uint32_t pcIdent;
2708 uint8_t Data[1];
2711#define U_SIZE_EMRCOMMENT_PUBLIC (sizeof(U_EMR) + sizeof(U_CBDATA) + 2*sizeof(uint32_t))
2712
2713/* Index 71 */
2725#define U_SIZE_EMRFILLRGN (sizeof(U_EMR) + sizeof(U_RECTL) + sizeof(U_CBRGNDATA) + sizeof(uint32_t))
2726
2727/* Index 72 */
2739#define U_SIZE_EMRFRAMERGN (sizeof(U_EMR) + sizeof(U_RECTL) + sizeof(U_CBRGNDATA) + sizeof(uint32_t) + sizeof(U_SIZEL))
2740
2741/* Index 73,74 */
2753#define U_SIZE_EMRINVERTRGN (sizeof(U_EMR) + sizeof(U_RECTL) + sizeof(U_CBRGNDATA))
2754#define U_SIZE_EMRPAINTRGN U_SIZE_EMRINVERTRGN
2755
2756/* Index 75 */
2766#define U_SIZE_EMREXTSELECTCLIPRGN (sizeof(U_EMR) + sizeof(U_CBRGNDATA) + sizeof(uint32_t))
2767
2768/* Index 76 */
2788#define U_SIZE_EMRBITBLT (sizeof(U_EMRBITBLT))
2789
2790/* Index 77 */
2811#define U_SIZE_EMRSTRETCHBLT (sizeof(U_EMRSTRETCHBLT))
2812
2813/* Index 78 */
2839#define U_SIZE_EMRMASKBLT (sizeof(U_EMRMASKBLT))
2840
2841/* Index 79 */
2866#define U_SIZE_EMRPLGBLT (sizeof(U_EMRPLGBLT))
2867
2868/* Index 80 */
2887#define U_SIZE_EMRSETDIBITSTODEVICE (sizeof(U_EMRSETDIBITSTODEVICE))
2888
2889/* Index 81 */
2908#define U_SIZE_EMRSTRETCHDIBITS (sizeof(U_EMRSTRETCHDIBITS))
2909
2910/* Index 82 */
2919#define U_SIZE_EMREXTCREATEFONTINDIRECTW_LOGFONT_PANOSE (sizeof(U_EMR) + 4 + sizeof(U_LOGFONT_PANOSE))
2920#define U_SIZE_EMREXTCREATEFONTINDIRECTW_LOGFONT (sizeof(U_EMR) + 4 + sizeof(U_LOGFONT))
2921
2922/* Index 83,84 */
2944#define U_SIZE_EMREXTTEXTOUTA (sizeof(U_EMREXTTEXTOUTA))
2945#define U_SIZE_EMREXTTEXTOUTW (sizeof(U_EMREXTTEXTOUTW))
2946
2947/* Index 85,86,87,88,89 */
2965#define U_SIZE_EMRPOLYBEZIER16 (sizeof(U_EMR) + sizeof(U_RECTL) + sizeof(U_NUM_POINT16))
2966#define U_SIZE_EMRPOLYGON16 U_SIZE_EMRPOLYBEZIER16
2967#define U_SIZE_EMRPOLYLINE16 U_SIZE_EMRPOLYBEZIER16
2968#define U_SIZE_EMRPOLYBEZIERTO16 U_SIZE_EMRPOLYBEZIER16
2969#define U_SIZE_EMRPOLYLINETO16 U_SIZE_EMRPOLYBEZIER16
2970/* Index 90,91 */
2986#define U_SIZE_EMRPOLYPOLYLINE16 (sizeof(U_EMR) + sizeof(U_RECTL) + sizeof(U_NUM_POLYCOUNTS) + sizeof(U_NUM_POINT16))
2987#define U_SIZE_EMRPOLYPOLYGON16 U_SIZE_EMRPOLYPOLYLINE16
2988
2989/* Index 92 */
3003#define U_SIZE_EMRPOLYDRAW16 (sizeof(U_EMR) + sizeof(U_RECTL) + sizeof(U_NUM_POINT16))
3004
3005/* Index 93 */
3019#define U_SIZE_EMRCREATEMONOBRUSH (sizeof(U_EMRCREATEMONOBRUSH))
3020
3021/* Index 94 */
3035#define U_SIZE_EMRCREATEDIBPATTERNBRUSHPT (sizeof(U_EMRCREATEDIBPATTERNBRUSHPT))
3036
3037/* Index 95 */
3051#define U_SIZE_EMREXTCREATEPEN (sizeof(U_EMREXTCREATEPEN) - sizeof(U_EXTLOGPEN) + U_SIZE_EXTLOGPEN)
3052
3053/* Index 96.97 */
3068#define U_SIZE_EMRPOLYTEXTOUTA (sizeof(U_EMR) + sizeof(U_RECTL) + sizeof(uint32_t) + 2*sizeof(U_FLOAT) + sizeof(U_NUM_EMRTEXT))
3069#define U_SIZE_EMRPOLYTEXTOUTW U_SIZE_EMRPOLYTEXTOUTA
3070
3071/* Index 98 (see 17) */
3072
3073/* Index 99 */
3082#define U_SIZE_EMRCREATECOLORSPACE (sizeof(U_EMRCREATECOLORSPACE))
3083
3084/* Index 100,101 */
3087typedef struct {
3089 uint32_t ihCS;
3094#define U_SIZE_EMRDELETECOLORSPACE (sizeof(U_EMRDELETECOLORSPACE))
3095#define U_SIZE_EMRSETCOLORSPACE (sizeof(U_EMRSETCOLORSPACE ))
3096
3097/* Index 102 */
3106#define U_SIZE_EMRGLSRECORD (sizeof(U_EMR) + sizeof(U_CBDATA))
3107
3108/* Index 103 */
3118#define U_SIZE_EMRGLSBOUNDEDRECORD (sizeof(U_EMR) + sizeof(U_RECTL) + sizeof(U_CBDATA))
3119
3120/* Index 104 */
3128#define U_SIZE_EMRPIXELFORMAT (sizeof(U_EMRPIXELFORMAT))
3129
3130/* Index 105 */
3133typedef struct {
3136 U_DATA Data[1];
3139#define U_SIZE_EMRDRAWESCAPE (sizeof(U_EMR) + sizeof(U_CBDATA))
3140
3141/* Index 106 */
3144typedef struct {
3147 U_DATA Data[1];
3150#define U_SIZE_EMREXTESCAPE (sizeof(U_EMR) + sizeof(U_CBDATA))
3151
3152/* Index 107 (not implemented ) */
3153
3154/* Index 108 */
3170#define U_SIZE_EMRSMALLTEXTOUT (sizeof(U_EMRSMALLTEXTOUT))
3171
3172/* Index 109 (not implemented )
3173EMF manual 2.3.11.2
3174*/
3175
3176/* Index 110 */
3182typedef struct {
3186 uint16_t Driver[1];
3189#define U_SIZE_EMRNAMEDESCAPE (sizeof(U_EMR) + 2*sizeof(U_CBDATA))
3190
3191/* Index 111-113 (not implemented )
3192 EMF manual 2.3.8.1
3193 EMF manual 2.3.11.15
3194 EMF manual 2.3.11.16
3195*/
3196
3197/* Index 114 */
3218#define U_SIZE_EMRALPHABLEND (sizeof(U_EMRALPHABLEND))
3219
3220/* Index 115 (see 17) */
3221
3222/* Index 116 */
3243#define U_SIZE_EMRTRANSPARENTBLT (sizeof(U_EMRTRANSPARENTBLT))
3244
3245/* Index 117 (not a defined U_EMR record type ) */
3246
3247/* Index 118 */
3262#define U_SIZE_EMRGRADIENTFILL (sizeof(U_EMRGRADIENTFILL))
3263
3264/* Index 119,120 (not implemented )
3265EMF manual 2.3.11.18
3266EMF manual 2.3.11.27
3267*/
3268
3269/* Index 121 */
3281#define U_SIZE_EMRCOLORMATCHTOTARGETW (sizeof(U_EMR) + 2*sizeof(uint32_t) + sizeof(U_CBNAME) + sizeof(U_CBDATA))
3282
3283/* Index 122 */
3286typedef struct {
3288 uint32_t ihCS;
3290 uint32_t dwFlags;
3292 uint8_t Data[1];
3295#define U_SIZE_EMRCREATECOLORSPACEW (sizeof(U_EMR) + 2*sizeof(uint32_t) + sizeof(U_LOGCOLORSPACEW) + sizeof(U_CBDATA))
3296
3297// records which are not documented, so we have no idea what to do with them
3298#define U_SIZE_EMRUNDEFINED 2048
3299
3300// ************************************************************************************************
3301// Utility function structures
3302
3306typedef struct {
3307 FILE *fp;
3308 size_t allocated;
3309 size_t used;
3310 uint32_t records;
3311 uint16_t ignore;
3312 uint32_t PalEntries;
3313 uint32_t chunk;
3314 char *buf;
3315} EMFTRACK;
3316
3327typedef struct {
3328 uint32_t *table;
3329 uint32_t *stack;
3330 size_t allocated;
3331 size_t chunk;
3332 uint32_t sptr;
3333 uint32_t top;
3334 uint32_t peak;
3335} EMFHANDLES;
3336
3340typedef struct {
3341 double M11;
3342 double M12;
3343 double M21;
3344 double M22;
3345} U_MAT2X2,
3347
3348// ************************************************************************************************
3349// Prototypes
3350
3352int memprobe(const void *buf, size_t size);
3353void wchar8show(const char *src);
3354void wchar16show(const uint16_t *src);
3355void wchar32show(const uint32_t *src);
3356void wchartshow(const wchar_t *src);
3357void dumpeht(char *string, unsigned int *handle, EMFHANDLES *eht);
3358
3359
3360char *U_emr_names(unsigned int idx);
3361uint32_t *dx_set(int32_t height, uint32_t weight, uint32_t members);
3362uint32_t emr_properties(uint32_t type);
3363int emr_arc_points(PU_ENHMETARECORD record, int *f1, int f2, PU_PAIRF center, PU_PAIRF start, PU_PAIRF end, PU_PAIRF size);
3364int emr_arc_points_common(PU_RECTL rclBox, PU_POINTL ArcStart, PU_POINTL ArcEnd,
3365 int *f1, int f2, PU_PAIRF center, PU_PAIRF start, PU_PAIRF end, PU_PAIRF size);
3366int get_real_color_count(const char *Bmih);
3367int get_real_color_icount(int Colors, int BitCount, int Width, int Height);
3368int RGBA_to_DIB(char **px, uint32_t *cbPx, PU_RGBQUAD *ct, int *numCt,
3369 const char *rgba_px, int w, int h, int stride, uint32_t colortype, int use_ct, int invert);
3370int get_DIB_params( const char *record, uint32_t offBitsSrc, uint32_t offBmiSrc,
3371 const char **px, const U_RGBQUAD **ct, uint32_t *numCt,
3372 uint32_t *width, uint32_t *height, uint32_t *colortype, uint32_t *invert );
3373int DIB_to_RGBA(const char *px, const U_RGBQUAD *ct, int numCt,
3374 char **rgba_px, int w, int h, uint32_t colortype, int use_ct, int invert);
3375char *RGBA_to_RGBA(char *rgba_px, int w, int h, int sl, int st, int *ew, int *eh);
3376
3377int device_size(const int xmm, const int ymm, const float dpmm, U_SIZEL *szlDev, U_SIZEL *szlMm);
3378int drawing_size(const int xmm, const int yum, const float dpmm, U_RECTL *rclBounds, U_RECTL *rclFrame);
3379
3380int emf_start(const char *name, const uint32_t initsize, const uint32_t chunksize, EMFTRACK **et);
3381int emf_finish(EMFTRACK *et, EMFHANDLES *eht);
3382int emf_free(EMFTRACK **et);
3383int emf_append(U_ENHMETARECORD *rec, EMFTRACK *et, int freerec);
3384int emf_readdata(const char *filename, char **contents, size_t *length);
3385FILE *emf_fopen(const char *filename, const int mode);
3386
3387
3388/* use these instead*/
3389int emf_htable_create(uint32_t initsize, uint32_t chunksize, EMFHANDLES **eht);
3390int emf_htable_delete(uint32_t *ih, EMFHANDLES *eht);
3391int emf_htable_insert(uint32_t *ih, EMFHANDLES *eht);
3392int emf_htable_free(EMFHANDLES **eht);
3393/* Deprecated forms */
3394#define htable_create emf_htable_create
3395#define htable_delete emf_htable_delete
3396#define htable_insert emf_htable_insert
3397#define htable_free emf_htable_free
3398
3399U_RECTL rectl_set(U_POINTL ul, U_POINTL lr);
3400void rectli_set(PU_RECTL array, int index, U_POINTL ul, U_POINTL lr);
3401U_SIZEL sizel_set(int32_t x, int32_t y);
3402U_POINTL point32_set(int32_t x, int32_t y);
3403#define point_set point32_set
3404#define pointl_set point32_set
3405U_POINT16 point16_set(int16_t x, int16_t y);
3406U_PANOSE panose_set(uint8_t bFamilyType, uint8_t bSerifStyle, uint8_t bWeight, uint8_t bProportion,
3407 uint8_t bContrast, uint8_t bStrokeVariation, uint8_t bArmStyle, uint8_t bLetterform,
3408 uint8_t bMidline, uint8_t bXHeight );
3409U_COLORREF colorref3_set(uint8_t red, uint8_t green, uint8_t blue);
3410U_COLORREF colorref4_set(uint8_t red, uint8_t green, uint8_t blue, uint8_t reserved);
3411U_RGBQUAD rgbquad_set(uint8_t red,uint8_t green, uint8_t blue, uint8_t reserved);
3412U_LOGBRUSH logbrush_set(uint32_t lbStyle, U_COLORREF lbColor, int32_t lbHatch);
3413U_XFORM xform_set(U_FLOAT eM11, U_FLOAT eM12, U_FLOAT eM21, U_FLOAT eM22, U_FLOAT eDx, U_FLOAT eDy);
3414U_XFORM xform_alt_set(U_FLOAT scale, U_FLOAT ratio, U_FLOAT rot, U_FLOAT axisrot, U_FLOAT eDx, U_FLOAT eDy);
3415U_LOGPEN logpen_set( uint32_t lopnStyle, U_POINT lopnWidth, U_COLORREF lopnColor );
3416PU_EXTLOGPEN extlogpen_set(uint32_t elpPenStyle, uint32_t elpWidth, uint32_t elpBrushStyle,
3417 U_COLORREF elpColor, int32_t elpHatch, U_NUM_STYLEENTRY elpNumEntries, U_STYLEENTRY *elpStyleEntry );
3418U_LOGFONT_PANOSE logfont_panose_set(U_LOGFONT elfLogFont, uint16_t *elfFullName,
3419 uint16_t *elfStyle, uint32_t elfStyleSize, U_PANOSE elfPanose);
3420U_LOGFONT logfont_set( int32_t lfHeight, int32_t lfWidth, int32_t lfEscapement, int32_t lfOrientation,
3421 int32_t lfWeight, uint8_t lfItalic, uint8_t lfUnderline, uint8_t lfStrikeOut,
3422 uint8_t lfCharSet, uint8_t lfOutPrecision, uint8_t lfClipPrecision,
3423 uint8_t lfQuality, uint8_t lfPitchAndFamily, uint16_t *lfFaceName);
3424char *emrtext_set(U_POINTL ptlReference, U_NUM_STR NumString, uint32_t cbChar, void *String, uint32_t fOptions, U_RECTL rcl, uint32_t *Dx);
3425U_LOGPLTNTRY logpltntry_set(uint8_t peReserved,uint8_t peRed,uint8_t peGreen,uint8_t peBlue);
3426PU_LOGPALETTE logpalette_set(U_NUM_LOGPLTNTRY palNumEntries,PU_LOGPLTNTRY *palPalEntry);
3427U_RGNDATAHEADER rgndataheader_set( U_NUM_RECTL nCount, U_RECTL rcBound);
3428PU_RGNDATA rgndata_set( U_RGNDATAHEADER rdh, PU_RECTL Buffer);
3429U_BITMAPINFOHEADER bitmapinfoheader_set(int32_t biWidth, int32_t biHeight,
3430 uint16_t biPlanes, uint16_t biBitCount, uint32_t biCompression,
3431 uint32_t biSizeImage, int32_t biXPelsPerMeter,
3432 int32_t biYPelsPerMeter, U_NUM_RGBQUAD biClrUsed, uint32_t biClrImportant);
3433PU_BITMAPINFO bitmapinfo_set(U_BITMAPINFOHEADER BmiHeader, PU_RGBQUAD BmiColors);
3434U_LOGCOLORSPACEA logcolorspacea_set(int32_t lcsCSType, int32_t lcsIntent,
3435 U_CIEXYZTRIPLE lcsEndpoints, U_LCS_GAMMARGB lcsGammaRGB, char *lcsFilename);
3436U_LOGCOLORSPACEW logcolorspacew_set(int32_t lcsCSType, int32_t lcsIntent,
3437 U_CIEXYZTRIPLE lcsEndpoints, U_LCS_GAMMARGB lcsGammaRGB, uint16_t *lcsFilename);
3438U_COLORADJUSTMENT coloradjustment_set(uint16_t Size, uint16_t Flags, uint16_t IlluminantIndex,
3439 uint16_t RedGamma, uint16_t GreenGamma, uint16_t BlueGamma,
3440 uint16_t ReferenceBlack, uint16_t ReferenceWhite,
3441 int16_t Contrast, int16_t Brightness, int16_t Colorfulness, int16_t RedGreenTint);
3442U_PIXELFORMATDESCRIPTOR pixelformatdescriptor_set( uint32_t dwFlags, uint8_t iPixelType, uint8_t cColorBits,
3443 uint8_t cRedBits, uint8_t cRedShift,
3444 uint8_t cGreenBits, uint8_t cGreenShift,
3445 uint8_t cBlueBits, uint8_t cBlueShift,
3446 uint8_t cAlphaBits, uint8_t cAlphaShift,
3447 uint8_t cAccumBits, uint8_t cAccumRedBits, uint8_t cAccumGreenBits, uint8_t cAccumBlueBits,
3448 uint8_t cAccumAlphaBits, uint8_t cDepthBits, uint8_t cStencilBits,
3449 uint8_t cAuxBuffers, uint8_t iLayerType, uint8_t bReserved, uint32_t dwLayerMask,
3450 uint32_t dwVisibleMask, uint32_t dwDamageMask);
3451
3452PU_POINT points_transform(PU_POINT points, int count, U_XFORM xform);
3453PU_POINT16 point16_transform(PU_POINT16 points, int count, U_XFORM xform);
3454PU_TRIVERTEX trivertex_transform(PU_TRIVERTEX tv, int count, U_XFORM xform);
3455PU_POINT point16_to_point(PU_POINT16 points, int count);
3456PU_POINT16 point_to_point16(PU_POINT points, int count);
3457
3458U_RECT findbounds(uint32_t count, PU_POINT pts, uint32_t width);
3459U_RECT findbounds16(uint32_t count, PU_POINT16 pts, uint32_t width);
3460char *emr_dup(const char *emr);
3461
3462char *textcomment_set(const char *string);
3463
3464// These generate the handle and then call the underlying function
3465char *deleteobject_set(uint32_t *ihObject, EMFHANDLES *eht);
3466char *selectobject_set(uint32_t ihObject, EMFHANDLES *eht);
3467char *createpen_set(uint32_t *ihPen, EMFHANDLES *eht, U_LOGPEN lopn );
3468char *extcreatepen_set(uint32_t *ihPen, EMFHANDLES *eht,
3469 PU_BITMAPINFO Bmi, const uint32_t cbPx, char *Px, PU_EXTLOGPEN elp);
3470char *createbrushindirect_set(uint32_t *ihBrush, EMFHANDLES *eht, U_LOGBRUSH lb );
3471char *createdibpatternbrushpt_set(uint32_t *ihBrush, EMFHANDLES *eht, uint32_t iUsage,
3472 PU_BITMAPINFO Bmi, const uint32_t cbPx, const char *Px);
3473char *createmonobrush_set(uint32_t *ihBrush, EMFHANDLES *eht, uint32_t iUsage,
3474 PU_BITMAPINFO Bmi, const uint32_t cbPx, const char *Px);
3475char *extcreatefontindirectw_set(uint32_t *ihFont, EMFHANDLES *eht, const char *elf, const char *elfw);
3476char *createpalette_set(uint32_t *ihPal, EMFHANDLES *eht, U_LOGPALETTE lgpl);
3477char *setpaletteentries_set(uint32_t *ihPal, EMFHANDLES *eht, uint32_t iStart, U_NUM_LOGPLTNTRY cEntries, PU_LOGPLTNTRY aPalEntries);
3478char *fillrgn_set(uint32_t *ihBrush, EMFHANDLES *eht, U_RECTL rclBounds,PU_RGNDATA RgnData);
3479char *framergn_set(uint32_t *ihBrush, EMFHANDLES *eht, U_RECTL rclBounds, U_SIZEL szlStroke, PU_RGNDATA RgnData);
3480char *createcolorspace_set(uint32_t *ihCS, EMFHANDLES *eht, U_LOGCOLORSPACEA lcs);
3481char *createcolorspacew_set(uint32_t *ihCS, EMFHANDLES *eht, U_LOGCOLORSPACEW lcs, uint32_t dwFlags, U_CBDATA cbData, uint8_t *Data);
3482
3483char *U_EMRHEADER_set( const U_RECTL rclBounds, const U_RECTL rclFrame, U_PIXELFORMATDESCRIPTOR* const pfmtDesc,
3484 U_CBSTR nDesc, uint16_t* const Description, const U_SIZEL szlDevice, const U_SIZEL szlMillimeters,
3485 const uint32_t bOpenGL);
3486char *U_EMRPOLYBEZIER_set( const U_RECTL rclBounds, const uint32_t count, const U_POINTL *points);
3487char *U_EMRPOLYGON_set( const U_RECTL rclBounds, const uint32_t count, const U_POINTL *points);
3488char *U_EMRPOLYLINE_set( const U_RECTL rclBounds, const uint32_t count, const U_POINTL *points);
3489char *U_EMRPOLYBEZIERTO_set(const U_RECTL rclBounds, const uint32_t count, const U_POINTL *points);
3490char *U_EMRPOLYLINETO_set( const U_RECTL rclBounds, const uint32_t count, const U_POINTL *points);
3491
3492char *U_EMRPOLYPOLYLINE_set(const U_RECTL rclBounds, const uint32_t nPolys, const uint32_t *aPolyCounts,
3493 const uint32_t cptl, const U_POINTL *points);
3494char *U_EMRPOLYPOLYGON_set(const U_RECTL rclBounds, const uint32_t nPolys, const uint32_t *aPolyCounts,
3495 const uint32_t cptl, const U_POINTL *points);
3496char *U_EMRSETWINDOWEXTEX_set(const U_SIZEL szlExtent);
3497char *U_EMRSETWINDOWORGEX_set(const U_POINTL ptlOrigin);
3498char *U_EMRSETVIEWPORTEXTEX_set(const U_SIZEL szlExtent);
3499char *U_EMRSETVIEWPORTORGEX_set(const U_POINTL ptlOrigin);
3500char *U_EMRSETBRUSHORGEX_set(const U_POINTL ptlOrigin);
3501char *U_EMREOF_set(const U_CBPLENTRIES cbPalEntries, const PU_LOGPLTNTRY PalEntries, EMFTRACK *et);
3502char *U_EMRSETPIXELV_set(const U_POINTL ptlPixel, const U_COLORREF crColor);
3503char *U_EMRSETMAPPERFLAGS_set(void);
3504char *U_EMRSETMAPMODE_set(const uint32_t iMode);
3505char *U_EMRSETBKMODE_set(const uint32_t iMode);
3506char *U_EMRSETPOLYFILLMODE_set(const uint32_t iMode);
3507char *U_EMRSETROP2_set(const uint32_t iMode);
3508char *U_EMRSETSTRETCHBLTMODE_set(const uint32_t iMode);
3509char *U_EMRSETTEXTALIGN_set(const uint32_t iMode);
3510char *U_EMRSETCOLORADJUSTMENT_set(const U_COLORADJUSTMENT ColorAdjustment);
3511char *U_EMRSETTEXTCOLOR_set(const U_COLORREF crColor);
3512char *U_EMRSETBKCOLOR_set(const U_COLORREF crColor);
3513char *U_EMROFFSETCLIPRGN_set(const U_POINTL ptl);
3514char *U_EMRMOVETOEX_set(const U_POINTL ptl);
3515char *U_EMRSETMETARGN_set(void);
3516char *U_EMREXCLUDECLIPRECT_set(const U_RECTL rclClip);
3517char *U_EMRINTERSECTCLIPRECT_set(const U_RECTL rclClip);
3518char *U_EMRSCALEVIEWPORTEXTEX_set(const int32_t xNum, const int32_t xDenom, const int32_t yNum, const int32_t yDenom);
3519char *U_EMRSCALEWINDOWEXTEX_set(const int32_t xNum, const int32_t xDenom, const int32_t yNum, const int32_t yDenom);
3520char *U_EMRSAVEDC_set(void);
3521char *U_EMRRESTOREDC_set(const int32_t iRelative);
3522char *U_EMRSETWORLDTRANSFORM_set(const U_XFORM xform);
3523char *U_EMRMODIFYWORLDTRANSFORM_set(const U_XFORM xform, const uint32_t iMode);
3524char *U_EMRSELECTOBJECT_set(const uint32_t ihObject); // better to call selectobject_set()
3525char *U_EMRCREATEPEN_set(const uint32_t ihPen, const U_LOGPEN lopn );
3526char *U_EMRCREATEBRUSHINDIRECT_set(const uint32_t ihBrush, const U_LOGBRUSH lb);
3527char *U_EMRDELETEOBJECT_set(const uint32_t ihObject); // better to call deleteobject_set()
3528char *U_EMRANGLEARC_set(const U_POINTL ptlCenter, const uint32_t nRadius, const U_FLOAT eStartAngle, const U_FLOAT eSweepAngle);
3529char *U_EMRELLIPSE_set(const U_RECTL rclBox);
3530char *U_EMRRECTANGLE_set(const U_RECTL rclBox);
3531char *U_EMRROUNDRECT_set(const U_RECTL rclBox, const U_SIZEL szlCorner);
3532char *U_EMRARC_set(const U_RECTL rclBox, const U_POINTL ptlStart, const U_POINTL ptlEnd);
3533char *U_EMRCHORD_set(const U_RECTL rclBox, const U_POINTL ptlStart, const U_POINTL ptlEnd);
3534char *U_EMRPIE_set(const U_RECTL rclBox, const U_POINTL ptlStart, const U_POINTL ptlEnd);
3535char *U_EMRSELECTPALETTE_set(const uint32_t ihPal);
3536char *U_EMRCREATEPALETTE_set(const uint32_t ihPal, const U_LOGPALETTE lgpl);
3537char *U_EMRSETPALETTEENTRIES_set(const uint32_t ihPal, const uint32_t iStart, const U_NUM_LOGPLTNTRY cEntries, const PU_LOGPLTNTRY aPalEntries);
3538char *U_EMRRESIZEPALETTE_set(const uint32_t ihPal, const uint32_t cEntries);
3539char *U_EMRREALIZEPALETTE_set(void);
3540char *U_EMREXTFLOODFILL_set(const U_POINTL ptlStart, const U_COLORREF crColor, const uint32_t iMode);
3541char *U_EMRLINETO_set(const U_POINTL ptl);
3542char *U_EMRARCTO_set(const U_RECTL rclBox, const U_POINTL ptlStart, const U_POINTL ptlEnd);
3543char *U_EMRPOLYDRAW_set(const U_RECTL rclBounds,const U_NUM_POINTL cptl,const U_POINTL *aptl,const uint8_t *abTypes);
3544char *U_EMRSETARCDIRECTION_set(const uint32_t iArcDirection);
3545char *U_EMRSETMITERLIMIT_set(const uint32_t eMiterLimit);
3546char *U_EMRBEGINPATH_set(void);
3547char *U_EMRENDPATH_set(void);
3548char *U_EMRCLOSEFIGURE_set(void);
3549char *U_EMRFILLPATH_set(const U_RECTL rclBox);
3550char *U_EMRSTROKEANDFILLPATH_set(const U_RECTL rclBox);
3551char *U_EMRSTROKEPATH_set(const U_RECTL rclBox);
3552char *U_EMRFLATTENPATH_set(void);
3553char *U_EMRWIDENPATH_set(void);
3554char *U_EMRSELECTCLIPPATH_set(const uint32_t iMode);
3555char *U_EMRABORTPATH_set(void);
3556// EMR_ENDEF69
3557char *U_EMRCOMMENT_set(const U_CBDATA cbData, const char *Data);
3558char *U_EMRFILLRGN_set(const U_RECTL rclBounds, const uint32_t ihBrush, const PU_RGNDATA RgnData);
3559char *U_EMRFRAMERGN_set(const U_RECTL rclBounds, const uint32_t ihBrush, const U_SIZEL szlStroke, const PU_RGNDATA RgnData);
3560char *U_EMRINVERTRGN_set(const PU_RGNDATA RgnData);
3561char *U_EMRPAINTRGN_set(const PU_RGNDATA RgnData);
3562char *U_EMREXTSELECTCLIPRGN_set(const uint32_t iMode, const PU_RGNDATA RgnData);
3563char *U_EMRBITBLT_set(const U_RECTL rclBounds, const U_POINTL Dest, const U_POINTL cDest,
3564 const U_POINTL Src, const U_XFORM xformSrc, const U_COLORREF crBkColorSrc,
3565 const uint32_t iUsageSrc, const uint32_t dwRop,
3566 const PU_BITMAPINFO Bmi, const uint32_t cbPx, char *Px);
3567char *U_EMRSTRETCHBLT_set(U_RECTL rclBounds, U_POINTL Dest, U_POINTL cDest,
3568 const U_POINTL Src, const U_POINTL cSrc, const U_XFORM xformSrc, const U_COLORREF crBkColorSrc, const uint32_t iUsageSrc,
3569 const uint32_t dwRop,
3570 const PU_BITMAPINFO Bmi, const uint32_t cbPx, char *Px);
3571char *U_EMRMASKBLT_set(U_RECTL rclBounds, U_POINTL Dest, U_POINTL cDest,
3572 const U_POINTL Src, const U_XFORM xformSrc, const U_COLORREF crBkColorSrc, const uint32_t iUsageSrc,
3573 const U_POINTL Mask, const uint32_t iUsageMask,
3574 const uint32_t dwRop,
3575 const PU_BITMAPINFO Bmi, const uint32_t cbPx, char *Px,
3576 const PU_BITMAPINFO BmiMsk, const uint32_t cbMsk, char *Msk);
3577char *U_EMRPLGBLT_set(const U_RECTL rclBounds, const PU_POINTL aptlDst,
3578 const U_POINTL Src, const U_POINTL cSrc, const U_XFORM xformSrc, const U_COLORREF crBkColorSrc, const uint32_t iUsageSrc,
3579 const U_POINTL Mask, const uint32_t iUsageMask,
3580 const PU_BITMAPINFO Bmi, const uint32_t cbPx, char *Px,
3581 const PU_BITMAPINFO BmiMsk, const uint32_t cbMsk, char *Msk);
3582char *U_EMRSETDIBITSTODEVICE_set(const U_RECTL rclBounds, const U_POINTL Dest,
3583 const U_POINTL Src, const U_POINTL cSrc, const uint32_t iUsageSrc,
3584 const uint32_t iStartScan, const uint32_t cScans,
3585 const PU_BITMAPINFO Bmi, const uint32_t cbPx, char *Px);
3586char *U_EMRSTRETCHDIBITS_set(const U_RECTL rclBounds, const U_POINTL Dest, const U_POINTL cDest,
3587 const U_POINTL Src, const U_POINTL cSrc, const uint32_t iUsageSrc,
3588 const uint32_t dwRop,
3589 const PU_BITMAPINFO Bmi, const uint32_t cbPx, char *Px);
3590char *U_EMREXTCREATEFONTINDIRECTW_set( uint32_t ihFont, const char *elf, const char *elfw);
3591char *U_EMREXTTEXTOUTA_set(U_RECTL rclBounds, uint32_t iGraphicsMode, U_FLOAT exScale, U_FLOAT eyScale, PU_EMRTEXT emrtext);
3592char *U_EMREXTTEXTOUTW_set(U_RECTL rclBounds, uint32_t iGraphicsMode, U_FLOAT exScale, U_FLOAT eyScale, PU_EMRTEXT emrtext);
3593char *U_EMRPOLYBEZIER16_set(const U_RECTL rclBounds, const uint32_t cpts, const U_POINT16 *points);
3594char *U_EMRPOLYGON16_set(const U_RECTL rclBounds, const uint32_t cpts, const U_POINT16 *points);
3595char *U_EMRPOLYLINE16_set(const U_RECTL rclBounds, const uint32_t cpts, const U_POINT16 *points);
3596char *U_EMRPOLYBEZIERTO16_set(const U_RECTL rclBounds, const uint32_t cpts, const U_POINT16 *points);
3597char *U_EMRPOLYLINETO16_set(const U_RECTL rclBounds, const uint32_t cpts, const U_POINT16 *points);
3598char *U_EMRPOLYPOLYLINE16_set(const U_RECTL rclBounds, const uint32_t nPolys, const uint32_t *aPolyCounts,const uint32_t cpts, const U_POINT16 *points);
3599char *U_EMRPOLYPOLYGON16_set(const U_RECTL rclBounds, const uint32_t nPolys, const uint32_t *aPolyCounts,const uint32_t cpts, const U_POINT16 *points);
3600char *U_EMRPOLYDRAW16_set(const U_RECTL rclBounds,const U_NUM_POINT16 cpts, const U_POINT16 *aptl, const uint8_t *abTypes);
3601char *U_EMRCREATEMONOBRUSH_set(const uint32_t ihBrush, const uint32_t iUsage,
3602 const PU_BITMAPINFO Bmi, const uint32_t cbPx, const char *Px);
3603char *U_EMRCREATEDIBPATTERNBRUSHPT_set(const uint32_t ihBrush, const uint32_t iUsage,
3604 const PU_BITMAPINFO Bmi, const uint32_t cbPx, const char *Px);
3605char *U_EMREXTCREATEPEN_set(const uint32_t ihPen, const PU_BITMAPINFO Bmi, const uint32_t cbPx, char *Px, const PU_EXTLOGPEN elp );
3606// U_EMRPOLYTEXTOUTA_set 96 NOT IMPLEMENTED, denigrated after Windows NT
3607// U_EMRPOLYTEXTOUTW_set 97 NOT IMPLEMENTED, denigrated after Windows NT
3608char *U_EMRSETICMMODE_set(const uint32_t iMode);
3609char *U_EMRCREATECOLORSPACE_set(const uint32_t ihCS, const U_LOGCOLORSPACEA lcs);
3610char *U_EMRSETCOLORSPACE_set(const uint32_t ihCS );
3611char *U_EMRDELETECOLORSPACE_set(const uint32_t ihCS);
3612// U_EMRGLSRECORD_set 102 Not implemented
3613// U_EMRGLSBOUNDEDRECORD_set 103 Not implemented
3614char *U_EMRPIXELFORMAT_set(const U_PIXELFORMATDESCRIPTOR pfd);
3615char *U_EMRSMALLTEXTOUT_set(const U_POINTL Dest, const U_NUM_STR cChars, const uint32_t fuOptions, const uint32_t iGraphicsMode,
3616 const U_FLOAT exScale, const U_FLOAT eyScale, const U_RECTL rclBounds, const char *TextString);
3617// U_EMRDRAWESCAPE_set 105 Not implemented
3618// U_EMREXTESCAPE_set 106 Not implemented
3619// U_EMRUNDEF107_set 107 Not implemented
3620// U_EMRSMALLTEXTOUT_set 108
3621// U_EMRFORCEUFIMAPPING_set 109 Not implemented
3622// U_EMRNAMEDESCAPE_set 110 Not implemented
3623// U_EMRCOLORCORRECTPALETTE_set 111 Not implemented
3624// U_EMRSETICMPROFILEA_set 112 Not implemented
3625// U_EMRSETICMPROFILEW_set 113 Not implemented
3626
3627
3628char *U_EMRALPHABLEND_set(const U_RECTL rclBounds, const U_POINTL Dest, const U_POINTL cDest,
3629 const U_POINTL Src, const U_POINTL cSrc, const U_XFORM xformSrc,
3630 const U_COLORREF crBkColorSrc, const uint32_t iUsageSrc,
3631 const U_BLEND Blend,
3632 const PU_BITMAPINFO Bmi, const uint32_t cbPx, char *Px);
3633char *U_EMRSETLAYOUT_set(const uint32_t iMode);
3634char *U_EMRTRANSPARENTBLT_set(const U_RECTL rclBounds, const U_POINTL Dest, const U_POINTL cDest,
3635 const U_POINTL Src, const U_POINTL cSrc, const U_XFORM xformSrc,
3636 const U_COLORREF crBkColorSrc, const uint32_t iUsageSrc, const uint32_t TColor,
3637 const PU_BITMAPINFO Bmi, const uint32_t cbPx, char *Px);
3638// U_EMRUNDEF117_set 117 Not implemented
3639char *U_EMRGRADIENTFILL_set(const U_RECTL rclBounds, const U_NUM_TRIVERTEX nTriVert, const U_NUM_GRADOBJ nGradObj,
3640 const uint32_t ulMode, const PU_TRIVERTEX TriVert, const uint32_t *GradObj );
3641// U_EMRSETLINKEDUFIS_set 119 Not implemented
3642// U_EMRSETTEXTJUSTIFICATION_set 120 Not implemented (denigrated)
3643// U_EMRCOLORMATCHTOTARGETW_set 121 Not implemented
3644char *U_EMRCREATECOLORSPACEW_set(const uint32_t ihCS, const U_LOGCOLORSPACEW lcs, const uint32_t dwFlags,
3645 const U_CBDATA cbData, const uint8_t *Data);
3646
3648
3649#ifdef __cplusplus
3650}
3651#endif
3652
3653#endif /* _UEMF_ */
const double w
Definition conic-4.cpp:19
Geom::Point start
Geom::Point end
int mode
int stride
int size
int buf
unsigned long weight
Definition quantize.cpp:37
void invert(const double v[16], double alpha[16])
The various create functions need a place to put their handles, these are stored in the table below.
Definition uemf.h:3327
uint32_t top
Highest slot occupied (currently)
Definition uemf.h:3333
uint32_t * table
Array Buffer for constructing the EMF in memory.
Definition uemf.h:3328
size_t chunk
Number to add if a realloc is required.
Definition uemf.h:3331
size_t allocated
Slots in the buffer.
Definition uemf.h:3330
uint32_t * stack
handles are either on the stack or in the table
Definition uemf.h:3329
uint32_t sptr
Pointer to next available handle in the stack.
Definition uemf.h:3332
uint32_t peak
Highest slot occupied (ever)
Definition uemf.h:3334
Storage for keeping track of properties of the growing EMF file as records are added.
Definition uemf.h:3306
uint16_t ignore
size padding,not used
Definition uemf.h:3311
char * buf
Buffer for constructing the EMF in memory.
Definition uemf.h:3314
uint32_t records
Number of records already contained.
Definition uemf.h:3310
size_t allocated
Size of the buffer.
Definition uemf.h:3308
uint32_t PalEntries
Number of PalEntries (set from U_EMREOF)
Definition uemf.h:3312
size_t used
Amount consumed.
Definition uemf.h:3309
FILE * fp
Open file.
Definition uemf.h:3307
uint32_t chunk
Number of bytes to add when more space is needed.
Definition uemf.h:3313
For U_POINT28_4 x and y fields.
Definition uemf.h:1653
signed IntValue
Signed integral bit field.
Definition uemf.h:1654
unsigned FracValue
Unsigned integral bit field.
Definition uemf.h:1655
WMF manual 2.2.2.3.
Definition uemf.h:422
uint16_t biBitCount
BitCount Enumeration (determines number of RBG colors)
Definition uemf.h:431
uint32_t biSize
Structure size in bytes.
Definition uemf.h:423
uint32_t biClrImportant
Number of bmciColors needed (0 means all).
Definition uemf.h:437
int32_t biHeight
Bitmap height in pixels, may be negative.
Definition uemf.h:425
int32_t biWidth
Bitmap width in pixels.
Definition uemf.h:424
uint32_t biCompression
BI_Compression Enumeration.
Definition uemf.h:432
uint16_t biPlanes
Planes (must be 1)
Definition uemf.h:430
uint32_t biSizeImage
Image size in bytes or 0 = "default size (calculated from geometry?)".
Definition uemf.h:433
int32_t biXPelsPerMeter
X Resolution in pixels/meter.
Definition uemf.h:434
U_NUM_RGBQUAD biClrUsed
Number of bmciColors in U_BITMAPINFO/U_BITMAPCOREINFO that are used by the bitmap.
Definition uemf.h:436
int32_t biYPelsPerMeter
Y Resolution in pixels/meter.
Definition uemf.h:435
For U_EMR_* OffBmi* fields.
Definition uemf.h:2045
U_BITMAPINFOHEADER bmiHeader
Geometry and pixel properties.
Definition uemf.h:2046
U_EMRALPHABLEND Blend field.
Definition uemf.h:2057
uint8_t Flags
Must be 0.
Definition uemf.h:2059
uint8_t Op
Blend Enumeration.
Definition uemf.h:2061
uint8_t Global
Alpha for whole thing if Op is U_AC_SRC_GLOBAL (AKA U_AC_SRC_GLOBAL)
Definition uemf.h:2060
uint8_t Operation
Must be 0.
Definition uemf.h:2058
WMF manual 2.2.2.7.
Definition uemf.h:461
U_CIEXYZ ciexyzRed
CIE XYZ coord of red endpoint of colorspace.
Definition uemf.h:462
U_CIEXYZ ciexyzBlue
CIE XYZ coord of blue endpoint of colorspace.
Definition uemf.h:464
U_CIEXYZ ciexyzGreen
CIE XYZ coord of green endpoint of colorspace.
Definition uemf.h:463
WMF manual 2.2.2.6.
Definition uemf.h:447
int32_t ciexyzX
CIE color space X component.
Definition uemf.h:448
int32_t ciexyzZ
CIE color space Z component.
Definition uemf.h:450
int32_t ciexyzY
CIE color space Y component.
Definition uemf.h:449
For U_EMRSETOLORADJUSTMENT ColorAdjustment field.
Definition uemf.h:1666
uint16_t caFlags
ColorAdjustment Enumeration.
Definition uemf.h:1668
uint16_t caReferenceWhite
Values more than this are white (range:6000:10000)
Definition uemf.h:1674
int16_t caBrightness
Brightness adjustment (range:-100:100, 0 is no correction)
Definition uemf.h:1676
int16_t caContrast
Contrast adjustment (range:-100:100, 0 is no correction)
Definition uemf.h:1675
uint16_t caIlluminantIndex
Illuminant Enumeration.
Definition uemf.h:1669
uint16_t caRedGamma
Red Gamma correction (range:2500:65000, 10000 is no correction)
Definition uemf.h:1670
int16_t caRedGreenTint
Tine adjustment (range:-100:100, 0 is no correction)
Definition uemf.h:1678
uint16_t caBlueGamma
Blue Gamma correction (range:2500:65000, 10000 is no correction)
Definition uemf.h:1672
uint16_t caSize
Size of this structure in bytes.
Definition uemf.h:1667
uint16_t caGreenGamma
Green Gamma correction (range:2500:65000, 10000 is no correction)
Definition uemf.h:1671
uint16_t caReferenceBlack
Values less than this are black (range:0:4000)
Definition uemf.h:1673
int16_t caColorfulness
Colorfulness adjustment (range:-100:100, 0 is no correction)
Definition uemf.h:1677
WMF manual 2.2.2.8.
Definition uemf.h:474
uint8_t Red
Red color (0-255)
Definition uemf.h:475
uint8_t Reserved
Not used.
Definition uemf.h:478
uint8_t Blue
Blue color (0-255)
Definition uemf.h:477
uint8_t Green
Green color (0-255)
Definition uemf.h:476
EMF manual 2.2.3.
Definition uemf.h:1687
uint32_t Signature
Must be 0x08007664 (AKA: DV_SGNTR)
Definition uemf.h:1688
U_NUM_FNTAXES NumAxes
Number of elements in Values, 0-16.
Definition uemf.h:1689
EMF manual 2.3.1.1
Definition uemf.h:3200
U_EMR emr
U_EMR.
Definition uemf.h:3201
U_POINTL cSrc
Source W & H in logical units Record may include optional DIB bitmap.
Definition uemf.h:3214
U_POINTL cDest
Destination W & H in logical units.
Definition uemf.h:3204
U_OFFBITSSRC offBitsSrc
Offset in bytes to the bitmap (within bitmapbuffer)
Definition uemf.h:3212
U_XFORM xformSrc
Transform to apply to source.
Definition uemf.h:3207
U_BLEND Blend
Blend Function.
Definition uemf.h:3205
U_POINTL Src
Source UL corner in logical units.
Definition uemf.h:3206
U_RECTL rclBounds
Bounding rectangle in device units.
Definition uemf.h:3202
uint32_t iUsageSrc
DIBcolors Enumeration.
Definition uemf.h:3209
U_OFFBMISRC offBmiSrc
Offset in bytes to U_BITMAPINFO (within bitmapbuffer)
Definition uemf.h:3210
U_COLORREF crBkColorSrc
Background color.
Definition uemf.h:3208
U_CBBITS cbBitsSrc
Size in bytes of bitmap.
Definition uemf.h:3213
U_CBBMISRC cbBmiSrc
Size in bytes of U_BITMAPINFO.
Definition uemf.h:3211
U_POINTL Dest
Destination UL corner in logical units.
Definition uemf.h:3203
EMF manual 2.3.5.1
Definition uemf.h:2486
uint32_t nRadius
Radius in logical units.
Definition uemf.h:2489
U_FLOAT eSweepAngle
Sweep angle in degrees.
Definition uemf.h:2491
U_FLOAT eStartAngle
Starting angle in degrees (counter clockwise from x axis)
Definition uemf.h:2490
U_EMR emr
U_EMR.
Definition uemf.h:2487
U_POINTL ptlCenter
Center in logical units.
Definition uemf.h:2488
EMF manual 2.3.5.2
Definition uemf.h:2523
U_POINTL ptlEnd
End point in logical units.
Definition uemf.h:2527
U_EMR emr
U_EMR.
Definition uemf.h:2524
U_POINTL ptlStart
Start point in logical units.
Definition uemf.h:2526
U_RECTL rclBox
bounding rectangle in logical units
Definition uemf.h:2525
EMF manual 2.3.1.2
Definition uemf.h:2771
U_OFFBITSSRC offBitsSrc
Offset in bytes to the bitmap (within bitmapbuffer)
Definition uemf.h:2783
U_OFFBMISRC offBmiSrc
Offset in bytes to U_BITMAPINFO (within bitmapbuffer)
Definition uemf.h:2781
U_POINTL Dest
Destination UL corner in logical units.
Definition uemf.h:2774
U_XFORM xformSrc
Source bitmap transform (world to page coordinates)
Definition uemf.h:2778
uint32_t dwRop
Ternary Raster Operation enumeration.
Definition uemf.h:2776
U_POINTL cDest
Destination width in logical units.
Definition uemf.h:2775
U_EMR emr
U_EMR.
Definition uemf.h:2772
U_CBBITS cbBitsSrc
Size in bytes of bitmap Record may include optional bitmapbuffer.
Definition uemf.h:2784
uint32_t iUsageSrc
DIBcolors Enumeration.
Definition uemf.h:2780
U_CBBMISRC cbBmiSrc
Size in bytes of U_BITMAPINFO.
Definition uemf.h:2782
U_COLORREF crBkColorSrc
Source bitmap background color.
Definition uemf.h:2779
U_RECTL rclBounds
Bounding rectangle in device units.
Definition uemf.h:2773
U_POINTL Src
Source retangle UL corner in logical units.
Definition uemf.h:2777
EMF manual 2.3.11.1
Definition uemf.h:3272
uint32_t dwFlags
ColorMatchToTarget Enumeration.
Definition uemf.h:3275
U_CBDATA cbData
Number of bytes of the target profile.
Definition uemf.h:3277
uint32_t dwAction
ColorSpace Enumeration.
Definition uemf.h:3274
U_CBNAME cbName
Number of bytes in UTF16 name of the color profile.
Definition uemf.h:3276
EMF manual 2.3.3.2.
Definition uemf.h:2680
U_EMR emr
U_EMR.
Definition uemf.h:2681
U_CBDATA cbData
Number of bytes in comment.
Definition uemf.h:2682
uint32_t cIdent
Comment identifier, must be U_EMR_COMMENT_EMFPLUSRECORD.
Definition uemf.h:2683
EMF manual 2.3.3.4.
Definition uemf.h:2703
uint32_t cIdent
Comment identifier, must be U_EMR_COMMENT_PUBLIC.
Definition uemf.h:2706
uint32_t pcIdent
Public Comment Identifier, from EMRComment Enumeration.
Definition uemf.h:2707
U_EMR emr
U_EMR.
Definition uemf.h:2704
U_CBDATA cbData
Number of bytes in comment.
Definition uemf.h:2705
EMF manual 2.3.3.3.
Definition uemf.h:2691
U_CBDATA cbData
Number of bytes in comment.
Definition uemf.h:2693
uint32_t esrIdent
EMFSpoolRecordIdentifier, may be U_EMR_COMMENT_SPOOLFONTDEF.
Definition uemf.h:2695
uint32_t cIdent
Comment identifier, must be U_EMR_COMMENT_SPOOL.
Definition uemf.h:2694
U_EMR emr
U_EMR.
Definition uemf.h:2692
EMF manual 2.3.3.1.
Definition uemf.h:2669
U_EMR emr
U_EMR.
Definition uemf.h:2670
U_CBDATA cbData
Number of bytes in comment.
Definition uemf.h:2671
EMF manual 2.3.7.1
Definition uemf.h:2473
uint32_t ihBrush
Index to place object in EMF object table (this entry must not yet exist)
Definition uemf.h:2475
U_LOGBRUSH lb
Brush properties.
Definition uemf.h:2476
EMF manual 2.3.7.3
Definition uemf.h:3286
U_LOGCOLORSPACEW lcs
Description of the color profile.
Definition uemf.h:3289
uint32_t dwFlags
If low bit set Data is present.
Definition uemf.h:3290
U_EMR emr
U_EMR.
Definition uemf.h:3287
U_CBDATA cbData
Number of bytes of theData field.
Definition uemf.h:3291
uint32_t ihCS
Index of the logical color space object in the EMF object table.
Definition uemf.h:3288
EMF manual 2.3.7.2
Definition uemf.h:3076
U_EMR emr
U_EMR.
Definition uemf.h:3077
uint32_t ihCS
Index to place object in EMF object table (this entry must not yet exist)
Definition uemf.h:3078
U_LOGCOLORSPACEA lcs
ColorSpace parameters.
Definition uemf.h:3079
EMF manual 2.3.7.4
Definition uemf.h:3024
U_OFFBITS offBits
Offset in bytes to the DIB bitmap data (within DIB bitmapbuffer.
Definition uemf.h:3030
uint32_t ihBrush
Index to place object in EMF object table (this entry must not yet exist)
Definition uemf.h:3026
U_OFFBMI offBmi
Offset in bytes to U_BITMAPINFO (within DIB bitmapbuffer)
Definition uemf.h:3028
uint32_t iUsage
DIBcolors Enumeration.
Definition uemf.h:3027
U_CBBITS cbBits
Size in bytes of DIB bitmap Record may include optional DIB bitmapbuffer.
Definition uemf.h:3031
U_CBBMI cbBmi
Size in bytes of U_BITMAPINFO.
Definition uemf.h:3029
EMF manual 2.3.7.5
Definition uemf.h:3008
U_CBBITS cbBits
Size in bytes of DIB bitmap Record may include optional DIB bitmapbuffer.
Definition uemf.h:3015
U_CBBMI cbBmi
Size in bytes of U_BITMAPINFO.
Definition uemf.h:3013
uint32_t ihBrush
Index to place object in EMF object table (this entry must not yet exist)
Definition uemf.h:3010
U_OFFBMI offBmi
Offset in bytes to U_BITMAPINFO (within DIBbitmapbuffer)
Definition uemf.h:3012
U_OFFBITS offBits
Offset in bytes to the DIB bitmap data (within DIBbitmapbuffer.
Definition uemf.h:3014
uint32_t iUsage
DIBcolors Enumeration.
Definition uemf.h:3011
U_EMR emr
U_EMR.
Definition uemf.h:3009
EMF manual 2.3.7.6
Definition uemf.h:2554
U_EMR emr
U_EMR.
Definition uemf.h:2555
uint32_t ihPal
Index to place object in EMF object table (this entry must not yet exist)
Definition uemf.h:2556
U_LOGPALETTE lgpl
Palette properties (variable size)
Definition uemf.h:2557
EMF manual 2.3.7.7
Definition uemf.h:2462
U_LOGPEN lopn
Pen properties.
Definition uemf.h:2465
U_EMR emr
U_EMR.
Definition uemf.h:2463
uint32_t ihPen
Index to place object in EMF object table (this entry must not yet exist)
Definition uemf.h:2464
EMF manual 2.3.8.2
Definition uemf.h:3087
uint32_t ihCS
Index of object in EMF object table.
Definition uemf.h:3089
U_EMR emr
U_EMR.
Definition uemf.h:3088
EMF manual 2.3.8.3
Definition uemf.h:2449
U_EMR emr
U_EMR.
Definition uemf.h:2450
uint32_t ihObject
Number of a stock or created object.
Definition uemf.h:2451
EMF manual 2.3.6.1
Definition uemf.h:3133
U_EMR emr
U_EMR.
Definition uemf.h:3134
U_CBDATA cjIn
Number of bytes to send to printer driver.
Definition uemf.h:3135
EMF manual 2.3.5.5
Definition uemf.h:2499
U_RECTL rclBox
bounding rectangle in logical units
Definition uemf.h:2501
U_EMR emr
U_EMR.
Definition uemf.h:2500
EMF manual 3.2.4.1
Definition uemf.h:2237
U_EMR emr
U_EMR.
Definition uemf.h:2238
U_CBPLENTRIES cbPalEntries
Number of palette entries.
Definition uemf.h:2239
U_OFFPLENTRIES offPalEntries
Offset in bytes to array of palette entries.
Definition uemf.h:2240
EMF manual 2.3.2.1
Definition uemf.h:2387
U_RECTL rclClip
Clipping Region.
Definition uemf.h:2389
U_EMR emr
U_EMR.
Definition uemf.h:2388
EMF manual 2.3.7.8
Definition uemf.h:2913
U_LOGFONT_PANOSE elfw
Font parameters, either U_LOGFONT or U_LOGFONT_PANOSE, the latter is bigger so use that type here.
Definition uemf.h:2916
uint32_t ihFont
Index of the font in the EMF object table.
Definition uemf.h:2915
EMF manual 2.3.7.9
Definition uemf.h:3040
U_CBBITS cbBits
Size in bytes of DIB bitmap.
Definition uemf.h:3046
U_OFFBITS offBits
Offset in bytes to the DIB bitmap data (within DIB bitmapbuffer.
Definition uemf.h:3045
uint32_t ihPen
Index to place object in EMF object table (this entry must not yet exist)
Definition uemf.h:3042
U_CBBMI cbBmi
Size in bytes of U_BITMAPINFO.
Definition uemf.h:3044
U_OFFBMI offBmi
Offset in bytes to U_BITMAPINFO (within DIB bitmapbuffer)
Definition uemf.h:3043
U_EXTLOGPEN elp
Pen parameters (Size is Variable!!!!) Record may include optional DIB bitmap.
Definition uemf.h:3047
U_EMR emr
U_EMR.
Definition uemf.h:3041
EMF manual 2.3.6.2
Definition uemf.h:3144
U_CBDATA cjIn
Number of bytes to send to printer driver.
Definition uemf.h:3146
U_EMR emr
U_EMR.
Definition uemf.h:3145
EMF manual 2.3.5.6
Definition uemf.h:2591
U_POINTL ptlStart
Start point in logical units.
Definition uemf.h:2593
uint32_t iMode
FloodFill Enumeration.
Definition uemf.h:2595
U_COLORREF crColor
Color to fill with.
Definition uemf.h:2594
U_EMR emr
U_EMR.
Definition uemf.h:2592
EMF manual 2.3.2.2
Definition uemf.h:2759
U_EMR emr
U_EMR.
Definition uemf.h:2760
uint32_t iMode
RegionMode Enumeration
Definition uemf.h:2762
U_CBRGNDATA cbRgnData
Size in bytes of Region data.
Definition uemf.h:2761
EMF manual 2.3.5.7
Definition uemf.h:2933
uint32_t iGraphicsMode
GraphicsMode Enumeration.
Definition uemf.h:2936
U_EMR emr
U_EMR.
Definition uemf.h:2934
U_RECTL rclBounds
Bounding rectangle in device units.
Definition uemf.h:2935
U_EMRTEXT emrtext
Text parameters.
Definition uemf.h:2939
U_FLOAT eyScale
scale to 0.01 mm units ( only if iGraphicsMode & U_GM_COMPATIBLE)
Definition uemf.h:2938
U_FLOAT exScale
scale to 0.01 mm units ( only if iGraphicsMode & U_GM_COMPATIBLE)
Definition uemf.h:2937
EMF manual 2.3.5.9
Definition uemf.h:2647
U_RECTL rclBounds
Bounding rectangle in device units.
Definition uemf.h:2649
U_EMR emr
U_EMR.
Definition uemf.h:2648
EMF manual 2.3.5.10 followed by a variable number of U_RECTLs
Definition uemf.h:2717
U_CBRGNDATA cbRgnData
Size in bytes of Region data.
Definition uemf.h:2720
U_EMR emr
U_EMR.
Definition uemf.h:2718
uint32_t ihBrush
Index of a Brush object in the EMF object table.
Definition uemf.h:2721
U_RECTL rclBounds
Bounding rectangle in device units.
Definition uemf.h:2719
For U_EMR_COMMENT_MULTIFORMATS record, where an array of these is used.
Definition uemf.h:1700
uint32_t signature
FormatSignature Enumeration.
Definition uemf.h:1701
uint32_t nVersion
Must be 1 if signature is EPS, else ignored.
Definition uemf.h:1702
U_CBDATA cbData
Data size in bytes.
Definition uemf.h:1703
U_OFFDATA offData
Offset in bytes to the Data from the start of the RECORD.
Definition uemf.h:1704
EMF manual 2.3.5.11
Definition uemf.h:2730
U_CBRGNDATA cbRgnData
Size in bytes of Region data.
Definition uemf.h:2733
U_EMR emr
U_EMR.
Definition uemf.h:2731
U_SIZEL szlStroke
W & H of Brush stroke.
Definition uemf.h:2735
U_RECTL rclBounds
Bounding rectangle in device units.
Definition uemf.h:2732
uint32_t ihBrush
Index of a Brush object in the EMF object table.
Definition uemf.h:2734
Generic EMR record with two 32 bit values.
Definition uemf.h:2093
U_PAIR pair
pair of 32 bit values
Definition uemf.h:2095
U_EMR emr
U_EMR.
Definition uemf.h:2094
EMF manual 2.3.9.1
Definition uemf.h:3111
U_EMR emr
U_EMR.
Definition uemf.h:3112
U_RECTL rclBounds
Bounding rectangle in device units.
Definition uemf.h:3113
U_CBDATA cbData
Size of OpenGL data in bytes.
Definition uemf.h:3114
EMF manual 2.3.9.2
Definition uemf.h:3100
U_EMR emr
U_EMR.
Definition uemf.h:3101
U_CBDATA cbData
Size of OpenGL data in bytes.
Definition uemf.h:3102
EMF manual 2.3.5.12
Definition uemf.h:3254
U_NUM_GRADOBJ nGradObj
Number of gradient triangle/rectangle objects.
Definition uemf.h:3258
uint32_t ulMode
Gradientfill Enumeration (determines Triangle/Rectangle)
Definition uemf.h:3259
U_NUM_TRIVERTEX nTriVert
Number of TriVertex objects.
Definition uemf.h:3257
U_EMR emr
U_EMR.
Definition uemf.h:3255
U_RECTL rclBounds
Bounding rectangle in device units.
Definition uemf.h:3256
The first U_ENHMETARECORD record in the metafile.
Definition uemf.h:2127
uint32_t nVersion
Must be U_ENHMETA_VERSION (0x00010000)
Definition uemf.h:2132
U_SIZEL szlMicrometers
Fields for winver >= win98.
Definition uemf.h:2147
uint32_t offDescription
Offset in bytes to optional UTF-16BE string Description field.
Definition uemf.h:2138
uint32_t nPalEntries
Number of Palette entries (in U_EMR_EOF record).
Definition uemf.h:2139
uint32_t nDescription
Characters in the Description field, 0 if no description
Definition uemf.h:2137
U_OFFPXLFMT offPixelFormat
Offset in bytes to optional PixelFormatDescriptor from the start of the RECORD, 0 if no PFD.
Definition uemf.h:2144
U_EMR emr
U_EMR
Definition uemf.h:2128
U_SIZEL szlMillimeters
Reference device size in 0.01 mm.
Definition uemf.h:2141
U_SIZEL szlDevice
Reference device size in pixels
Definition uemf.h:2140
uint16_t nHandles
Number of graphics objects used in the Metafile
Definition uemf.h:2135
uint32_t nBytes
Length in bytes of the Metafile
Definition uemf.h:2133
U_RECTL rclFrame
Bounding rectangle in 0.01 mm units.
Definition uemf.h:2130
uint32_t nRecords
Records in the Metafile
Definition uemf.h:2134
uint32_t bOpenGL
nonZero if OpenGL commands are included
Definition uemf.h:2145
U_RECTL rclBounds
Bounding rectangle in device units.
Definition uemf.h:2129
uint16_t sReserved
Must be 0
Definition uemf.h:2136
uint32_t dSignature
FormatSignature Enumeration (must be U_ENHMETA_SIGNATURE)
Definition uemf.h:2131
U_CBPXLFMT cbPixelFormat
Fields for winver >= win95.
Definition uemf.h:2143
EMF manual 2.3.11.3
Definition uemf.h:2744
U_RECTL rclBounds
Bounding rectangle in device units.
Definition uemf.h:2746
U_EMR emr
U_EMR.
Definition uemf.h:2745
U_CBRGNDATA cbRgnData
Size in bytes of Region data.
Definition uemf.h:2747
EMF manual 2.3.1.3
Definition uemf.h:2816
U_OFFBMISRC offBmiSrc
Offset in bytes to U_BITMAPINFO (within srcbitmapbuffer)
Definition uemf.h:2826
U_POINTL Src
Source UL corner in logical units.
Definition uemf.h:2822
uint32_t iUsageSrc
DIBcolors Enumeration.
Definition uemf.h:2825
U_CBBITSMSK cbBitsMask
Size in bytes of bitmap Record may include optional Source and mask bitmapbuffers.
Definition uemf.h:2835
U_POINTL Dest
Destination UL corner in logical units.
Definition uemf.h:2819
U_CBBMIMSK cbBmiMask
Size in bytes of U_BITMAPINFO.
Definition uemf.h:2833
U_OFFBITSMSK offBitsMask
Offset in bytes to the mask bitmap (within maskbitmapbuffer)
Definition uemf.h:2834
U_XFORM xformSrc
Transform to apply to source.
Definition uemf.h:2823
uint32_t iUsageMask
DIBcolors Enumeration.
Definition uemf.h:2831
uint32_t dwRop
Ternary Raster Operation enumeration.
Definition uemf.h:2821
U_POINTL cDest
Destination width in logical units.
Definition uemf.h:2820
U_RECTL rclBounds
Bounding rectangle in device units.
Definition uemf.h:2818
U_OFFBITSSRC offBitsSrc
Offset in bytes to the src bitmap (within srcbitmapbuffer)
Definition uemf.h:2828
U_OFFBMIMSK offBmiMask
Offset in bytes to U_BITMAPINFO (within maskbitmapbuffer)
Definition uemf.h:2832
U_POINTL Mask
Mask UL corner in logical units.
Definition uemf.h:2830
U_CBBITS cbBitsSrc
Size in bytes of src bitmap.
Definition uemf.h:2829
U_CBBMISRC cbBmiSrc
Size in bytes of U_BITMAPINFO.
Definition uemf.h:2827
U_COLORREF crBkColorSrc
Background color.
Definition uemf.h:2824
U_EMR emr
U_EMR.
Definition uemf.h:2817
EMF manual 2.3.12.1
Definition uemf.h:2438
U_XFORM xform
Transform.
Definition uemf.h:2440
uint32_t iMode
ModifyWorldTransformMode Enumeration.
Definition uemf.h:2441
EMF manual 2.3.11.4 EMF manual 2.3.5.13
Definition uemf.h:2340
U_EMR emr
U_EMR.
Definition uemf.h:2341
U_POINTL ptl
Point coordinates.
Definition uemf.h:2342
EMF manual 2.3.6.3
Definition uemf.h:3182
U_CBDATA cbDriver
Number of bytes in driver name (note, BYTES, not CHARACTERS)
Definition uemf.h:3184
U_CBDATA cbData
Number of bytes in data.
Definition uemf.h:3185
U_EMR emr
U_EMR
Definition uemf.h:3183
EMF manual 2.3.2.4
Definition uemf.h:2328
U_EMR emr
U_EMR
Definition uemf.h:2329
U_POINTL ptlOffset
Clipping region.
Definition uemf.h:2330
EMF manual 2.3.11.5
Definition uemf.h:3123
U_EMR emr
U_EMR.
Definition uemf.h:3124
U_PIXELFORMATDESCRIPTOR pfd
PixelFormatDescriptor.
Definition uemf.h:3125
EMF manual 2.3.1.4
Definition uemf.h:2844
U_POINTL Mask
Mask UL corner in logical units.
Definition uemf.h:2857
U_EMR emr
U_EMR.
Definition uemf.h:2845
U_POINTL Src
Source UL corner in logical units.
Definition uemf.h:2848
U_OFFBMISRC offBmiSrc
Offset in bytes to U_BITMAPINFO (within srcbitmapbuffer)
Definition uemf.h:2853
U_RECTL rclBounds
Bounding rectangle in device units.
Definition uemf.h:2846
U_OFFBITSSRC offBitsSrc
Offset in bytes to the src bitmap (within srcbitmapbuffer)
Definition uemf.h:2855
U_OFFBITSMSK offBitsMask
Offset in bytes to the mask bitmap (within maskbitmapbuffer)
Definition uemf.h:2861
U_CBBMISRC cbBmiSrc
Size in bytes of U_BITMAPINFO.
Definition uemf.h:2854
U_CBBITSMSK cbBitsMask
Size in bytes of bitmap Record may include optional Source and mask bitmapbuffers.
Definition uemf.h:2862
uint32_t iUsageMask
DIBcolors Enumeration.
Definition uemf.h:2858
uint32_t iUsageSrc
DIBcolors Enumeration.
Definition uemf.h:2852
U_OFFBMIMSK offBmiMask
Offset in bytes to U_BITMAPINFO (within maskbitmapbuffer)
Definition uemf.h:2859
U_POINTL cSrc
Src W & H in logical units.
Definition uemf.h:2849
U_CBBMIMSK cbBmiMask
Size in bytes of U_BITMAPINFO.
Definition uemf.h:2860
U_XFORM xformSrc
Transform to apply to source.
Definition uemf.h:2850
U_CBBITS cbBitsSrc
Size in bytes of src bitmap.
Definition uemf.h:2856
U_COLORREF crBkColorSrc
Background color.
Definition uemf.h:2851
EMF manual 2.3.5.17
Definition uemf.h:2950
U_RECTL rclBounds
Bounding rectangle in device units.
Definition uemf.h:2952
U_NUM_POINT16 cpts
Number of POINT16 in array.
Definition uemf.h:2953
U_EMR emr
U_EMR.
Definition uemf.h:2951
EMF manual 2.3.5.16.
Definition uemf.h:2156
U_NUM_POINTL cptl
Number of points to draw.
Definition uemf.h:2159
U_EMR emr
U_EMR.
Definition uemf.h:2157
U_RECTL rclBounds
bounding rectangle in device units
Definition uemf.h:2158
EMF manual 2.3.5.21
Definition uemf.h:2996
U_EMR emr
U_EMR.
Definition uemf.h:2997
U_RECTL rclBounds
Bounding rectangle in device units.
Definition uemf.h:2998
U_NUM_POINT16 cpts
Total number of points (over all poly)
Definition uemf.h:2999
EMF manual 2.3.5.20
Definition uemf.h:2610
U_EMR emr
U_EMR.
Definition uemf.h:2611
U_NUM_POINTL cptl
Number of U_POINTL objects.
Definition uemf.h:2613
U_RECTL rclBounds
Bounding rectangle in device units.
Definition uemf.h:2612
EMF manual 2.3.5.31
Definition uemf.h:2976
U_NUM_POINT16 cpts
Total number of points (over all poly)
Definition uemf.h:2980
U_RECTL rclBounds
Bounding rectangle in device units.
Definition uemf.h:2978
U_NUM_POLYCOUNTS nPolys
Number of elements in aPolyCounts.
Definition uemf.h:2979
U_EMR emr
U_EMR.
Definition uemf.h:2977
EMF manual 2.3.5.30.
Definition uemf.h:2183
U_RECTL rclBounds
bounding rectangle in device units
Definition uemf.h:2185
U_EMR emr
U_EMR
Definition uemf.h:2184
U_NUM_POINTL cptl
Total number of points (over all poly)
Definition uemf.h:2187
U_NUM_POLYCOUNTS nPolys
Number of elements in aPolyCounts.
Definition uemf.h:2186
EMF manual 2.3.5.32
Definition uemf.h:3056
U_FLOAT exScale
scale to 0.01 mm units ( only if iGraphicsMode & U_GM_COMPATIBLE)
Definition uemf.h:3060
U_RECTL rclBounds
Bounding rectangle in device units.
Definition uemf.h:3058
U_EMR emr
U_EMR.
Definition uemf.h:3057
U_FLOAT eyScale
scale to 0.01 mm units ( only if iGraphicsMode & U_GM_COMPATIBLE)
Definition uemf.h:3061
U_NUM_EMRTEXT cStrings
Number of U_EMRTEXT in array.
Definition uemf.h:3062
uint32_t iGraphicsMode
GraphicsMode Enumeration.
Definition uemf.h:3059
EMF manual 2.3.8.4
Definition uemf.h:2578
uint32_t cEntries
Number to expand or truncate the Palette entry list to.
Definition uemf.h:2581
uint32_t ihPal
Index of a Palette object in the EMF object table.
Definition uemf.h:2580
U_EMR emr
U_EMR.
Definition uemf.h:2579
EMF manual 2.3.11.6
Definition uemf.h:2418
int32_t iRelative
DC to restore. -1 is preceding.
Definition uemf.h:2420
U_EMR emr
U_EMR.
Definition uemf.h:2419
EMF manual 2.3.5.35
Definition uemf.h:2512
U_RECTL rclBox
bounding rectangle in logical units
Definition uemf.h:2514
U_SIZEL szlCorner
W & H in logical units of ellipse used to round corner.
Definition uemf.h:2515
U_EMR emr
U_EMR.
Definition uemf.h:2513
EMF manual 2.3.11.7
Definition uemf.h:2400
int32_t yNum
Vertical multiplier (!=0)
Definition uemf.h:2404
int32_t xDenom
Horizontal divisor (!=0)
Definition uemf.h:2403
U_EMR emr
U_EMR.
Definition uemf.h:2401
int32_t yDenom
Vertical divisor (!=0)
Definition uemf.h:2405
int32_t xNum
Horizontal multiplier (!=0)
Definition uemf.h:2402
EMF manual 2.3.8.6
Definition uemf.h:2544
U_EMR emr
U_EMR.
Definition uemf.h:2545
uint32_t ihPal
Index of a Palette object in the EMF object table.
Definition uemf.h:2546
EMF manual 2.3.11.9
Definition uemf.h:2622
U_EMR emr
U_EMR.
Definition uemf.h:2623
uint32_t iArcDirection
ArcDirection Enumeration.
Definition uemf.h:2624
EMF manual 2.3.11.13
Definition uemf.h:2305
U_EMR emr
U_EMR.
Definition uemf.h:2306
U_COLORADJUSTMENT ColorAdjustment
Color Adjustment.
Definition uemf.h:2307
EMF manual 2.3.1.5
Definition uemf.h:2871
U_CBBITS cbBitsSrc
Size in bytes of bitmap.
Definition uemf.h:2880
U_OFFBMISRC offBmiSrc
Offset in bytes to U_BITMAPINFO (within bitmapbuffer)
Definition uemf.h:2877
U_POINTL Src
Source LL corner in logical units.
Definition uemf.h:2875
U_POINTL Dest
Destination UL corner in logical units.
Definition uemf.h:2874
uint32_t iUsageSrc
DIBColors Enumeration.
Definition uemf.h:2881
U_EMR emr
U_EMR.
Definition uemf.h:2872
U_CBBMISRC cbBmiSrc
Size in bytes of U_BITMAPINFO.
Definition uemf.h:2878
U_POINTL cSrc
Src W & H in logical units.
Definition uemf.h:2876
U_OFFBITSSRC offBitsSrc
Offset in bytes to bitmap.
Definition uemf.h:2879
U_RECTL rclBounds
Bounding rectangle in device units.
Definition uemf.h:2873
uint32_t iStartScan
First scan line.
Definition uemf.h:2882
uint32_t cScans
Number of scan lines Record may includes optional bitmapbuffer.
Definition uemf.h:2883
EMF manual 2.3.11.19 MapMode enumeration.
Definition uemf.h:2270
uint32_t iMode
enumeration varies with type
Definition uemf.h:2272
U_EMR emr
U_EMR.
Definition uemf.h:2271
EMF manual 2.3.11.20.
Definition uemf.h:2259
uint32_t dwFlags
must be 1
Definition uemf.h:2261
U_EMR emr
U_EMR.
Definition uemf.h:2260
EMF manual 2.3.2.
Definition uemf.h:2353
U_EMR emr
U_EMR.
Definition uemf.h:2354
EMF manual 2.3.11.21
Definition uemf.h:2635
uint32_t eMiterLimit
Miter limit (max value of mitered length / line width)
Definition uemf.h:2637
U_EMR emr
U_EMR.
Definition uemf.h:2636
EMF manual 2.3.8.8
Definition uemf.h:2565
uint32_t iStart
First Palette entry in selected object to set.
Definition uemf.h:2568
U_EMR emr
U_EMR.
Definition uemf.h:2566
U_NUM_LOGPLTNTRY cEntries
Number of Palette entries in selected object to set.
Definition uemf.h:2569
uint32_t ihPal
Index of a Palette object in the EMF object table.
Definition uemf.h:2567
EMF manual 2.3.5.36
Definition uemf.h:2248
U_EMR emr
U_EMR.
Definition uemf.h:2249
U_COLORREF crColor
Pixel color.
Definition uemf.h:2251
U_POINTL ptlPixel
Pixel coordinates (logical)
Definition uemf.h:2250
EMF manual 2.3.11.26
Definition uemf.h:2315
U_EMR emr
U_EMR.
Definition uemf.h:2316
U_COLORREF crColor
Color.
Definition uemf.h:2317
EMF manual 2.3.11.30.
Definition uemf.h:2199
U_EMR emr
U_EMR.
Definition uemf.h:2200
U_SIZEL szlExtent
H & V extent in logical units.
Definition uemf.h:2201
EMF manual 2.3.11.31.
Definition uemf.h:2212
U_POINTL ptlOrigin
H & V origin in logical units.
Definition uemf.h:2214
U_EMR emr
U_EMR.
Definition uemf.h:2213
EMF manual 2.3.12.2
Definition uemf.h:2428
U_XFORM xform
Transform.
Definition uemf.h:2430
U_EMR emr
U_EMR.
Definition uemf.h:2429
EMF manual 2.3.5.37
Definition uemf.h:3157
U_EMR emr
U_EMR.
Definition uemf.h:3158
U_POINTL Dest
Where to draw the text.
Definition uemf.h:3159
U_FLOAT eyScale
scale on Y axis
Definition uemf.h:3164
uint32_t iGraphicsMode
GraphicsMode Enumeration.
Definition uemf.h:3162
U_NUM_STR cChars
Characters in TextString (not null terminated)
Definition uemf.h:3160
uint32_t fuOptions
ExtTextOutOptions Enumeration.
Definition uemf.h:3161
U_FLOAT exScale
scale on X axis
Definition uemf.h:3163
EMF manual 2.3.1.6
Definition uemf.h:2793
U_CBBITS cbBitsSrc
Size in bytes of bitmap.
Definition uemf.h:2806
U_OFFBMISRC offBmiSrc
Offset in bytes to U_BITMAPINFO (within bitmapbuffer)
Definition uemf.h:2803
U_RECTL rclBounds
Bounding rectangle in device units.
Definition uemf.h:2795
uint32_t dwRop
Ternary Raster Operation enumeration.
Definition uemf.h:2798
U_POINTL cSrc
Src W & H in logical units Record may include optional bitmapbuffer.
Definition uemf.h:2807
U_OFFBITSSRC offBitsSrc
Offset in bytes to the bitmap (within bitmapbuffer)
Definition uemf.h:2805
U_EMR emr
U_EMR.
Definition uemf.h:2794
uint32_t iUsageSrc
DIBcolors Enumeration.
Definition uemf.h:2802
U_COLORREF crBkColorSrc
Background color.
Definition uemf.h:2801
U_XFORM xformSrc
Transform to apply to source.
Definition uemf.h:2800
U_POINTL Src
Source UL corner in logical units.
Definition uemf.h:2799
U_CBBMISRC cbBmiSrc
Size in bytes of U_BITMAPINFO.
Definition uemf.h:2804
U_POINTL Dest
Destination UL corner in logical units.
Definition uemf.h:2796
U_POINTL cDest
Destination width in logical units.
Definition uemf.h:2797
EMF manual 2.3.1.7
Definition uemf.h:2892
uint32_t dwRop
Ternary Raster Operation enumeration.
Definition uemf.h:2903
U_POINTL cDest
Destination W & H in logical units Record may includes optional bitmapbuffer.
Definition uemf.h:2904
U_POINTL Src
Source UL corner in logical units.
Definition uemf.h:2896
U_POINTL Dest
Destination UL corner in logical units.
Definition uemf.h:2895
U_OFFBITSSRC offBitsSrc
Offset in bytes to bitmap.
Definition uemf.h:2900
U_RECTL rclBounds
Bounding rectangle in device units.
Definition uemf.h:2894
U_CBBITS cbBitsSrc
Size in bytes of bitmap.
Definition uemf.h:2901
U_CBBMISRC cbBmiSrc
Size in bytes of U_BITMAPINFO.
Definition uemf.h:2899
U_OFFBMISRC offBmiSrc
Offset in bytes to U_BITMAPINFO (within bitmapbuffer)
Definition uemf.h:2898
U_POINTL cSrc
Source W & H in logical units.
Definition uemf.h:2897
U_EMR emr
U_EMR
Definition uemf.h:2893
uint32_t iUsageSrc
DIBColors Enumeration.
Definition uemf.h:2902
For U_EMR[POLY]EXTTEXTOUT[A|W] emrtext field.
Definition uemf.h:1729
uint32_t fOptions
ExtTextOutOptions Enumeration.
Definition uemf.h:1733
U_POINTL ptlReference
String start coordinates.
Definition uemf.h:1730
U_OFFSTR offString
Offset in bytes to the string from the start of the RECORD.
Definition uemf.h:1732
U_NUM_STR nChars
Number of characters in the string.
Definition uemf.h:1731
EMF manual 2.3.1.8
Definition uemf.h:3225
U_CBBMISRC cbBmiSrc
Size in bytes of U_BITMAPINFO.
Definition uemf.h:3236
U_POINTL cSrc
Source W & H in logical units Record may includes optional bitmapbuffer.
Definition uemf.h:3239
U_XFORM xformSrc
Transform to apply to source.
Definition uemf.h:3232
U_POINTL cDest
Destination W & H in logical units.
Definition uemf.h:3229
U_CBBITS cbBitsSrc
Size in bytes of bitmap.
Definition uemf.h:3238
U_RECTL rclBounds
Bounding rectangle in device units.
Definition uemf.h:3227
U_OFFBITSSRC offBitsSrc
Offset in bytes to the bitmap (within bitmapbuffer)
Definition uemf.h:3237
U_OFFBMISRC offBmiSrc
Offset in bytes to U_BITMAPINFO (within bitmapbuffer)
Definition uemf.h:3235
uint32_t TColor
Bitmap color to be treated as transparent.
Definition uemf.h:3230
U_POINTL Dest
Destination UL corner in logical units.
Definition uemf.h:3228
U_POINTL Src
Source UL corner in logical units.
Definition uemf.h:3231
U_COLORREF crBkColorSrc
Background color.
Definition uemf.h:3233
U_EMR emr
U_EMR.
Definition uemf.h:3226
uint32_t iUsageSrc
DIBcolors Enumeration.
Definition uemf.h:3234
First two fields of all EMF records, First two fields of all EMF+ records (1 or more within an EMF co...
Definition uemf.h:2084
uint32_t iType
Type of EMR record.
Definition uemf.h:2085
uint32_t nSize
Size of entire record in bytes (multiple of 4).
Definition uemf.h:2086
General form of an EMF record.
Definition uemf.h:2071
uint32_t iType
Type of EMR record.
Definition uemf.h:2072
uint32_t nSize
Size of entire record in bytes (multiple of 4).
Definition uemf.h:2073
For embedding EPS in EMF via U_EMRFORMAT offData array in U_EMR_COMMENT_MULTIFORMATS.
Definition uemf.h:1753
uint32_t sizeData
Size in bytes of this object.
Definition uemf.h:1754
U_RECTL PostScriptData
Record may include optional clipping/opaque rectangle.
Definition uemf.h:1757
uint32_t version
Must be 1.
Definition uemf.h:1755
For U_EMREXTCREATEPEN lopn field.
Definition uemf.h:2026
U_NUM_STYLEENTRY elpNumEntries
Count of StyleEntry array.
Definition uemf.h:2032
uint32_t elpWidth
Width in logical units (elpPenStyle & U_PS_GEOMETRIC) or 1 (pixel)
Definition uemf.h:2028
uint32_t elpPenStyle
PenStyle Enumeration.
Definition uemf.h:2027
U_COLORREF elpColor
Pen color.
Definition uemf.h:2030
uint32_t elpBrushStyle
LB_Style Enumeration.
Definition uemf.h:2029
uint32_t elpHatch
HatchStyle Enumeration.
Definition uemf.h:2031
For U_EMRGRADIENTFILL GradObj field.
Definition uemf.h:1797
uint32_t Vertex3
Index of Vertex3 in an array of U_TRIVERTEX objects.
Definition uemf.h:1800
uint32_t Vertex1
Index of Vertex1 in an array of U_TRIVERTEX objects.
Definition uemf.h:1798
uint32_t Vertex2
Index of Vertex2 in an array of U_TRIVERTEX objects.
Definition uemf.h:1799
For U_EMRGRADIENTFILL GradObj field.
Definition uemf.h:1781
uint32_t UpperLeft
Index of UL corner in an array of U_TRIVERTEX objects.
Definition uemf.h:1782
uint32_t LowerRight
Index of LR corner in an array of U_TRIVERTEX objects.
Definition uemf.h:1783
WMF manual 2.2.2.11.
Definition uemf.h:500
U_LCS_GAMMA lcsGammaRed
Red Gamma.
Definition uemf.h:501
U_LCS_GAMMA lcsGammaBlue
Blue Gamma.
Definition uemf.h:503
U_LCS_GAMMA lcsGammaGreen
Green Gamma.
Definition uemf.h:502
WMF manual 2.2.2.11.
Definition uemf.h:487
unsigned fracPart
fraction part
Definition uemf.h:490
unsigned ignoreHi
not used
Definition uemf.h:488
unsigned ignoreLo
not used
Definition uemf.h:491
unsigned intPart
integer part
Definition uemf.h:489
For U_EMRCREATEBRUSHINDIRECT lb field.
Definition uemf.h:1813
U_COLORREF lbColor
Brush color.
Definition uemf.h:1815
uint32_t lbHatch
HatchStyle Enumeration.
Definition uemf.h:1816
uint32_t lbStyle
< In MS documentation this is LogBrushEx Object
Definition uemf.h:1814
WMF manual 2.2.2.11.
Definition uemf.h:512
uint32_t lcsSignature
must be U_LCS_SIGNATURE
Definition uemf.h:513
int32_t lcsIntent
LCS_Intent Enumeration.
Definition uemf.h:517
U_CIEXYZTRIPLE lcsEndpoints
CIE XYZ color space endpoints.
Definition uemf.h:518
uint32_t lcsVersion
must be U_LCS_VERSION
Definition uemf.h:514
uint32_t lcsSize
Size in bytes of this structure.
Definition uemf.h:515
U_LCS_GAMMARGB lcsGammaRGB
Gamma For RGB.
Definition uemf.h:519
int32_t lcsCSType
LCS_CSType Enumeration.
Definition uemf.h:516
WMF manual 2.2.2.12.
Definition uemf.h:529
uint32_t lcsSize
Size in bytes of this structure.
Definition uemf.h:532
int32_t lcsIntent
lcsIntent Enumeration
Definition uemf.h:534
uint32_t lcsVersion
must be U_LCS_VERSION
Definition uemf.h:531
int32_t lcsCSType
lcsCSType Enumeration
Definition uemf.h:533
U_LCS_GAMMARGB lcsGammaRGB
Gamma For RGB.
Definition uemf.h:536
U_CIEXYZTRIPLE lcsEndpoints
CIE XYZ color space endpoints.
Definition uemf.h:535
uint32_t lcsSignature
must be U_LCS_SIGNATURE
Definition uemf.h:530
For U_EMREXTCREATEFONTINDIRECTW elfw field.
Definition uemf.h:1876
uint32_t elfReserved
Must be 0, Ignore.
Definition uemf.h:1883
U_PANOSE elfPanose
Panose Object. If all zero, it is ignored.
Definition uemf.h:1886
uint32_t elfMatch
Ignore.
Definition uemf.h:1882
uint32_t elfVersion
Ignore.
Definition uemf.h:1880
uint32_t elfStyleSize
Font hinting starting at this point size, if 0, starts at Height.
Definition uemf.h:1881
U_LOGFONT elfLogFont
Basic font attributes.
Definition uemf.h:1877
uint16_t elfPadding
Ignore.
Definition uemf.h:1887
uint32_t elfCulture
Must be 0, Ignore.
Definition uemf.h:1885
For U_LOGFONT elfLogFont field.
Definition uemf.h:1827
uint8_t lfQuality
LF_Quality Enumeration.
Definition uemf.h:1839
uint8_t lfPitchAndFamily
LF_PitchAndFamily Enumeration.
Definition uemf.h:1840
uint8_t lfUnderline
LF_Underline Enumeration.
Definition uemf.h:1834
uint8_t lfClipPrecision
LF_ClipPrecision Enumeration.
Definition uemf.h:1838
uint8_t lfOutPrecision
LF_OutPrecision Enumeration.
Definition uemf.h:1837
uint8_t lfCharSet
LF_CharSet Enumeration.
Definition uemf.h:1836
int32_t lfWidth
Average Width in Logical units.
Definition uemf.h:1829
int32_t lfOrientation
Angle in 0.1 degrees between baseline and X axis.
Definition uemf.h:1831
uint8_t lfItalic
LF_Italic Enumeration.
Definition uemf.h:1833
uint8_t lfStrikeOut
LF_StrikeOut Enumeration.
Definition uemf.h:1835
int32_t lfEscapement
Angle in 0.1 degrees betweem escapement vector and X axis.
Definition uemf.h:1830
int32_t lfHeight
Height in Logical units.
Definition uemf.h:1828
int32_t lfWeight
LF_Weight Enumeration.
Definition uemf.h:1832
For U_EMRCREATEPALETTE lgpl field.
Definition uemf.h:1911
uint16_t palNumEntries
Number of U_LOGPLTNTRY objects.
Definition uemf.h:1913
uint16_t palVersion
Must be 0x0300 (AKA: U_LP_VERSION)
Definition uemf.h:1912
For U_EMRCREATEPEN lopn field.
Definition uemf.h:1926
uint32_t lopnStyle
PenStyle Enumeration.
Definition uemf.h:1927
U_POINT lopnWidth
Width of pen set by X, Y is ignored.
Definition uemf.h:1928
U_COLORREF lopnColor
Pen color value.
Definition uemf.h:1929
For U_LOGPALETTE palPalEntry field(s)
Definition uemf.h:1897
uint8_t peGreen
Palette entry Green Intensity.
Definition uemf.h:1900
uint8_t peBlue
Palette entry Blue Intensity.
Definition uemf.h:1901
uint8_t peReserved
Ignore.
Definition uemf.h:1898
uint8_t peRed
Palette entry Red Intensity.
Definition uemf.h:1899
2 x 2 matrix, used by xform_alt_set() function.
Definition uemf.h:3340
double M12
Matrix element 1,2.
Definition uemf.h:3342
double M11
Matrix element 1,1.
Definition uemf.h:3341
double M21
Matrix element 2,1.
Definition uemf.h:3343
double M22
Matrix element 2,2.
Definition uemf.h:3344
Any generic pair of floats.
Definition uemf.h:1637
float x
X value.
Definition uemf.h:1638
float y
Y value.
Definition uemf.h:1639
WMF manual 2.2.2.15.
Definition uemf.h:546
int32_t x
X value.
Definition uemf.h:547
int32_t y
Y value.
Definition uemf.h:548
For U_LOGFONT_PANOSE elfPanose field.
Definition uemf.h:1854
uint8_t bXHeight
XHeight Enumeration.
Definition uemf.h:1864
uint8_t bLetterform
Letterform Enumeration.
Definition uemf.h:1862
uint8_t bMidline
Midline Enumeration.
Definition uemf.h:1863
uint8_t bProportion
Proportion Enumeration.
Definition uemf.h:1858
uint8_t bStrokeVariation
StrokeVariation Enumeration.
Definition uemf.h:1860
uint8_t bSerifStyle
SerifType Enumeration.
Definition uemf.h:1856
uint8_t bWeight
Weight Enumeration.
Definition uemf.h:1857
uint8_t bContrast
Contrast Enumeration.
Definition uemf.h:1859
uint8_t bFamilyType
FamilyType Enumeration.
Definition uemf.h:1855
uint8_t bArmStyle
ArmStyle Enumeration.
Definition uemf.h:1861
For U_EMRPIXELFORMAT pfd field.
Definition uemf.h:1941
uint8_t cColorBits
RGBA: total bits per pixel.
Definition uemf.h:1946
uint8_t cAccumAlphaBits
Alpha accumulator buffer bitplanes.
Definition uemf.h:1959
uint32_t dwLayerMask
may be ignored
Definition uemf.h:1965
uint8_t cAccumGreenBits
Green accumulator buffer bitplanes.
Definition uemf.h:1957
uint8_t bReserved
Bits 0:3/4:7 are number of Overlay/Underlay planes.
Definition uemf.h:1964
uint16_t nVersion
must be 1
Definition uemf.h:1943
uint8_t cAccumBlueBits
Blue accumulator buffer bitplanes.
Definition uemf.h:1958
uint8_t cBlueShift
Blue shift to data bits.
Definition uemf.h:1952
uint32_t dwFlags
PFD_dwFlags Enumeration.
Definition uemf.h:1944
uint8_t cGreenShift
Green shift to data bits.
Definition uemf.h:1950
uint8_t cAlphaShift
Alpha shift to data bits.
Definition uemf.h:1954
uint8_t cDepthBits
Depth of Z-buffer.
Definition uemf.h:1960
uint8_t cStencilBits
Depth of stencil buffer.
Definition uemf.h:1961
uint8_t cGreenBits
Green bits per pixel.
Definition uemf.h:1949
uint32_t dwDamageMask
may be ignored
Definition uemf.h:1967
uint8_t cRedBits
Red bits per pixel.
Definition uemf.h:1947
uint8_t cAuxBuffers
Depth of auxilliary buffers (not supported)
Definition uemf.h:1962
uint8_t cBlueBits
Blue bits per pixel.
Definition uemf.h:1951
uint8_t cAccumRedBits
Red accumulator buffer bitplanes.
Definition uemf.h:1956
uint32_t dwVisibleMask
color or index of underlay plane
Definition uemf.h:1966
uint8_t cAccumBits
Accumulator buffer, total bitplanes.
Definition uemf.h:1955
uint8_t iPixelType
PFD_iPixelType Enumeration.
Definition uemf.h:1945
uint8_t iLayerType
PFD_iLayerType Enumeration, may be ignored.
Definition uemf.h:1963
uint16_t nSize
Structure size in bytes.
Definition uemf.h:1942
uint8_t cAlphaBits
Alpha bits per pixel.
Definition uemf.h:1953
uint8_t cRedShift
Red shift to data bits.
Definition uemf.h:1948
WMF manual 2.2.2.16.
Definition uemf.h:563
int16_t y
Y size (16 bit)
Definition uemf.h:565
int16_t x
X size (16 bit)
Definition uemf.h:564
For U_EPS_DATA Points field.
Definition uemf.h:1742
U_BITFIX28_4 x
X coordinate.
Definition uemf.h:1743
U_BITFIX28_4 y
Y coordinate.
Definition uemf.h:1744
WMF manual 2.2.2.19.
Definition uemf.h:576
int32_t left
left coordinate
Definition uemf.h:577
int32_t right
right coordinate
Definition uemf.h:579
int32_t bottom
bottom coordinate
Definition uemf.h:580
int32_t top
top coordinate
Definition uemf.h:578
WMF manual 2.2.2.20.
Definition uemf.h:592
uint8_t Red
Red color (0-255)
Definition uemf.h:595
uint8_t Green
Green color (0-255)
Definition uemf.h:594
uint8_t Reserved
Not used.
Definition uemf.h:596
uint8_t Blue
Blue color (0-255)
Definition uemf.h:593
For U_RGNDATA rdb field.
Definition uemf.h:1979
uint32_t iType
Must be 1 (AKA: U_RDH_RECTANGLES)
Definition uemf.h:1981
uint32_t dwSize
Size in bytes, must be 0x20 (AKA: U_RDH_OBJSIZE)
Definition uemf.h:1980
U_RECTL rclBounds
Region bounds.
Definition uemf.h:1984
U_NUM_RECTL nCount
Number of rectangles in region.
Definition uemf.h:1982
uint32_t nRgnSize
Size in bytes of rectangle buffer.
Definition uemf.h:1983
For U_EMRFILLRGN RgnData field(s)
Definition uemf.h:1995
U_RGNDATAHEADER rdh
Data description.
Definition uemf.h:1996
WMF manual 2.2.2.22.
Definition uemf.h:608
int32_t cy
Y size.
Definition uemf.h:610
int32_t cx
X size.
Definition uemf.h:609
For GRADIENT_[TRIANGLE|U_RECT].
Definition uemf.h:1766
uint16_t Green
Green component.
Definition uemf.h:1770
int32_t y
Y coord.
Definition uemf.h:1768
uint16_t Red
Red component.
Definition uemf.h:1769
int32_t x
X coord.
Definition uemf.h:1767
uint16_t Alpha
Alpha Transparency.
Definition uemf.h:1772
uint16_t Blue
Bule component.
Definition uemf.h:1771
For U_EMR[FILLRGN|STRETCHBLT|MASKBLT|PLGBLT] xformSrc field.
Definition uemf.h:2011
U_FLOAT eDx
X offset in logical units.
Definition uemf.h:2016
U_FLOAT eM12
Matrix element M12.
Definition uemf.h:2013
U_FLOAT eM21
Matrix element M21.
Definition uemf.h:2014
U_FLOAT eM11
Matrix element M11.
Definition uemf.h:2012
U_FLOAT eDy
Y offset in logical units.
Definition uemf.h:2017
U_FLOAT eM22
Matrix element M22.
Definition uemf.h:2015
int index
double height
double width
Glib::ustring name
Definition toolbars.cpp:55
struct U_EMREXCLUDECLIPRECT * PU_EMREXCLUDECLIPRECT
EMF manual 2.3.2.1.
struct U_EMRSETMAPMODE U_EMRSETICMMODE
EMF manual 2.3.11.14 ICMMode Enumeration.
struct U_EMRSETWINDOWORGEX * PU_EMRSETWINDOWORGEX
EMF manual 2.3.11.31.
struct U_EMRCREATECOLORSPACEW * PU_EMRCREATECOLORSPACEW
EMF manual 2.3.7.3.
struct U_EMRSETMETARGN * PU_EMRABORTPATH
EMF manual 2.3.10.
struct U_EMRPOLYTEXTOUTA * PU_EMRPOLYTEXTOUTA
EMF manual 2.3.5.32.
struct U_EPS_DATA * PU_EPS_DATA
EMF manual 2.2.6.
uint32_t U_CBBITSSRC
Count of Bytes in object at corresponding U_OFF*.
Definition uemf.h:196
struct U_EMREXTFLOODFILL * PU_EMREXTFLOODFILL
EMF manual 2.3.5.6
struct U_XFORM * PU_XFORM
EMF manual 2.2.28.
struct U_EMRSETMETARGN * PU_EMRCLOSEFIGURE
EMF manual 2.3.10.
struct U_RECT U_RECTL
WMF manual 2.2.2.19.
struct U_EMRMODIFYWORLDTRANSFORM * PU_EMRMODIFYWORLDTRANSFORM
EMF manual 2.3.12.1.
struct U_EMRSETMITERLIMIT * PU_EMRSETMITERLIMIT
EMF manual 2.3.11.21
uint32_t U_NUM_RGBQUAD
Number of U_RGBQUAD (in bmciColors in U_BITMAPCOREINFO)
Definition uemf.h:238
struct U_EMRSETMETARGN * PU_EMRENDPATH
EMF manual 2.3.10.
struct U_EMRDELETEOBJECT * PU_EMRDELETEOBJECT
EMF manual 2.3.8.3.
struct U_EMRPOLYPOLYLINE * PU_EMRPOLYPOLYGON
EMF manual 2.3.5.28.
uint32_t U_NUM_POLYCOUNTS
Number of U_POLYCOUNTS.
Definition uemf.h:233
struct U_EMRSETMAPMODE * PU_EMRSETTEXTALIGN
EMF manual 2.3.11.25 TextAlignment enumeration.
struct U_EMRNAMEDESCAPE * PU_EMRNAMEDESCAPE
EMF manual 2.3.6.3.
uint32_t U_NUM_RECTL
Number of U_RECTL.
Definition uemf.h:229
struct U_EMRSETCOLORADJUSTMENT * PU_EMRSETCOLORADJUSTMENT
EMF manual 2.3.11.13.
struct U_EMRCOLORMATCHTOTARGETW * PU_EMRCOLORMATCHTOTARGETW
EMF manual 2.3.11.1.
struct U_EMRSETWINDOWORGEX * PU_EMRSETVIEWPORTORGEX
EMF manual 2.3.11.29.
struct U_EMRMOVETOEX * PU_EMRMOVETOEX
EMF manual 2.3.11.4.
struct U_EMRSTRETCHBLT * PU_EMRSTRETCHBLT
EMF manual 2.3.1.6.
uint32_t U_CBBITSMSK
Count of Bytes in object at corresponding U_OFF*.
Definition uemf.h:195
struct U_EMRPOLYBEZIER * PU_EMRPOLYGON
EMF manual 2.3.5.22.
struct U_EMRSETWINDOWEXTEX * PU_EMRSETWINDOWEXTEX
EMF manual manual 2.3.11.30.
struct U_EMRSETMAPMODE * PU_EMRSETMAPMODE
EMF manual 2.3.11.19 MapMode enumeration.
struct U_EMRFILLPATH U_EMRSTROKEPATH
EMF manual 2.3.5.39.
struct U_EMRSETPIXELV * PU_EMRSETPIXELV
EMF manual 2.3.5.36.
struct U_SIZE U_SIZEL
WMF manual 2.2.2.22.
struct U_EMRSTRETCHDIBITS * PU_EMRSTRETCHDIBITS
EMF manual 2.3.1.7.
struct U_POINT28_4 * PU_POINT28_4
EMF manual 2.2.23.
struct U_EMRSETMAPMODE U_EMRSETROP2
EMF manual 2.3.11.23 Binary Raster Operation Enumeration.
struct U_PAIRF * PU_PAIRF
Any generic pair of floats. Microsoft name: (none)
struct U_POINT16 * PU_POINT16
WMF manual 2.2.2.16.
uint32_t U_NUM_POINTL
Number of U_POINTL.
Definition uemf.h:230
struct U_EMRTRANSPARENTBLT * PU_EMRTRANSPARENTBLT
EMF manual 2.3.1.8.
uint32_t U_OFFBMIMSK
Byte offset to TYPE, always measured from the start of the RECORD (not the struct)
Definition uemf.h:211
struct U_DESIGNVECTOR * PU_DESIGNVECTOR
EMF manual 2.2.3.
uint32_t U_POLYCOUNTS
aPolyCounts For U_EMRPOLYPOLYLINE etc.
Definition uemf.h:224
struct U_EMRPOLYPOLYLINE16 U_EMRPOLYPOLYGON16
EMF manual 2.3.5.29.
struct U_EMRPOLYBEZIER16 U_EMRPOLYBEZIERTO16
EMF manual 2.3.5.19.
struct U_EMRSETWORLDTRANSFORM * PU_EMRSETWORLDTRANSFORM
EMF manual 2.3.12.2.
uint32_t U_OFFBMI
Byte offset to TYPE, always measured from the start of the RECORD (not the struct)
Definition uemf.h:210
uint32_t U_OFFBITS
Byte offset to TYPE, always measured from the start of the RECORD (not the struct)
Definition uemf.h:207
struct U_EMRSETMAPMODE * PU_EMRSETPOLYFILLMODE
EMF manual 2.3.11.22 PolygonFillMode Enumeration.
struct U_EMRSETMAPMODE * PU_EMRSETBKMODE
EMF manual 2.3.11.11 BackgroundMode Enumeration.
struct U_PAIR * PU_POINT
WMF manual 2.2.2.15.
uint32_t U_NUM_STR
Number of 8 or 16 bit characters in string.
Definition uemf.h:235
struct U_PIXELFORMATDESCRIPTOR * PU_PIXELFORMATDESCRIPTOR
EMF manual 2.2.22.
struct U_GRADIENT4 * PU_GRADIENT4
EMF manual 2.2.7.
struct U_EMRPOLYDRAW * PU_EMRPOLYDRAW
EMF manual 2.3.5.20
struct U_LOGBRUSH * PU_LOGBRUSH
EMF manual 2.2.12.
struct U_EMRCOMMENT_EMFPLUS * PU_EMRCOMMENT_EMFPLUS
EMF manual 2.3.3.2, EMF Plus comment.
struct U_EMRSETTEXTCOLOR * PU_EMRSETTEXTCOLOR
EMF manual 2.3.11.26.
struct U_EMRINVERTRGN * PU_EMRPAINTRGN
EMF manual 2.3.5.14.
uint32_t U_NUM_GRADOBJ
Number of U_GRADIENT4 OR U_GRADIENT3 (determined at run time)
Definition uemf.h:237
struct U_EMRSETMAPMODE * PU_EMRSELECTCLIPPATH
EMF manual 2.3.2.5 RegionMode Enumeration.
struct U_EMRCOMMENT_SPOOL * PU_EMRCOMMENT_SPOOL
EMF manual 2.3.3.3, EMF Spool comment.
struct U_EMRPOLYPOLYLINE16 * PU_EMRPOLYPOLYLINE16
EMF manual 2.3.5.31.
struct U_EMRMOVETOEX * PU_EMRLINETO
EMF manual 2.3.5.13.
struct U_PAIR U_POINTL
WMF manual 2.2.2.15.
struct U_EXTLOGPEN * PU_EXTLOGPEN
EMF manual 2.2.20.
struct U_EMRSCALEVIEWPORTEXTEX U_EMRSCALEWINDOWEXTEX
EMF manual 2.3.11.8.
struct U_EMRSELECTPALETTE * PU_EMRSELECTPALETTE
EMF manual 2.3.8.6
uint32_t U_CBDATA
Count of Bytes in object at corresponding U_OFF*.
Definition uemf.h:200
struct U_EMRBITBLT * PU_EMRBITBLT
EMF manual 2.3.1.2.
struct U_EMRSETMETARGN U_EMRCLOSEFIGURE
EMF manual 2.3.10.
struct U_EMRMOVETOEX U_EMRLINETO
EMF manual 2.3.5.13.
struct U_EMRPOLYBEZIER16 U_EMRPOLYLINETO16
EMF manual 2.3.5.27.
struct U_EMRARC * PU_EMRCHORD
EMF manual 2.3.5.4.
struct U_EMRPOLYBEZIER * PU_EMRPOLYBEZIERTO
EMF manual 2.3.5.18.
struct U_EMRSETMAPMODE * PU_EMRSETLAYOUT
EMF manual 2.3.11.17 Mirroring Enumeration.
struct U_EMRRESIZEPALETTE * PU_EMRRESIZEPALETTE
EMF manual 2.3.8.4
struct U_LOGCOLORSPACEA * PU_LOGCOLORSPACEA
WMF manual 2.2.2.11.
struct U_EMRCOMMENT * PU_EMRCOMMENT
EMF manual 2.3.3.1, AKA GDICOMMENT.
struct U_EMRCOMMENT_PUBLIC * PU_EMRCOMMENT_PUBLIC
EMF manual 2.3.3.4, EMF Public comment.
struct U_EMREXTCREATEPEN * PU_EMREXTCREATEPEN
EMF manual 2.3.7.9.
struct U_EMRSETWINDOWORGEX * PU_EMRSETBRUSHORGEX
EMF manual 2.3.11.12.
struct U_EMRFORMAT * PU_EMRFORMAT
EMF manual 2.2.4.
struct U_EMRSETMAPMODE U_EMRSELECTCLIPPATH
EMF manual 2.3.2.5 RegionMode Enumeration.
struct U_LOGPALETTE * PU_LOGPALETTE
EMF manual 2.2.17.
struct U_EMRPOLYBEZIER16 * PU_EMRPOLYLINETO16
EMF manual 2.3.5.27.
struct U_CIEXYZTRIPLE * PU_CIEXYZTRIPLE
WMF manual 2.2.2.7.
struct U_EMRELLIPSE U_EMRRECTANGLE
EMF manual 2.3.5.5
struct U_LCS_GAMMA * PU_LCS_GAMMA
WMF manual 2.2.2.11.
struct U_EMRSETMAPMODE U_EMRSETSTRETCHBLTMODE
EMF manual 2.3.11.24 StretchMode Enumeration.
struct U_ENHMETARECORD * PU_ENHMETARECORD
General form of an EMF record.
struct U_EMRARC U_EMRCHORD
EMF manual 2.3.5.4.
struct U_RECT * PU_RECTL
WMF manual 2.2.2.19.
uint32_t U_STYLEENTRY
StyleEntry For U_EXTLOGPEN.
Definition uemf.h:223
struct U_EMRPLGBLT * PU_EMRPLGBLT
EMF manual 2.3.1.4.
struct U_EMRARC * PU_EMRARCTO
EMF manual 2.3.5.3.
struct U_EMROFFSETCLIPRGN * PU_EMROFFSETCLIPRGN
EMF manual 2.3.2.4.
struct U_EMRSCALEVIEWPORTEXTEX * PU_EMRSCALEWINDOWEXTEX
EMF manual 2.3.11.8.
struct U_EMRPOLYBEZIER U_EMRPOLYBEZIERTO
EMF manual 2.3.5.18.
struct U_LOGFONT * PU_LOGFONT
EMF manual 2.2.13.
struct U_EMRSETMAPPERFLAGS * PU_EMRSETMAPPERFLAGS
EMF manual 2.3.11.20.
uint32_t U_OFFDESC
Byte offset to TYPE, always measured from the start of the RECORD (not the struct)
Definition uemf.h:214
struct U_EMRHEADER * PU_EMRHEADER
EMF manual 2.2.9.
struct U_MAT2X2 * PU_MAT2X2
2 x 2 matrix, used by xform_alt_set() function.
struct U_EMRINVERTRGN * PU_EMRINVERTRGN
EMF manual 2.3.11.3.
struct U_EMRPOLYBEZIER16 U_EMRPOLYGON16
EMF manual 2.3.5.23.
struct U_LOGPLTNTRY * PU_LOGPLTNTRY
EMF manual 2.2.18.
uint32_t U_CBNAME
Count of Bytes in object at corresponding U_OFF*.
Definition uemf.h:201
struct U_EMRSETARCDIRECTION * PU_EMRSETARCDIRECTION
EMF manual 2.3.11.9.
uint32_t U_CBBMISRC
Count of Bytes in object at corresponding U_OFF*.
Definition uemf.h:199
struct U_EMRSMALLTEXTOUT * PU_EMRSMALLTEXTOUT
EMF manual 2.3.5.37.
struct U_BITFIX28_4 * PU_BITFIX28_4
EMF manual 2.2.1.
struct U_BITMAPINFOHEADER * PU_BITMAPINFOHEADER
WMF manual 2.2.2.3.
struct U_EMRCREATECOLORSPACE * PU_EMRCREATECOLORSPACE
EMF manual 2.3.7.2
struct U_EMRGENERICPAIR * PU_EMRGENERICPAIR
Generic EMR record with two 32 bit values. Microsoft name: (none)
struct U_EMRSETMETARGN U_EMRBEGINPATH
EMF manual 2.3.10.
struct U_EMRCREATEBRUSHINDIRECT * PU_EMRCREATEBRUSHINDIRECT
EMF manual 2.3.7.1
uint32_t U_NUM_EMRTEXT
Number of U_EMRTEXT.
Definition uemf.h:234
struct U_EMRSETMAPMODE * PU_EMRSETICMMODE
EMF manual 2.3.11.14 ICMMode Enumeration.
struct U_EMRROUNDRECT * PU_EMRROUNDRECT
EMF manual 2.3.5.35
struct U_EMRPOLYBEZIER * PU_EMRPOLYBEZIER
EMF manual 2.3.5.16.
struct U_EMRRESTOREDC * PU_EMRRESTOREDC
EMF manual 2.3.11.6.
struct U_EMRSETWINDOWEXTEX U_EMRSETVIEWPORTEXTEX
EMF manual manual 2.3.11.28.
uint32_t U_OFFBITSMSK
Byte offset to TYPE, always measured from the start of the RECORD (not the struct)
Definition uemf.h:208
uint32_t U_CBBMI
Count of Bytes in object at corresponding U_OFF*.
Definition uemf.h:197
uint32_t U_OFFBMISRC
Byte offset to TYPE, always measured from the start of the RECORD (not the struct)
Definition uemf.h:212
struct U_EMRSETMAPMODE U_EMRSETBKMODE
EMF manual 2.3.11.11 BackgroundMode Enumeration.
struct U_EMRPOLYPOLYLINE U_EMRPOLYPOLYGON
EMF manual 2.3.5.28.
struct U_RGBQUAD * PU_RGBQUAD
WMF manual 2.2.2.20.
struct U_EMRDELETECOLORSPACE U_EMRSETCOLORSPACE
EMF manual 2.3.8.7.
struct U_EMRPOLYBEZIER U_EMRPOLYLINETO
EMF manual 2.3.5.26.
struct U_EMREXTTEXTOUTA * PU_EMREXTTEXTOUTW
EMF manual 2.3.5.8.
struct U_EMRSETWINDOWORGEX U_EMRSETBRUSHORGEX
EMF manual 2.3.11.12.
struct U_EMRSETMETARGN U_EMRSAVEDC
EMF manual 2.3.11.
struct U_EMRPOLYTEXTOUTA * PU_EMRPOLYTEXTOUTW
EMF manual 2.3.5.33.
struct U_EMRPOLYBEZIER16 * PU_EMRPOLYGON16
EMF manual 2.3.5.23.
struct U_EMRPOLYBEZIER * PU_EMRPOLYLINE
EMF manual 2.3.5.24.
struct U_SIZE * PU_SIZEL
WMF manual 2.2.2.22.
uint32_t U_OFFPXLFMT
Byte offset to TYPE, always measured from the start of the RECORD (not the struct)
Definition uemf.h:217
struct U_EMRDELETEOBJECT * PU_EMRSELECTOBJECT
EMF manual 2.3.8.5.
struct U_EMR * PU_EMR
First two fields of all EMF records,.
struct U_EMRPIXELFORMAT * PU_EMRPIXELFORMAT
EMF manual 2.3.11.5.
uint8_t U_DATA
any binary sort of data, not otherwise classified.
Definition uemf.h:219
struct U_LOGPEN * PU_LOGPEN
EMF manual 2.2.19.
struct U_EMRCREATEDIBPATTERNBRUSHPT * PU_EMRCREATEDIBPATTERNBRUSHPT
EMF manual 2.3.7.4.
struct U_EMRPOLYTEXTOUTA U_EMRPOLYTEXTOUTW
EMF manual 2.3.5.33.
struct U_EMRPOLYDRAW16 * PU_EMRPOLYDRAW16
EMF manual 2.3.5.21.
struct U_EMRCREATEMONOBRUSH * PU_EMRCREATEMONOBRUSH
EMF manual 2.3.7.5.
struct U_EMRDRAWESCAPE * PU_EMRDRAWESCAPE
EMF manual 2.3.6.1.
struct U_PANOSE * PU_PANOSE
EMF manual 2.2.21.
struct U_EMRSETMETARGN U_EMRENDPATH
EMF manual 2.3.10.
struct U_EMRPOLYPOLYLINE * PU_EMRPOLYPOLYLINE
EMF manual 2.3.5.30.
struct U_EMRDELETECOLORSPACE * PU_EMRSETCOLORSPACE
EMF manual 2.3.8.7.
struct U_EMRELLIPSE * PU_EMRELLIPSE
EMF manual 2.3.5.5.
struct U_LOGBRUSH U_PATTERN
EMF manual 2.2.12.
struct U_EMRSETWINDOWEXTEX * PU_EMRSETVIEWPORTEXTEX
EMF manual manual 2.3.11.28.
struct U_EMRPOLYPOLYLINE16 * PU_EMRPOLYPOLYGON16
EMF manual 2.3.5.29.
struct U_EMRSETMETARGN U_EMRFLATTENPATH
EMF manual 2.3.10.
struct U_EMREXTTEXTOUTA * PU_EMREXTTEXTOUTA
EMF manual 2.3.5.7.
uint32_t U_CBPLENTRIES
Count of Bytes in object at corresponding U_OFF*.
Definition uemf.h:202
struct U_EMRINVERTRGN U_EMRPAINTRGN
EMF manual 2.3.5.14.
struct U_EMRSETMETARGN * PU_EMRFLATTENPATH
EMF manual 2.3.10.
struct U_EMRDELETEOBJECT U_EMRSELECTOBJECT
EMF manual 2.3.8.5.
struct U_LOGCOLORSPACEW * PU_LOGCOLORSPACEW
WMF manual 2.2.2.12.
struct U_EMRCREATEPALETTE * PU_EMRCREATEPALETTE
EMF manual 2.3.7.6
struct U_EMRSETMETARGN U_EMRWIDENPATH
EMF manual 2.3.10.
struct U_EMRSETMAPMODE * PU_EMRSETSTRETCHBLTMODE
EMF manual 2.3.11.24 StretchMode Enumeration.
struct U_EMRFRAMERGN * PU_EMRFRAMERGN
EMF manual 2.3.5.11
struct U_EMRFILLPATH U_EMRSTROKEANDFILLPATH
EMF manual 2.3.5.38.
struct U_LOGFONT_PANOSE * PU_LOGFONT_PANOSE
EMF manual 2.2.16.
struct U_EMRSETPALETTEENTRIES * PU_EMRSETPALETTEENTRIES
EMF manual 2.3.8.8
struct U_EMRELLIPSE * PU_EMRRECTANGLE
EMF manual 2.3.5.34.
uint32_t U_CBPXLFMT
Count of Bytes in object at corresponding U_OFF*.
Definition uemf.h:203
struct U_EMRPOLYBEZIER U_EMRPOLYGON
EMF manual 2.3.5.22.
struct U_PAIR U_POINT
WMF manual 2.2.2.15.
struct U_EMRALPHABLEND * PU_EMRALPHABLEND
EMF manual 2.3.1.1.
struct U_EMRSETMAPMODE U_EMRSETTEXTALIGN
EMF manual 2.3.11.25 TextAlignment enumeration.
struct U_EMRCREATEPEN * PU_EMRCREATEPEN
EMF manual 2.3.7.7.
struct U_EMREXTTEXTOUTA U_EMREXTTEXTOUTW
EMF manual 2.3.5.8.
struct U_PAIR * PU_POINTL
WMF manual 2.2.2.15.
struct U_EMRARC U_EMRARCTO
EMF manual 2.3.5.3.
uint32_t U_NUM_STYLEENTRY
Number of U_STYLEENTRY.
Definition uemf.h:232
struct U_EMRSETWINDOWORGEX U_EMRSETVIEWPORTORGEX
EMF manual 2.3.11.29.
struct U_EMRSETMETARGN * PU_EMRREALIZEPALETTE
EMF manual 2.3.10.
struct U_EMRDELETECOLORSPACE * PU_EMRDELETECOLORSPACE
EMF manual 2.3.8.2.
struct U_COLORADJUSTMENT * PU_COLORADJUSTMENT
EMF manual 2.2.2.
uint32_t U_OFFDX
Byte offset to TYPE, always measured from the start of the RECORD (not the struct)
Definition uemf.h:215
struct U_EMREXTESCAPE * PU_EMREXTESCAPE
EMF manual 2.3.6.2.
uint32_t U_CBBITS
Count of Bytes in object at corresponding U_OFF*.
Definition uemf.h:194
struct U_EMRPOLYBEZIER * PU_EMRPOLYLINETO
EMF manual 2.3.5.26.
struct U_EMRGLSBOUNDEDRECORD * PU_EMRGLSBOUNDEDRECORD
EMF manual 2.3.9.1.
struct U_CIEXYZ * PU_CIEXYZ
WMF manual 2.2.2.6.
struct U_EMRSETMAPMODE U_EMRSETPOLYFILLMODE
EMF manual 2.3.11.22 PolygonFillMode Enumeration.
struct U_EMRFILLPATH * PU_EMRSTROKEANDFILLPATH
EMF manual 2.3.5.38.
struct U_RGNDATAHEADER * PU_RGNDATAHEADER
EMF manual 2.2.25.
struct U_EMRGLSRECORD * PU_EMRGLSRECORD
EMF manual 2.3.9.2
uint32_t U_CBSTR
Count of Bytes in an 8 or 16 bit string.
Definition uemf.h:205
struct U_LOGBRUSH * PU_PATTERN
EMF manual 2.2.12.
struct U_EMREXCLUDECLIPRECT * PU_EMRINTERSECTCLIPRECT
EMF manual 2.3.2.3.
struct U_EMREOF * PU_EMREOF
EMF manual 3.2.4.1.
uint32_t U_OFFSTR
Byte offset to string of either 8 or 16 bit characters.
Definition uemf.h:218
struct U_EMRPOLYBEZIER16 * PU_EMRPOLYLINE16
EMF manual 2.3.5.25.
struct U_EMRSETTEXTCOLOR * PU_EMRSETBKCOLOR
EMF manual 2.3.11.10.
struct U_EMRSETMETARGN * PU_EMRSETMETARGN
EMF manual 2.3.2.
struct U_EMRMASKBLT * PU_EMRMASKBLT
EMF manual 2.3.1.3.
struct U_EMRSETDIBITSTODEVICE * PU_EMRSETDIBITSTODEVICE
EMF manual 2.3.1.5.
uint32_t U_OFFDATA
Byte offset to TYPE, always measured from the start of the RECORD (not the struct)
Definition uemf.h:213
struct U_EMRFILLPATH * PU_EMRSTROKEPATH
EMF manual 2.3.5.39.
struct U_EMRSETMETARGN * PU_EMRBEGINPATH
EMF manual 2.3.10.
struct U_EMRARC * PU_EMRARC
EMF manual 2.3.5.2.
struct U_EMRSETMETARGN U_EMRREALIZEPALETTE
EMF manual 2.3.10.
struct U_RECT * PU_RECT
WMF manual 2.2.2.19.
struct U_EMRSETMAPMODE * PU_EMRSETROP2
EMF manual 2.3.11.23 Binary Raster Operation Enumeration.
uint32_t U_OFFPLENTRIES
Byte offset to TYPE, always measured from the start of the RECORD (not the struct)
Definition uemf.h:216
struct U_EMRPOLYBEZIER U_EMRPOLYLINE
EMF manual 2.3.5.24.
struct U_EMRSETMETARGN U_EMRABORTPATH
EMF manual 2.3.10.
struct U_EMREXTSELECTCLIPRGN * PU_EMREXTSELECTCLIPRGN
EMF manual 2.3.2.2.
uint32_t U_NUM_POINT16
Number of U_POINT16.
Definition uemf.h:231
struct U_LCS_GAMMARGB * PU_LCS_GAMMARGB
WMF manual 2.2.2.11.
struct U_EMRPOLYBEZIER16 * PU_EMRPOLYBEZIER16
EMF manual 2.3.5.17.
uint32_t U_NUM_FNTAXES
Number of U_FNTAXES.
Definition uemf.h:227
uint32_t U_OFFBITSSRC
Byte offset to TYPE, always measured from the start of the RECORD (not the struct)
Definition uemf.h:209
struct U_EMRANGLEARC * PU_EMRANGLEARC
EMF manual 2.3.5.1
uint32_t U_FNTAXES
Font Axes For U_DESIGNVECTOR.
Definition uemf.h:222
struct U_SIZE * PU_SIZE
WMF manual 2.2.2.22.
uint32_t U_NUM_TRIVERTEX
Number of U_TRIVERTEX.
Definition uemf.h:236
struct U_TRIVERTEX * PU_TRIVERTEX
EMF manual 2.2.26.
struct U_EMRSETMAPMODE U_EMRSETLAYOUT
EMF manual 2.3.11.17 Mirroring Enumeration.
float U_FLOAT
32 bit float
Definition uemf.h:192
struct U_EMRARC U_EMRPIE
EMF manual 2.3.5.15.
struct U_BITMAPINFO * PU_BITMAPINFO
WMF Manual 2.2.2.9.
struct U_EMRFILLPATH * PU_EMRFILLPATH
EMF manual 2.3.5.9.
struct U_EMRGRADIENTFILL * PU_EMRGRADIENTFILL
EMF manual 2.3.5.12.
struct U_BLEND * PU_BLEND
EMF Manual 2.3.1.1.
struct U_EMRSETMETARGN * PU_EMRSAVEDC
EMF manual 2.3.11.
uint32_t U_CBRGNDATA
Count of Bytes in object at corresponding U_OFF*.
Definition uemf.h:204
struct U_EMRPOLYBEZIER16 * PU_EMRPOLYBEZIERTO16
EMF manual 2.3.5.19.
struct U_EMRSETTEXTCOLOR U_EMRSETBKCOLOR
EMF manual 2.3.11.10.
struct U_GRADIENT3 * PU_GRADIENT3
EMF manual 2.2.8.
struct U_EMREXTCREATEFONTINDIRECTW * PU_EMREXTCREATEFONTINDIRECTW
EMF manual 2.3.7.8.
struct U_RGNDATA * PU_RGNDATA
EMF manual 2.2.24.
struct U_COLORREF * PU_COLORREF
WMF manual 2.2.2.8.
struct U_EMRPOLYBEZIER16 U_EMRPOLYLINE16
EMF manual 2.3.5.25.
struct U_PAIR * PU_PAIR
WMF manual 2.2.2.15.
struct U_EMRFILLRGN * PU_EMRFILLRGN
EMF manual 2.3.5.10
struct U_EMRSCALEVIEWPORTEXTEX * PU_EMRSCALEVIEWPORTEXTEX
EMF manual 2.3.11.7.
struct U_EMRARC * PU_EMRPIE
EMF manual 2.3.5.15.
struct U_EMRSETMETARGN * PU_EMRWIDENPATH
EMF manual 2.3.10.
struct U_EMRTEXT * PU_EMRTEXT
EMF manual 2.2.5.
uint32_t U_CBBMIMSK
Count of Bytes in object at corresponding U_OFF*.
Definition uemf.h:198
uint32_t U_NUM_LOGPLTNTRY
Number of U_LOGPLTENTRY.
Definition uemf.h:228
struct U_EMREXCLUDECLIPRECT U_EMRINTERSECTCLIPRECT
EMF manual 2.3.2.3.
Defintions and prototype for function for converting EMF records between Big Endian and Little Endian...
Prototypes for functions that manipulate UTF and various types of text.
void wchar32show(const uint32_t *src)
void wchar16show(const uint16_t *src)
void wchartshow(const wchar_t *src)
void wchar8show(const char *src)