libUEMF
A portable library for reading and writing WMF, EMF and EMF+ files
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Functions
upmf.c File Reference

Functions for manipulating EMF+ files and structures. More...

#include <stdlib.h>
#include <stdio.h>
#include <string.h>
#include <iconv.h>
#include <wchar.h>
#include <errno.h>
#include <limits.h>
#include <math.h>
#include <stddef.h>
#include "upmf.h"
#include "uemf_endian.h"

Functions

void U_PMR_write (U_PSEUDO_OBJ *po, U_PSEUDO_OBJ *sum, EMFTRACK *et)
 Utility function for writing one or more EMF+ records in a PseudoObject to the EMF output file. More...
 
int U_PMR_drawline (uint32_t PenID, uint32_t PathID, U_PMF_POINTF Start, U_PMF_POINTF End, int Dashed, U_PSEUDO_OBJ *sum, EMFTRACK *et)
 Utility function to draw a line. More...
 
int U_PMR_drawstring (const char *string, int Vpos, uint32_t FontID, const U_PSEUDO_OBJ *BrushID, uint32_t FormatID, U_PMF_STRINGFORMAT Sfs, const char *FontName, U_FLOAT Height, U_FontInfoParams *fip, uint32_t FontFlags, U_FLOAT x, U_FLOAT y, U_PSEUDO_OBJ *sum, EMFTRACK *et)
 Utility function for drawing strings onto the baseline in one call. More...
 
U_PMF_POINTPOINTF_To_POINT16_LE (U_PMF_POINTF *points, int count)
 Allocate and construct an array of U_POINT16 objects from a set of U_PMF_POINTF objects, endianness in and out is LE. More...
 
char * U_pmr_names (unsigned int idx)
 Look up the name of the EMR+ record by type. Returns U_EMR_INVALID if out of range. More...
 
int U_OID_To_OT (uint32_t OID)
 Convert from PseudoObject OID to ObjectType enumeration. More...
 
int U_OID_To_BT (uint32_t OID)
 Convert from PseudoObject OID to BrushType enumeration. More...
 
int U_OID_To_CLCDT (uint32_t OID)
 Convert from PseudoObject OID to CustomLineCapDataType Enumeration. More...
 
int U_OID_To_IDT (uint32_t OID)
 Convert from PseudoObject OID to ImageDataType Enumeration. More...
 
int U_OID_To_RNDT (uint32_t OID)
 Convert from PseudoObject OID to RegionNodeDataType Enumeration. More...
 
int U_OA_append (U_OBJ_ACCUM *oa, const char *data, int size, int Type, int Id)
 Append data to an U_OBJ_ACCUM structure. More...
 
int U_OA_clear (U_OBJ_ACCUM *oa)
 Clear an U_OBJ_ACCUM structure. Accumulated storage is retained. More...
 
int U_OA_release (U_OBJ_ACCUM *oa)
 Release an U_OBJ_ACCUM structure. Accumulated storage is free'd. More...
 
U_PSEUDO_OBJU_PO_create (char *Data, size_t Size, size_t Use, uint32_t Type)
 Create and set an U_PSEUDO_OBJ. More...
 
U_PSEUDO_OBJU_PO_append (U_PSEUDO_OBJ *po, const char *Data, size_t Size)
 Append data to a U_PSEUDO_OBJ object and return it. More...
 
U_PSEUDO_OBJU_PO_po_append (U_PSEUDO_OBJ *po, U_PSEUDO_OBJ *Src, int StripE)
 Append data to a U_PSEUDO_OBJ object and return it. More...
 
int U_PO_free (U_PSEUDO_OBJ **po)
 Free an U_PSEUDO_OBJ structure. All associated memory is released. More...
 
U_PSEUDO_OBJU_PMF_SERIAL_set (uint32_t Type, const U_SERIAL_DESC *List)
 create a PseudoObject with data in the correct byte order for an EMF+ file. More...
 
U_DPSEUDO_OBJU_PATH_create (int Elements, const U_PMF_POINTF *Points, uint8_t First, uint8_t Others)
 Create U_DPSEUDO_OBJ's for the Points and Types of a path. More...
 
int U_DPO_free (U_DPSEUDO_OBJ **dpo)
 Free U_DPSEUDO_OBJ's. More...
 
int U_DPO_clear (U_DPSEUDO_OBJ *dpo)
 Clear U_DPSEUDO_OBJ's. Memory is retained, Elements and Used values are set to 0. More...
 
int U_PATH_moveto (U_DPSEUDO_OBJ *Path, U_PMF_POINTF Point, uint8_t Flags)
 Append a "moveto" point to a path. More...
 
int U_PATH_lineto (U_DPSEUDO_OBJ *Path, U_PMF_POINTF Point, uint8_t Flags)
 Append a "lineto" point to a path. More...
 
int U_PATH_closepath (U_DPSEUDO_OBJ *Path)
 Set the closepath bit in the last point. More...
 
int U_PATH_polylineto (U_DPSEUDO_OBJ *Path, uint32_t Elements, const U_PMF_POINTF *Points, uint8_t Flags, uint8_t StartSeg)
 Append a "polylineto" set of point to a path. More...
 
int U_PATH_polybezierto (U_DPSEUDO_OBJ *Path, uint32_t Elements, const U_PMF_POINTF *Points, uint8_t Flags, uint8_t StartSeg)
 Append a "polybezierto" set of point to a path. More...
 
int U_PATH_polygon (U_DPSEUDO_OBJ *Path, uint32_t Elements, const U_PMF_POINTF *Points, uint8_t Flags)
 Append a "polygon" set of points to a path. More...
 
int U_PATH_arcto (U_DPSEUDO_OBJ *Path, U_FLOAT Start, U_FLOAT Sweep, U_FLOAT Rot, U_PMF_RECTF *Rect, uint8_t Flags, int StartSeg)
 Append an "arcto" set of points to a path (Bezier points are calculated, and these are appended. More...
 
U_PMF_POINTFpointfs_transform (U_PMF_POINTF *points, int count, U_XFORM xform)
 Allocate and construct an array of U_PMF_POINTF objects which have been subjected to a U_XFORM. More...
 
U_PMF_RECTFrectfs_transform (U_PMF_RECTF *Rects, int Count, U_XFORM Xform)
 Allocate and construct an array of U_PMF_RECTF objects which have been subjected to a U_XFORM. More...
 
U_PMF_TRANSFORMMATRIX tm_for_gradrect (U_FLOAT Angle, U_FLOAT w, U_FLOAT h, U_FLOAT x, U_FLOAT y, U_FLOAT Periods)
 Utility function calculate the transformation matrix needed to make a gradient run precisely corner to corner of a rectangle. More...
 
U_PSEUDO_OBJU_PMR_drawfill (uint32_t PathID, uint32_t PenID, const U_PSEUDO_OBJ *BrushID)
 Create a U_PSEUDO_OBJ containing a U_PMR_FILLPATH and U_PMR_DRAWPATH records. More...
 
int U_PMF_SERIAL_get (const char **Src, void *Dst, size_t Units, size_t Reps, int SE)
 Extract a single data field from a source. More...
 
int U_PMF_SERIAL_array_copy_get (const char **Src, void **Dst, size_t Units, size_t Reps, int SE, int Cond)
 Conditionally extract an array of data from a source, allocating space to hold it. More...
 
int U_PMF_LEN_REL715 (const char *contents, int Elements)
 Calculate the length in bytes of a relative path object composed of U_PMF_INTEGER7 and U_PMF_INTER15 values. More...
 
int U_PMF_LEN_FLOATDATA (const char *contents)
 Calculate the length in bytes of objects which are a 4 byte Count followed by Count * float bytes. More...
 
int U_PMF_LEN_BYTEDATA (const char *contents)
 Calculate the length in bytes of objects which are a 4 byte count followed by count bytes. More...
 
char * U_PMF_CURLYGUID_set (uint8_t *GUID)
 Create a string containing the curly bracket form of the 16 byte GUID value. More...
 
int U_PMF_KNOWNCURLYGUID_set (const char *string)
 Identify a known curly GUID. More...
 
uint8_t * U_LOAD_GUID (char *string)
 Load a GUID from text format into EMF+ file binary format. More...
 
uint8_t * U_OID_To_GUID (uint32_t OID)
 Generate the 16 byte form from OID of the ImageEffects Identifier. More...
 
void U_PMF_MEMCPY_SRCSHIFT (void *Dst, const char **Src, size_t Size)
 copy data and shift source pointer by the amount of data moved More...
 
void U_PMF_MEMCPY_DSTSHIFT (char **Dst, const void *Src, size_t Size)
 copy data and shift destination pointer by the amount of data moved More...
 
void U_PMF_REPCPY_DSTSHIFT (char **Dst, const void *Src, size_t Size, size_t Reps)
 Copy the single instance at Src repeatedly to Dst. More...
 
void U_PMF_PTRSAV_SHIFT (const char **Dst, const char **Src, size_t Size)
 save pointer to data and shift source pointer by the amount of data moved More...
 
int U_PMF_PTRSAV_COND (const char **Dst, const char *Src, int Doit)
 save pointer to data and shift source pointer by the amount of data moved More...
 
uint16_t U_PMF_HEADERFLAGS_get (const char *contents)
 Get the 16 bit unsigned Flags field from a header. More...
 
int U_PMF_HEADERFIELDS_get (const char *contents, uint16_t *Type, uint16_t *Flags, uint32_t *Size, uint32_t *Datasize)
 Retrieve whichever header fields are requested. NULL pointers do not retrieve. More...
 
int U_PMF_CMN_HDR_get (const char **contents, U_PMF_CMN_HDR *Header)
 Get the entire EMF+ record header. More...
 
int U_PMF_LEN_PENDATA (const char *PenData)
 Return the size of a PenData object from an EMF+ record. More...
 
int U_PMF_LEN_OPTPENDATA (const char *PenData, uint32_t Flags)
 Return the size of an OptPenData object from an EMF+ record. More...
 
U_PSEUDO_OBJU_PMF_BRUSH_set (uint32_t Version, const U_PSEUDO_OBJ *Bd)
 Create and set a U_PMF_BRUSH PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_CUSTOMLINECAP_set (uint32_t Version, const U_PSEUDO_OBJ *Ld)
 Create and set a U_PMF_CUSTOMLINECAP PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_FONT_set (uint32_t Version, U_FLOAT EmSize, uint32_t SizeUnit, int32_t FSFlags, uint32_t Length, const uint16_t *Font)
 Create and set a U_PMF_FONT PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_IMAGE_set (uint32_t Version, const U_PSEUDO_OBJ *Id)
 Create and set a U_PMF_IMAGE PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_IMAGEATTRIBUTES_set (uint32_t Version, uint32_t WrapMode, uint32_t ClampColor, uint32_t ObjectClamp)
 Create and set a U_PMF_IMAGEATTRIBUTES PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_PATH_set (uint32_t Version, const U_PSEUDO_OBJ *Points, const U_PSEUDO_OBJ *Types)
 Create and set a U_PMF_PATH PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_PATH_set2 (uint32_t Version, const U_DPSEUDO_OBJ *Path)
 Create and set a U_PMF_PATH PseudoObject that uses U_PMF_POINTF coordinates. More...
 
U_PSEUDO_OBJU_PMF_PATH_set3 (uint32_t Version, const U_DPSEUDO_OBJ *Path)
 Create and set a U_PMF_PATH PseudoObject that uses U_PMF_POINT (int 16) coordinates. More...
 
U_PSEUDO_OBJU_PMF_PEN_set (uint32_t Version, const U_PSEUDO_OBJ *PenData, const U_PSEUDO_OBJ *Brush)
 Create and set a U_PMF_PEN PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_REGION_set (uint32_t Version, uint32_t Count, const U_PSEUDO_OBJ *Nodes)
 Create and set a U_PMF_REGION PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_STRINGFORMAT_set (U_PMF_STRINGFORMAT *Sfs, const U_PSEUDO_OBJ *Sfd)
 Create and set a U_PMF_STRINGFORMAT PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_4NUM_set (uint32_t BrushID)
 Create and set a PMF_4NUM PseudoObject (used for BrushID's) More...
 
U_PSEUDO_OBJU_PMF_ARGB_set (uint8_t Alpha, uint8_t Red, uint8_t Green, uint8_t Blue)
 Create and set a U_PMF_ARGB PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_ARGBN_set (uint32_t Count, U_PMF_ARGB *Colors)
 Create and set an Array of U_PMF_ARGB valus in a PseudoObject. More...
 
U_PMF_ARGB U_PMF_ARGBOBJ_set (uint8_t Alpha, uint8_t Red, uint8_t Green, uint8_t Blue)
 Set a U_PMF_ARGB object. More...
 
U_PSEUDO_OBJU_PMF_BITMAP_set (const U_PMF_BITMAP *Bs, const U_PSEUDO_OBJ *Bm)
 Create and set a U_PMF_BITMAP PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_BITMAPDATA_set (const U_PSEUDO_OBJ *Ps, int cbBm, const char *Bm)
 Create and set a U_PMF_BITMAPDATA PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_BLENDCOLORS_set (uint32_t Elements, const U_FLOAT *Positions, const U_PSEUDO_OBJ *Colors)
 Create and set a U_PMF_BLENDCOLORS PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_BLENDCOLORS_linear_set (uint32_t Elements, U_PMF_ARGB StartColor, U_PMF_ARGB EndColor)
 Create and set a U_PMF_BLENDCOLORS PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_BLENDFACTORS_set (uint32_t Elements, const U_FLOAT *Positions, const U_FLOAT *Factors)
 Create and set a U_PMF_BLENDFACTORS PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_BLENDFACTORS_linear_set (uint32_t Elements, U_FLOAT StartFactor, U_FLOAT EndFactor)
 Create and set a U_PMF_BLENDFACTORS PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_BOUNDARYPATHDATA_set (const U_PSEUDO_OBJ *Path)
 Create and set a U_PMF_BOUNDARYPATHDATA PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_BOUNDARYPOINTDATA_set (uint32_t Elements, const U_PMF_POINTF *Points)
 Create and set a U_PMF_BOUNDARYPOINTDATA PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_CHARACTERRANGE_set (int32_t First, int32_t Length)
 Create and set a U_PMF_CHARACTERRANGE PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_COMPOUNDLINEDATA_set (int32_t Elements, const char *Widths)
 Create and set a U_PMF_COMPOUNDLINEDATA PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_COMPRESSEDIMAGE_set (int32_t cbImage, const char *Image)
 Create and set a U_PMF_COMPRESSEDIMAGE PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_CUSTOMENDCAPDATA_set (const U_PSEUDO_OBJ *Clc)
 Create and set a U_PMF_CUSTOMENDCAPDATA PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_CUSTOMLINECAPARROWDATA_set (U_FLOAT Width, U_FLOAT Height, U_FLOAT MiddleInset, uint32_t FillState, uint32_t StartCap, uint32_t EndCap, uint32_t Join, U_FLOAT MiterLimit, U_FLOAT WidthScale)
 Create and set a U_PMF_CUSTOMLINECAPARROWDATA PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_CUSTOMLINECAPDATA_set (uint32_t Flags, uint32_t Cap, U_FLOAT Inset, uint32_t StartCap, uint32_t EndCap, uint32_t Join, U_FLOAT MiterLimit, U_FLOAT WidthScale, const U_PSEUDO_OBJ *Clcod)
 Create and set a U_PMF_CUSTOMLINECAPDATA PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_CUSTOMLINECAPOPTIONALDATA_set (const U_PSEUDO_OBJ *Fill, const U_PSEUDO_OBJ *Line)
 Create and set a U_PMF_CUSTOMLINECAPOPTIONALDATA PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_CUSTOMSTARTCAPDATA_set (const U_PSEUDO_OBJ *Clc)
 Create and set a U_PMF_CUSTOMSTARTCAPDATA PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_DASHEDLINEDATA_set (int32_t Elements, const U_FLOAT *Lengths)
 Create and set a U_PMF_DASHEDLINEDATA PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_DASHEDLINEDATA_set2 (U_FLOAT Unit, int StdPat)
 Utility function to create and set a U_PMF_DASHEDLINEDATA PseudoObject from one of a predefined set of patterns. More...
 
U_PSEUDO_OBJU_PMF_FILLPATHOBJ_set (const U_PSEUDO_OBJ *Path)
 Create and set a U_PMF_FILLPATHOBJ PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_FOCUSSCALEDATA_set (U_FLOAT ScaleX, U_FLOAT ScaleY)
 Create and set a U_PMF_FOCUSSCALEDATA PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_GRAPHICSVERSION_set (int GrfVersion)
 Create and set a U_PMF_GRAPHICSVERSION object (Signature always set to 0xDBC01) More...
 
U_PMF_GRAPHICSVERSION U_PMF_GRAPHICSVERSIONOBJ_set (int GrfVersion)
 Create and set a U_PMF_GRAPHICSVERSION object Structure (Signature always set to 0xDBC01) More...
 
U_PSEUDO_OBJU_PMF_HATCHBRUSHDATA_set (uint32_t Style, const U_PSEUDO_OBJ *Fg, const U_PSEUDO_OBJ *Bg)
 Create and set a U_PMF_HATCHBRUSHDATA PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_INTEGER7_set (int Value)
 Create and set a U_PMF_INTEGER7 PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_INTEGER15_set (int Value)
 Create and set a U_PMF_INTEGER15 PseudoObject. More...
 
U_PMF_LANGUAGEIDENTIFIER U_PMF_LANGUAGEIDENTIFIEROBJ_set (int SubLId, int PriLId)
 Create and set a U_PMF_LANGUAGEIDENTIFIER value in 4 byte unsigned int, in NATIVE byte order. More...
 
U_PSEUDO_OBJU_PMF_LANGUAGEIDENTIFIER_set (U_PMF_LANGUAGEIDENTIFIER LId)
 Create and set a U_PMF_LANGUAGEIDENTIFIER PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_LINEARGRADIENTBRUSHDATA_set (const U_PMF_LINEARGRADIENTBRUSHDATA *Lgbd, const U_PSEUDO_OBJ *Lgbod)
 Create and set a U_PMF_LINEARGRADIENTBRUSHDATA PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_LINEARGRADIENTBRUSHOPTIONALDATA_set (uint32_t *Flags, const U_PSEUDO_OBJ *Tm, const U_PSEUDO_OBJ *Bc, const U_PSEUDO_OBJ *BfH, const U_PSEUDO_OBJ *BfV)
 Create and set a U_PMF_LINEARGRADIENTBRUSHOPTIONALDATA PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_LINEPATH_set (const U_PSEUDO_OBJ *Path)
 Create and set a U_PMF_LINEPATH PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_METAFILE_set (void)
 Create and set a U_PMF_METAFILE object (NOT SUPPORTED!) More...
 
U_PSEUDO_OBJU_PMF_PALETTE_set (uint32_t Flags, uint32_t Elements, const U_PMF_ARGB *Pd)
 Create and set a U_PMF_PALETTE PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_PATHGRADIENTBRUSHDATA_set (uint32_t Flags, int32_t WrapMode, U_PMF_ARGB CenterColor, U_PMF_POINTF Center, const U_PSEUDO_OBJ *Gradient, const U_PSEUDO_OBJ *Boundary, const U_PSEUDO_OBJ *Data)
 Create and set a U_PMF_PATHGRADIENTBRUSHDATA PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_PATHGRADIENTBRUSHOPTIONALDATA_set (uint32_t Flags, const U_PSEUDO_OBJ *Tm, const U_PSEUDO_OBJ *Pd, const U_PSEUDO_OBJ *Fsd)
 Create and set a U_PMF_PATHGRADIENTBRUSHOPTIONALDATA PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_PATHPOINTTYPE_set (uint32_t Elements, const uint8_t *Ppt)
 Create and set an ARRAY of U_PMF_PATHPOINTTYPE objects. More...
 
U_PSEUDO_OBJU_PMF_PATHPOINTTYPE_set2 (uint32_t Elements, uint8_t First, uint8_t Others)
 Create and set an ARRAY of U_PMF_PATHPOINTTYPE objects, with a preceding Elements count. More...
 
U_PSEUDO_OBJU_PMF_PATHPOINTTYPERLE_set (uint32_t Elements, const uint8_t *Bz, const uint8_t *RL, const uint8_t *Ppte)
 Create and set an ARRAY of U_PMF_PATHPOINTTYPERLE objects. More...
 
U_PSEUDO_OBJU_PMF_PENDATA_set (uint32_t Unit, U_FLOAT Width, const U_PSEUDO_OBJ *Pod)
 Create and set a U_PMF_PENDATA PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_PENOPTIONALDATA_set (uint32_t Flags, U_PSEUDO_OBJ *Tm, int32_t StartCap, int32_t EndCap, uint32_t Join, U_FLOAT MiterLimit, int32_t Style, int32_t DLCap, U_FLOAT DLOffset, U_PSEUDO_OBJ *DLData, int32_t PenAlignment, U_PSEUDO_OBJ *CmpndLineData, U_PSEUDO_OBJ *CSCapData, U_PSEUDO_OBJ *CECapData)
 Create and set a U_PMF_PENOPTIONALDATA PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_POINT_set (uint32_t Elements, const U_PMF_POINT *Coords)
 Create and set an ARRAY of U_PMF_POINT objects. More...
 
U_PSEUDO_OBJU_PMF_POINTF_set (uint32_t Elements, const U_PMF_POINTF *Coords)
 Create and set an ARRAY of U_PMF_POINTF objects, with a leading Elements value. More...
 
U_PSEUDO_OBJU_PMF_POINTR_set (uint32_t Elements, const U_PMF_POINTF *Coords)
 Create and set an ARRAY of U_PMF_POINTR objects. More...
 
U_PSEUDO_OBJU_PMF_RECT4_set (int16_t X, int16_t Y, int16_t Width, int16_t Height)
 Create and set a U_PMF_RECT object. More...
 
U_PSEUDO_OBJU_PMF_RECT_set (U_PMF_RECT *Rect)
 Create and set a U_PMF_RECT object. More...
 
U_PSEUDO_OBJU_PMF_RECTN_set (uint32_t Elements, U_PMF_RECT *Rects)
 Create and set an array of U_PMF_RECT objects in a PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_RECTF4_set (U_FLOAT X, U_FLOAT Y, U_FLOAT Width, U_FLOAT Height)
 Create and set a U_PMF_RECTF object in a PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_RECTF_set (U_PMF_RECTF *Rect)
 Create and set a U_PMF_RECTF object in a PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_RECTFN_set (uint32_t Elements, U_PMF_RECTF *Rects)
 Create and set an array of U_PMF_RECTF objects in a PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_REGIONNODE_set (int32_t Type, const U_PSEUDO_OBJ *Rnd)
 Create and set a U_PMF_REGIONNODE PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_REGIONNODECHILDNODES_set (const U_PSEUDO_OBJ *Left, const U_PSEUDO_OBJ *Right)
 Create and set a U_PMF_REGIONNODECHILDNODES PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_REGIONNODEPATH_set (const U_PSEUDO_OBJ *Path)
 Create and set a U_PMF_REGIONNODEPATH PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_SOLIDBRUSHDATA_set (const U_PSEUDO_OBJ *Color)
 Create and set a U_PMF_SOLIDBRUSHDATA PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_STRINGFORMATDATA_set (uint32_t TabStopCount, U_FLOAT *TabStops, const U_PSEUDO_OBJ *Ranges)
 Create and set a U_PMF_STRINGFORMATDATA PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_TEXTUREBRUSHDATA_set (uint32_t Flags, uint32_t WrapMode, const U_PSEUDO_OBJ *Tbod)
 Create and set a U_PMF_TEXTUREBRUSHDATA PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_TEXTUREBRUSHOPTIONALDATA_set (const U_PSEUDO_OBJ *Tm, const U_PSEUDO_OBJ *Image)
 Create and set a U_PMF_TEXTUREBRUSHOPTIONALDATA PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_TRANSFORMMATRIX_set (U_PMF_TRANSFORMMATRIX *Tm)
 Create and set a U_PMF_TRANSFORMMATRIX PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_IE_BLUR_set (U_FLOAT Radius, uint32_t ExpandEdge)
 Create and set a U_PMF_IE_BLUR PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_IE_BRIGHTNESSCONTRAST_set (int32_t Brightness, int32_t Contrast)
 Create and set a U_PMF_IE_BRIGHTNESSCONTRAST PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_IE_COLORBALANCE_set (int32_t CyanRed, int32_t MagentaGreen, int32_t YellowBlue)
 Create and set a U_PMF_IE_COLORBALANCE PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_IE_COLORCURVE_set (uint32_t Adjust, uint32_t Channel, int32_t Intensity)
 Create and set a U_PMF_IE_COLORCURVE PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_IE_COLORLOOKUPTABLE_set (const uint8_t *BLUT, const uint8_t *GLUT, const uint8_t *RLUT, const uint8_t *ALUT)
 Create and set a U_PMF_IE_COLORLOOKUPTABLE PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_IE_COLORMATRIX_set (const U_FLOAT *Matrix)
 Create and set a U_PMF_IE_COLORMATRIX PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_IE_HUESATURATIONLIGHTNESS_set (int32_t Hue, int32_t Saturation, int32_t Lightness)
 Create and set a U_PMF_IE_HUESATURATIONLIGHTNESS PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_IE_LEVELS_set (int32_t Highlight, int32_t Midtone, int32_t Shadow)
 Create and set a U_PMF_IE_LEVELS PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_IE_REDEYECORRECTION_set (uint32_t Elements, const U_RECTL *Rects)
 Create and set a U_PMF_IE_REDEYECORRECTION PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_IE_SHARPEN_set (U_FLOAT Radius, int32_t Sharpen)
 Create and set a U_PMF_IE_SHARPEN PseudoObject. More...
 
U_PSEUDO_OBJU_PMF_IE_TINT_set (const int32_t Hue, const int32_t Amount)
 Create and set a U_PMF_IE_TINT PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_STROKEFILLPATH_set (void)
 Create and set a U_PMR_STROKEFILLPATH PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_OFFSETCLIP_set (U_FLOAT dX, U_FLOAT dY)
 Create and set a U_PMR_OFFSETCLIP PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_RESETCLIP_set (void)
 Create and set a U_PMR_RESETCLIP PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_SETCLIPPATH_set (uint32_t PathID, uint32_t CMenum)
 Create and set a U_PMR_SETCLIPPATH PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_SETCLIPRECT_set (uint32_t CMenum, const U_PSEUDO_OBJ *Rect)
 Create and set a U_PMR_SETCLIPRECT PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_SETCLIPREGION_set (uint32_t PathID, uint32_t CMenum)
 Create and set a U_PMR_SETCLIPREGION PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_COMMENT_set (size_t cbData, const void *Data)
 Create and set a U_PMR_COMMENT PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_ENDOFFILE_set (void)
 Create and set a U_PMR_ENDOFFILE PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_GETDC_set (void)
 Create and set a U_PMR_GETDC PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_HEADER_set (int IsDual, int IsVideo, const U_PSEUDO_OBJ *Version, uint32_t LogicalDpiX, uint32_t LogicalDpiY)
 Create and set a U_PMR_HEADER PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_CLEAR_set (const U_PSEUDO_OBJ *Color)
 Create and set a U_PMR_CLEAR PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_DRAWARC_set (uint32_t PenID, U_FLOAT Start, U_FLOAT Sweep, const U_PSEUDO_OBJ *Rect)
 Create and set a U_PMR_DRAWARC PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_DRAWBEZIERS_set (uint32_t PenID, const U_PSEUDO_OBJ *Points)
 Create and set a U_PMR_DRAWBEZIERS PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_DRAWCLOSEDCURVE_set (uint32_t PenID, U_FLOAT Tension, const U_PSEUDO_OBJ *Points)
 Create and set a U_PMR_DRAWCLOSEDCURVE PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_DRAWCURVE_set (uint32_t PenID, U_FLOAT Tension, uint32_t Offset, uint32_t NSegs, const U_PSEUDO_OBJ *Points)
 Create and set a U_PMR_DRAWCURVE PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_DRAWDRIVERSTRING_set (uint32_t FontID, U_FLOAT Tension, const U_PSEUDO_OBJ *BrushID, uint32_t DSOFlags, uint32_t HasMatrix, uint32_t GlyphCount, const uint16_t *Glyphs, const U_PSEUDO_OBJ *Points, const U_PSEUDO_OBJ *Tm)
 Create and set a U_PMR_DRAWDRIVERSTRING PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_DRAWELLIPSE_set (uint32_t PenID, const U_PSEUDO_OBJ *Rect)
 Create and set a U_PMR_DRAWELLIPSE PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_DRAWIMAGE_set (uint32_t ImgID, int32_t ImgAttrID, int32_t SrcUnit, const U_PSEUDO_OBJ *SrcRect, const U_PSEUDO_OBJ *DstRect)
 Create and set a U_PMR_DRAWIMAGE PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_DRAWIMAGEPOINTS_set (uint32_t ImgID, int etype, int32_t ImgAttrID, int32_t SrcUnit, const U_PSEUDO_OBJ *SrcRect, const U_PSEUDO_OBJ *Points)
 Create and set a U_PMR_DRAWIMAGEPOINTS PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_DRAWLINES_set (uint32_t PenID, int dtype, const U_PSEUDO_OBJ *Points)
 Create and set a U_PMR_DRAWLINES PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_DRAWPATH_set (uint32_t PathID, uint32_t PenID)
 Create and set a U_PMR_DRAWPATH PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_DRAWPIE_set (uint32_t PenID, U_FLOAT Start, U_FLOAT Sweep, const U_PSEUDO_OBJ *Rect)
 Create and set a U_PMR_DRAWPIE PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_DRAWRECTS_set (uint32_t PenID, const U_PSEUDO_OBJ *Rects)
 Create and set a U_PMR_DRAWRECTS PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_DRAWSTRING_set (uint32_t FontID, const U_PSEUDO_OBJ *BrushID, uint32_t FormatID, uint32_t Length, const U_PSEUDO_OBJ *Rect, const uint16_t *Text)
 Create and set a U_PMR_DRAWSTRING PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_FILLCLOSEDCURVE_set (int ftype, U_FLOAT Tension, const U_PSEUDO_OBJ *BrushID, const U_PSEUDO_OBJ *Points)
 Create and set a U_PMR_FILLCLOSEDCURVE PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_FILLELLIPSE_set (const U_PSEUDO_OBJ *BrushID, const U_PSEUDO_OBJ *Rect)
 Create and set a U_PMR_FILLELLIPSE PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_FILLPATH_set (uint32_t PathID, const U_PSEUDO_OBJ *BrushID)
 Create and set a U_PMR_FILLPATH PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_FILLPIE_set (U_FLOAT Start, U_FLOAT Sweep, const U_PSEUDO_OBJ *BrushID, const U_PSEUDO_OBJ *Rect)
 Create and set a U_PMR_FILLPIE PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_FILLPOLYGON_set (const U_PSEUDO_OBJ *BrushID, const U_PSEUDO_OBJ *Points)
 Create and set a U_PMR_FILLPOLYGON PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_FILLRECTS_set (const U_PSEUDO_OBJ *BrushID, const U_PSEUDO_OBJ *Rects)
 Create and set a U_PMR_FILLRECTS PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_FILLREGION_set (uint32_t RgnID, const U_PSEUDO_OBJ *BrushID)
 Create and set a U_PMR_FILLREGION PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_OBJECT_PO_set (uint32_t ObjID, U_PSEUDO_OBJ *Po)
 Create and set a U_PMR_OBJECT PseudoObject from another PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_OBJECT_set (uint32_t ObjID, int otype, int ntype, uint32_t TSize, size_t cbData, const char *Data)
 Create and set a U_PMR_OBJECT PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_SERIALIZABLEOBJECT_set (const U_PSEUDO_OBJ *Siepb)
 Create and set a U_PMR_SERIALIZABLEOBJECT PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_SETANTIALIASMODE_set (int SMenum, int aatype)
 Create and set a U_PMR_SETANTIALIASMODE PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_SETCOMPOSITINGMODE_set (int CMenum)
 Create and set a U_PMR_SETCOMPOSITINGMODE PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_SETCOMPOSITINGQUALITY_set (int CQenum)
 Create and set a U_PMR_SETCOMPOSITINGQUALITY PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_SETINTERPOLATIONMODE_set (int IMenum)
 Create and set a U_PMR_SETINTERPOLATIONMODE PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_SETPIXELOFFSETMODE_set (int POMenum)
 Create and set a U_PMR_SETPIXELOFFSETMODE PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_SETRENDERINGORIGIN_set (int32_t X, int32_t Y)
 Create and set a U_PMR_SETRENDERINGORIGIN PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_SETTEXTCONTRAST_set (int TGC)
 Create and set a U_PMR_SETTEXTCONTRAST PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_SETTEXTRENDERINGHINT_set (int TRHenum)
 Create and set a U_PMR_SETTEXTRENDERINGHINT PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_BEGINCONTAINER_set (int UTenum, U_PSEUDO_OBJ *DstRect, U_PSEUDO_OBJ *SrcRect, uint32_t StackID)
 Create and set a U_PMR_BEGINCONTAINER PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_BEGINCONTAINERNOPARAMS_set (int StackID)
 Create and set a U_PMR_BEGINCONTAINERNOPARAMS PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_ENDCONTAINER_set (int StackID)
 Create and set a U_PMR_ENDCONTAINER PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_RESTORE_set (int StackID)
 Create and set a U_PMR_RESTORE PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_SAVE_set (int StackID)
 Create and set a U_PMR_SAVE PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_SETTSCLIP_set (U_PSEUDO_OBJ *Rects)
 Create and set a U_PMR_SETTSCLIP PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_SETTSGRAPHICS_set (int vgatype, U_PMF_SETTSGRAPHICS *Tsg, U_PSEUDO_OBJ *Palette)
 Create and set a U_PMR_SETTSGRAPHICS PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_MULTIPLYWORLDTRANSFORM_set (int xmtype, U_PSEUDO_OBJ *Tm)
 Create and set a U_PMR_MULTIPLYWORLDTRANSFORM PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_RESETWORLDTRANSFORM_set (void)
 Create and set a U_PMR_RESETWORLDTRANSFORM PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_ROTATEWORLDTRANSFORM_set (int xmtype, U_FLOAT Angle)
 Create and set a U_PMR_ROTATEWORLDTRANSFORM PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_SCALEWORLDTRANSFORM_set (int xmtype, U_FLOAT X, U_FLOAT Y)
 Create and set a U_PMR_SCALEWORLDTRANSFORM PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_SETPAGETRANSFORM_set (int PUenum, U_FLOAT Scale)
 Create and set a U_PMR_SETPAGETRANSFORM PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_SETWORLDTRANSFORM_set (U_PSEUDO_OBJ *Tm)
 Create and set a U_PMR_SETWORLDTRANSFORM PseudoObject. More...
 
U_PSEUDO_OBJU_PMR_TRANSLATEWORLDTRANSFORM_set (int xmtype, U_FLOAT Dx, U_FLOAT Dy)
 Create and set a U_PMR_TRANSLATEWORLDTRANSFORM PseudoObject. More...
 
int U_PMF_BRUSH_get (const char *contents, uint32_t *Version, uint32_t *Type, const char **Data)
 Get data from a U_PMF_BRUSH object. More...
 
int U_PMF_CUSTOMLINECAP_get (const char *contents, uint32_t *Version, uint32_t *Type, const char **Data)
 Get data from a U_PMF_CUSTOMLINECAP object. More...
 
int U_PMF_FONT_get (const char *contents, uint32_t *Version, U_FLOAT *EmSize, uint32_t *SizeUnit, int32_t *FSFlags, uint32_t *Length, const char **Data)
 Get data from a U_PMF_FONT object. More...
 
int U_PMF_IMAGE_get (const char *contents, uint32_t *Version, uint32_t *Type, const char **Data)
 Get data from a U_PMF_IMAGE object. More...
 
int U_PMF_IMAGEATTRIBUTES_get (const char *contents, uint32_t *Version, uint32_t *WrapMode, uint32_t *ClampColor, uint32_t *ObjectClamp)
 Get data from a U_PMF_IMAGEATTRIBUTES object. More...
 
int U_PMF_PATH_get (const char *contents, uint32_t *Version, uint32_t *Count, uint16_t *Flags, const char **Points, const char **Types)
 Get data from a U_PMF_PATH object. More...
 
int U_PMF_PEN_get (const char *contents, uint32_t *Version, uint32_t *Type, const char **PenData, const char **Brush)
 Get data from a U_PMF_PEN object. More...
 
int U_PMF_REGION_get (const char *contents, uint32_t *Version, uint32_t *Count, const char **Nodes)
 Get data from a U_PMF_REGION object. More...
 
int U_PMF_STRINGFORMAT_get (const char *contents, U_PMF_STRINGFORMAT *Sfs, const char **Data)
 Get data from a U_PMF_STRINGFORMAT object. More...
 
int U_PMF_ARGB_get (const char *contents, uint8_t *Blue, uint8_t *Green, uint8_t *Red, uint8_t *Alpha)
 Get data from a U_PMF_ARGB object. More...
 
int U_PMF_BITMAP_get (const char *contents, U_PMF_BITMAP *Bs, const char **Data)
 Get data from a U_PMF_BITMAP object. More...
 
int U_PMF_BITMAPDATA_get (const char *contents, U_PMF_PALETTE *Ps, const char **Colors, const char **Data)
 Get data from a U_PMF_BITMAPDATA object. More...
 
int U_PMF_BLENDCOLORS_get (const char *contents, uint32_t *Elements, U_FLOAT **Positions, const char **Colors)
 Get data from a U_PMF_BLENDCOLORS object. More...
 
int U_PMF_BLENDFACTORS_get (const char *contents, uint32_t *Elements, U_FLOAT **Positions, U_FLOAT **Factors)
 Get data from a U_PMF_BLENDFACTORS object. More...
 
int U_PMF_BOUNDARYPATHDATA_get (const char *contents, int32_t *Size, const char **Data)
 Get data from a U_PMF_BOUNDARYPATHDATA object. More...
 
int U_PMF_BOUNDARYPOINTDATA_get (const char *contents, int32_t *Elements, U_PMF_POINTF **Points)
 Get data from a U_PMF_BOUNDARYPOINTDATA object. More...
 
int U_PMF_CHARACTERRANGE_get (const char *contents, int32_t *First, int32_t *Length)
 Get data from a U_PMF_CHARACTERRANGE object. More...
 
int U_PMF_COMPOUNDLINEDATA_get (const char *contents, int32_t *Elements, U_FLOAT **Widths)
 Get data from a U_PMF_COMPOUNDLINEDATA object. More...
 
int U_PMF_COMPRESSEDIMAGE_get (const char *contents, const char **Data)
 Get data from a U_PMF_COMPRESSEDIMAGE object. More...
 
int U_PMF_CUSTOMENDCAPDATA_get (const char *contents, int32_t *Size, const char **Data)
 Get data from a U_PMF_CUSTOMENDCAPDATA object. More...
 
int U_PMF_CUSTOMLINECAPARROWDATA_get (const char *contents, U_PMF_CUSTOMLINECAPARROWDATA *Ccad)
 Get data from a U_PMF_CUSTOMLINECAPARROWDATA object. More...
 
int U_PMF_CUSTOMLINECAPDATA_get (const char *contents, U_PMF_CUSTOMLINECAPDATA *Clcd, const char **Data)
 Get data from a U_PMF_CUSTOMLINECAPDATA object. More...
 
int U_PMF_CUSTOMLINECAPOPTIONALDATA_get (const char *contents, uint32_t Flags, const char **FillData, const char **LineData)
 Get data from a U_PMF_CUSTOMLINECAPOPTIONALDATA object. More...
 
int U_PMF_CUSTOMSTARTCAPDATA_get (const char *contents, int32_t *Size, const char **Data)
 Get data from a U_PMF_CUSTOMSTARTCAPDATA object. More...
 
int U_PMF_DASHEDLINEDATA_get (const char *contents, int32_t *Elements, U_FLOAT **Lengths)
 Get data from a U_PMF_DASHEDLINEDATA object. More...
 
int U_PMF_FILLPATHOBJ_get (const char *contents, int32_t *Size, const char **Data)
 Get data from a U_PMF_FILLPATHOBJ object. More...
 
int U_PMF_FOCUSSCALEDATA_get (const char *contents, uint32_t *Count, U_FLOAT *ScaleX, U_FLOAT *ScaleY)
 Get data from a U_PMF_FOCUSSCALEDATA object. More...
 
int U_PMF_GRAPHICSVERSION_get (const char *contents, int *Signature, int *GrfVersion)
 Get data from a U_PMF_GRAPHICSVERSION object. More...
 
int U_PMF_HATCHBRUSHDATA_get (const char *contents, uint32_t *Style, U_PMF_ARGB *Foreground, U_PMF_ARGB *Background)
 Get data from a U_PMF_HATCHBRUSHDATA object. More...
 
int U_PMF_INTEGER7_get (const char **contents, U_FLOAT *Value)
 Get data from a U_PMF_INTEGER7 object. More...
 
int U_PMF_INTEGER15_get (const char **contents, U_FLOAT *Value)
 Get data from a U_PMF_INTEGER15 object. More...
 
int U_PMF_LANGUAGEIDENTIFIER_get (U_PMF_LANGUAGEIDENTIFIER LId, int *SubLId, int *PriLId)
 Get data from a U_PMF_LANGUAGEIDENTIFIER object. More...
 
int U_PMF_LINEARGRADIENTBRUSHDATA_get (const char *contents, U_PMF_LINEARGRADIENTBRUSHDATA *Lgbd, const char **Data)
 Get data from a U_PMF_LINEARGRADIENTBRUSHDATA object. More...
 
int U_PMF_LINEARGRADIENTBRUSHOPTIONALDATA_get (const char *contents, uint32_t Flags, U_PMF_TRANSFORMMATRIX *Tm, const char **Bc, const char **BfH, const char **BfV)
 Get data from a U_PMF_LINEARGRADIENTBRUSHOPTIONALDATA object. More...
 
int U_PMF_LINEPATH_get (const char *contents, int32_t *Size, const char **Data)
 Get data from a U_PMF_LINEPATH object. More...
 
int U_PMF_METAFILE_get (const char *contents, uint32_t *Type, uint32_t *Size, const char **Data)
 Get data from a U_PMF_METAFILE object. More...
 
int U_PMF_PALETTE_get (const char *contents, uint32_t *Flags, uint32_t *Elements, const char **Colors)
 Get data from a U_PMF_PALETTE object. More...
 
int U_PMF_PATHGRADIENTBRUSHDATA_get (const char *contents, U_PMF_PATHGRADIENTBRUSHDATA *Pgbd, const char **Gradient, const char **Boundary, const char **Data)
 Get data from a U_PMF_PATHGRADIENTBRUSHDATA object. More...
 
int U_PMF_PATHGRADIENTBRUSHOPTIONALDATA_get (const char *contents, uint32_t Flags, U_PMF_TRANSFORMMATRIX *Matrix, const char **Pattern, const char **Data)
 Get data from a U_PMF_PATHGRADIENTBRUSHOPTIONALDATA object. More...
 
int U_PMF_PATHPOINTTYPE_get (const char *contents, int *Flags, int *Type)
 Get data from a U_PMF_PATHPOINTTYPE object. More...
 
int U_PMF_PATHPOINTTYPERLE_get (const char *contents, int *Bezier, int *RL, int *Ppt)
 Get data from a U_PMF_PATHPOINTTYPERLE object. More...
 
int U_PMF_PENDATA_get (const char *contents, uint32_t *Flags, uint32_t *Unit, U_FLOAT *Width, const char **Data)
 Get data from a U_PMF_PENDATA object. More...
 
int U_PMF_PENOPTIONALDATA_get (const char *contents, uint32_t Flags, U_PMF_TRANSFORMMATRIX *Matrix, int32_t *StartCap, int32_t *EndCap, uint32_t *Join, U_FLOAT *MiterLimit, int32_t *Style, int32_t *DLCap, U_FLOAT *DLOffset, const char **DLData, int32_t *Alignment, const char **CmpndLineData, const char **CSCapData, const char **CECapData)
 Get data from a U_PMF_PENOPTIONALDATA object. More...
 
int U_PMF_POINT_get (const char **contents, U_FLOAT *X, U_FLOAT *Y)
 Get data from a U_PMF_POINT object. More...
 
int U_PMF_POINTF_get (const char **contents, U_FLOAT *X, U_FLOAT *Y)
 Get data from a U_PMF_POINTF object. More...
 
int U_PMF_POINTR_get (const char **contents, U_FLOAT *X, U_FLOAT *Y)
 Get data from a U_PMF_POINTR object. More...
 
int U_PMF_VARPOINTS_get (const char **contents, uint16_t Flags, int Elements, U_PMF_POINTF **Points)
 Get data from a variable POINTS object, which may be U_PMF_POINTS, U_PMF_POINTF, or U_PMF_POINTR. More...
 
int U_PMF_RECT_get (const char **contents, int16_t *X, int16_t *Y, int16_t *Width, int16_t *Height)
 Get data from a U_PMF_RECT object. More...
 
int U_PMF_RECTF_get (const char **contents, U_FLOAT *X, U_FLOAT *Y, U_FLOAT *Width, U_FLOAT *Height)
 Get data from a U_PMF_RECTF object. More...
 
int U_PMF_VARRECTS_get (const char **contents, uint16_t Flags, int Elements, U_PMF_RECTF **Rects)
 Get data from a variable RECTS object, which may be U_PMF_RECT or U_PMF_RECTF. More...
 
int U_PMF_REGIONNODE_get (const char *contents, uint32_t *Type, const char **Data)
 Get data from a U_PMF_REGIONNODE object. More...
 
int U_PMF_REGIONNODEPATH_get (const char *contents, int32_t *Size, const char **Data)
 Get data from a U_PMF_REGIONNODEPATH object. More...
 
int U_PMF_SOLIDBRUSHDATA_get (const char *contents, U_PMF_ARGB *Color)
 Get data from a U_PMF_SOLIDBRUSHDATA object. More...
 
int U_PMF_STRINGFORMATDATA_get (const char *contents, uint32_t TabStopCount, uint32_t RangeCount, const U_FLOAT **TabStops, const U_PMF_CHARACTERRANGE **CharRange)
 Get data from a U_PMF_STRINGFORMATDATA object. More...
 
int U_PMF_TEXTUREBRUSHDATA_get (const char *contents, uint32_t *Flags, int32_t *WrapMode, const char **Data)
 Get data from a U_PMF_TEXTUREBRUSHDATA object. More...
 
int U_PMF_TEXTUREBRUSHOPTIONALDATA_get (const char *contents, int HasImage, U_PMF_TRANSFORMMATRIX *Matrix, const char **Image)
 Get data from a U_PMF_TEXTUREBRUSHOPTIONALDATA object. More...
 
int U_PMF_TRANSFORMMATRIX_get (const char *contents, U_PMF_TRANSFORMMATRIX *Matrix)
 Get data from a U_PMF_TRANSFORMMATRIX object. More...
 
int U_PMF_IE_BLUR_get (const char *contents, U_FLOAT *Radius, uint32_t *ExpandEdge)
 Get data from a U_PMF_IE_BLUR object. More...
 
int U_PMF_IE_BRIGHTNESSCONTRAST_get (const char *contents, int32_t *Brightness, int32_t *Contrast)
 Get data from a U_PMF_IE_BRIGHTNESSCONTRAST object. More...
 
int U_PMF_IE_COLORBALANCE_get (const char *contents, int32_t *CyanRed, int32_t *MagentaGreen, int32_t *YellowBlue)
 Get data from a U_PMF_IE_COLORBALANCE object. More...
 
int U_PMF_IE_COLORCURVE_get (const char *contents, uint32_t *Adjust, uint32_t *Channel, int32_t *Intensity)
 Get data from a U_PMF_IE_COLORCURVE object. More...
 
int U_PMF_IE_COLORLOOKUPTABLE_get (const char *contents, const uint8_t **BLUT, const uint8_t **GLUT, const uint8_t **RLUT, const uint8_t **ALUT)
 Get data from a U_PMF_IE_COLORLOOKUPTABLE object. More...
 
int U_PMF_IE_COLORMATRIX_get (const char *contents, U_PMF_IE_COLORMATRIX *Matrix)
 Get data from a U_PMF_IE_COLORMATRIX object. More...
 
int U_PMF_IE_HUESATURATIONLIGHTNESS_get (const char *contents, int32_t *Hue, int32_t *Saturation, int32_t *Lightness)
 Get data from a U_PMF_IE_HUESATURATIONLIGHTNESS object. More...
 
int U_PMF_IE_LEVELS_get (const char *contents, int32_t *Highlight, int32_t *Midtone, int32_t *Shadow)
 Get data from a U_PMF_IE_LEVELS object. More...
 
int U_PMF_IE_REDEYECORRECTION_get (const char *contents, int32_t *Elements, U_RECTL **Rects)
 Get data from a U_PMF_IE_REDEYECORRECTION object. More...
 
int U_PMF_IE_SHARPEN_get (const char *contents, U_FLOAT *Radius, int32_t *Sharpen)
 Get data from a U_PMF_IE_SHARPEN object. More...
 
int U_PMF_IE_TINT_get (const char *contents, int32_t *Hue, int32_t *Amount)
 Get data from a U_PMF_IE_TINT object. More...
 
int U_PMR_OFFSETCLIP_get (const char *contents, U_PMF_CMN_HDR *Header, U_FLOAT *dX, U_FLOAT *dY)
 Get data from a U_PMR_OFFSETCLIP record. More...
 
int U_PMR_RESETCLIP_get (const char *contents, U_PMF_CMN_HDR *Header)
 Get data from a U_PMR_RESETCLIP record. More...
 
int U_PMR_SETCLIPPATH_get (const char *contents, U_PMF_CMN_HDR *Header, uint32_t *PathID, int *CMenum)
 Get data from a U_PMR_SETCLIPPATH record. More...
 
int U_PMR_SETCLIPRECT_get (const char *contents, U_PMF_CMN_HDR *Header, int *CMenum, U_PMF_RECTF *Rect)
 Get data from a U_PMR_SETCLIPRECT record. More...
 
int U_PMR_SETCLIPREGION_get (const char *contents, U_PMF_CMN_HDR *Header, uint32_t *PathID, int *CMenum)
 Get data from a U_PMR_SETCLIPREGION record. More...
 
int U_PMR_COMMENT_get (const char *contents, U_PMF_CMN_HDR *Header, const char **Data)
 Get data from a U_PMR_COMMENT record. More...
 
int U_PMR_ENDOFFILE_get (const char *contents, U_PMF_CMN_HDR *Header)
 Get data from a U_PMR_ENDOFFILE record. More...
 
int U_PMR_GETDC_get (const char *contents, U_PMF_CMN_HDR *Header)
 Get data from a U_PMR_GETDC record. More...
 
int U_PMR_HEADER_get (const char *contents, U_PMF_CMN_HDR *Header, U_PMF_GRAPHICSVERSION *Version, int *IsDual, int *IsVideo, uint32_t *LogicalDpiX, uint32_t *LogicalDpiY)
 Get data from a U_PMR_HEADER record. More...
 
int U_PMR_CLEAR_get (const char *contents, U_PMF_CMN_HDR *Header, U_PMF_ARGB *Color)
 Get data from a U_PMR_CLEAR record. More...
 
int U_PMR_DRAWARC_get (const char *contents, U_PMF_CMN_HDR *Header, uint32_t *PenID, int *ctype, U_FLOAT *Start, U_FLOAT *Sweep, U_PMF_RECTF *Rect)
 Get data from a U_PMR_DRAWARC record. More...
 
int U_PMR_DRAWBEZIERS_get (const char *contents, U_PMF_CMN_HDR *Header, uint32_t *PenID, int *ctype, int *RelAbs, uint32_t *Elements, U_PMF_POINTF **Points)
 Get data from a U_PMR_DRAWBEZIERS record. More...
 
int U_PMR_DRAWCLOSEDCURVE_get (const char *contents, U_PMF_CMN_HDR *Header, uint32_t *PenID, int *ctype, int *RelAbs, U_FLOAT *Tension, uint32_t *Elements, U_PMF_POINTF **Points)
 Get data from a U_PMR_DRAWCLOSEDCURVE record. More...
 
int U_PMR_DRAWCURVE_get (const char *contents, U_PMF_CMN_HDR *Header, uint32_t *PenID, int *ctype, U_FLOAT *Tension, uint32_t *Offset, uint32_t *NSegs, uint32_t *Elements, U_PMF_POINTF **Points)
 Get data from a U_PMR_DRAWCURVE record. More...
 
int U_PMR_DRAWDRIVERSTRING_get (const char *contents, U_PMF_CMN_HDR *Header, uint32_t *FontID, int *btype, U_FLOAT *Tension, uint32_t *BrushID, uint32_t *DSOFlags, uint32_t *HasMatrix, uint32_t *Elements, uint16_t **Glyphs, U_PMF_POINTF **Points, U_PMF_TRANSFORMMATRIX **Matrix)
 Get data from a U_PMR_DRAWDRIVERSTRING record. More...
 
int U_PMR_DRAWELLIPSE_get (const char *contents, U_PMF_CMN_HDR *Header, uint32_t *PenID, int *ctype, U_PMF_RECTF *Rect)
 Get data from a U_PMR_DRAWELLIPSE record. More...
 
int U_PMR_DRAWIMAGE_get (const char *contents, U_PMF_CMN_HDR *Header, uint32_t *ImgID, int *ctype, uint32_t *ImgAttrID, int32_t *SrcUnit, U_PMF_RECTF *SrcRect, U_PMF_RECTF *DstRect)
 Get data from a U_PMR_DRAWIMAGE record. More...
 
int U_PMR_DRAWIMAGEPOINTS_get (const char *contents, U_PMF_CMN_HDR *Header, uint32_t *ImgID, int *ctype, int *etype, int *RelAbs, uint32_t *ImgAttrID, int32_t *SrcUnit, U_PMF_RECTF *SrcRect, uint32_t *Elements, U_PMF_POINTF **Points)
 Get data from a U_PMR_DRAWIMAGEPOINTS record. More...
 
int U_PMR_DRAWLINES_get (const char *contents, U_PMF_CMN_HDR *Header, uint32_t *PenID, int *ctype, int *dtype, int *RelAbs, uint32_t *Elements, U_PMF_POINTF **Points)
 Get data from a U_PMR_DRAWLINES record. More...
 
int U_PMR_DRAWPATH_get (const char *contents, U_PMF_CMN_HDR *Header, uint32_t *PathID, uint32_t *PenID)
 Get data from a U_PMR_DRAWPATH record. More...
 
int U_PMR_DRAWPIE_get (const char *contents, U_PMF_CMN_HDR *Header, uint32_t *PenID, int *ctype, U_FLOAT *Start, U_FLOAT *Sweep, U_PMF_RECTF *Rect)
 Get data from a U_PMR_DRAWPIE record. More...
 
int U_PMR_DRAWRECTS_get (const char *contents, U_PMF_CMN_HDR *Header, uint32_t *PenID, int *ctype, uint32_t *Elements, U_PMF_RECTF **Rects)
 Get data from a U_PMR_DRAWRECTS record. More...
 
int U_PMR_DRAWSTRING_get (const char *contents, U_PMF_CMN_HDR *Header, uint32_t *FontID, int *btype, uint32_t *BrushID, uint32_t *FormatID, uint32_t *Elements, U_PMF_RECTF *Rect, uint16_t **String)
 Get data from a U_PMR_DRAWSTRING record. More...
 
int U_PMR_FILLCLOSEDCURVE_get (const char *contents, U_PMF_CMN_HDR *Header, int *btype, int *ctype, int *ftype, int *RelAbs, uint32_t *BrushID, U_FLOAT *Tension, uint32_t *Elements, U_PMF_POINTF **Points)
 Get data from a U_PMR_FILLCLOSEDCURVE record. More...
 
int U_PMR_FILLELLIPSE_get (const char *contents, U_PMF_CMN_HDR *Header, int *btype, int *ctype, uint32_t *BrushID, U_PMF_RECTF *Rect)
 Get data from a U_PMR_FILLELLIPSE record. More...
 
int U_PMR_FILLPATH_get (const char *contents, U_PMF_CMN_HDR *Header, uint32_t *PathID, int *btype, uint32_t *BrushID)
 Get data from a U_PMR_FILLPATH record. More...
 
int U_PMR_FILLPIE_get (const char *contents, U_PMF_CMN_HDR *Header, int *btype, int *ctype, uint32_t *BrushID, U_FLOAT *Start, U_FLOAT *Sweep, U_PMF_RECTF *Rect)
 Get data from a U_PMR_FILLPIE record. More...
 
int U_PMR_FILLPOLYGON_get (const char *contents, U_PMF_CMN_HDR *Header, int *btype, int *ctype, int *RelAbs, uint32_t *BrushID, uint32_t *Elements, U_PMF_POINTF **Points)
 Get data from a U_PMR_FILLPOLYGON record. More...
 
int U_PMR_FILLRECTS_get (const char *contents, U_PMF_CMN_HDR *Header, int *btype, int *ctype, uint32_t *BrushID, uint32_t *Elements, U_PMF_RECTF **Rects)
 Get data from a U_PMR_FILLRECTS record. More...
 
int U_PMR_FILLREGION_get (const char *contents, U_PMF_CMN_HDR *Header, uint32_t *RgnID, int *btype, int *ctype, uint32_t *BrushID)
 Get data from a U_PMR_FILLREGION record. More...
 
int U_PMR_OBJECT_get (const char *contents, U_PMF_CMN_HDR *Header, uint32_t *ObjID, int *otype, int *ntype, uint32_t *TSize, const char **Data)
 Get data from a U_PMR_OBJECT record. More...
 
int U_PMR_SERIALIZABLEOBJECT_get (const char *contents, U_PMF_CMN_HDR *Header, uint8_t *GUID, uint32_t *Size, const char **Data)
 Get data from a U_PMR_SERIALIZABLEOBJECT record. More...
 
int U_PMR_SETANTIALIASMODE_get (const char *contents, U_PMF_CMN_HDR *Header, int *SMenum, int *aatype)
 Get data from a U_PMR_SETANTIALIASMODE record. More...
 
int U_PMR_SETCOMPOSITINGMODE_get (const char *contents, U_PMF_CMN_HDR *Header, int *CMenum)
 Get data from a U_PMR_SETCOMPOSITINGMODE record. More...
 
int U_PMR_SETCOMPOSITINGQUALITY_get (const char *contents, U_PMF_CMN_HDR *Header, int *CQenum)
 Get data from a U_PMR_SETCOMPOSITINGQUALITY record. More...
 
int U_PMR_SETINTERPOLATIONMODE_get (const char *contents, U_PMF_CMN_HDR *Header, int *IMenum)
 Get data from a U_PMR_SETINTERPOLATIONMODE record. More...
 
int U_PMR_SETPIXELOFFSETMODE_get (const char *contents, U_PMF_CMN_HDR *Header, int *POMenum)
 Get data from a U_PMR_SETPIXELOFFSETMODE record. More...
 
int U_PMR_SETRENDERINGORIGIN_get (const char *contents, U_PMF_CMN_HDR *Header, int32_t *X, int32_t *Y)
 Get data from a U_PMR_SETRENDERINGORIGIN record. More...
 
int U_PMR_SETTEXTCONTRAST_get (const char *contents, U_PMF_CMN_HDR *Header, int *TGC)
 Get data from a U_PMR_SETTEXTCONTRAST record. More...
 
int U_PMR_SETTEXTRENDERINGHINT_get (const char *contents, U_PMF_CMN_HDR *Header, int *TRHenum)
 Get data from a U_PMR_SETTEXTRENDERINGHINT record. More...
 
int U_PMR_BEGINCONTAINER_get (const char *contents, U_PMF_CMN_HDR *Header, int *UTenum, U_PMF_RECTF *DstRect, U_PMF_RECTF *SrcRect, uint32_t *StackID)
 Get data from a U_PMR_BEGINCONTAINER record. More...
 
int U_PMR_BEGINCONTAINERNOPARAMS_get (const char *contents, U_PMF_CMN_HDR *Header, uint32_t *StackID)
 Get data from a U_PMR_BEGINCONTAINERNOPARAMS record. More...
 
int U_PMR_ENDCONTAINER_get (const char *contents, U_PMF_CMN_HDR *Header, uint32_t *StackID)
 Get data from a U_PMR_ENDCONTAINER record. More...
 
int U_PMR_RESTORE_get (const char *contents, U_PMF_CMN_HDR *Header, uint32_t *StackID)
 Get data from a U_PMR_RESTORE record. More...
 
int U_PMR_SAVE_get (const char *contents, U_PMF_CMN_HDR *Header, uint32_t *StackID)
 Get data from a U_PMR_SAVE record. More...
 
int U_PMR_SETTSCLIP_get (const char *contents, U_PMF_CMN_HDR *Header, int *ctype, uint32_t *Elements, U_PMF_RECTF **Rects)
 Get data from a U_PMR_SETTSCLIP record. More...
 
int U_PMR_SETTSGRAPHICS_get (const char *contents, U_PMF_CMN_HDR *Header, int *vgatype, int *pptype, uint8_t *AntiAliasMode, uint8_t *TextRenderHint, uint8_t *CompositingMode, uint8_t *CompositingQuality, int16_t *RenderOriginX, int16_t *RenderOriginY, uint16_t *TextContrast, uint8_t *FilterType, uint8_t *PixelOffset, U_PMF_TRANSFORMMATRIX *WorldToDevice, const char **Data)
 Get data from a U_PMR_SETTSGRAPHICS record. More...
 
int U_PMR_MULTIPLYWORLDTRANSFORM_get (const char *contents, U_PMF_CMN_HDR *Header, int *xmtype, U_PMF_TRANSFORMMATRIX *Matrix)
 Get data from a U_PMR_MULTIPLYWORLDTRANSFORM record. More...
 
int U_PMR_RESETWORLDTRANSFORM_get (const char *contents, U_PMF_CMN_HDR *Header)
 Get data from a U_PMR_RESETWORLDTRANSFORM record. More...
 
int U_PMR_ROTATEWORLDTRANSFORM_get (const char *contents, U_PMF_CMN_HDR *Header, int *xmtype, U_FLOAT *Angle)
 Get data from a U_PMR_ROTATEWORLDTRANSFORM record. More...
 
int U_PMR_SCALEWORLDTRANSFORM_get (const char *contents, U_PMF_CMN_HDR *Header, int *xmtype, U_FLOAT *Sx, U_FLOAT *Sy)
 Get data from a U_PMR_SCALEWORLDTRANSFORM record. More...
 
int U_PMR_SETPAGETRANSFORM_get (const char *contents, U_PMF_CMN_HDR *Header, int *PUenum, U_FLOAT *Scale)
 Get data from a U_PMR_SETPAGETRANSFORM record. More...
 
int U_PMR_SETWORLDTRANSFORM_get (const char *contents, U_PMF_CMN_HDR *Header, U_PMF_TRANSFORMMATRIX *Matrix)
 Get data from a U_PMR_SETWORLDTRANSFORM record. More...
 
int U_PMR_TRANSLATEWORLDTRANSFORM_get (const char *contents, U_PMF_CMN_HDR *Header, int *xmtype, U_FLOAT *Dx, U_FLOAT *Dy)
 Get data from a U_PMR_TRANSLATEWORLDTRANSFORM record. More...
 
int U_PMR_STROKEFILLPATH_get (const char *contents, U_PMF_CMN_HDR *Header)
 Get data from a U_PMR_STROKEFILLPATH record. More...
 
int U_PMR_MULTIFORMATSTART_get (const char *contents, U_PMF_CMN_HDR *Header)
 Get data from a U_PMR_MULTIFORMATSTART record. More...
 
int U_PMR_MULTIFORMATSECTION_get (const char *contents, U_PMF_CMN_HDR *Header)
 Get data from a U_PMR_MULTIFORMATSECTION record. More...
 
int U_PMR_MULTIFORMATEND_get (const char *contents, U_PMF_CMN_HDR *Header)
 Get data from a U_PMR_MULTIFORMATEND record. More...
 

Detailed Description

Functions for manipulating EMF+ files and structures.

EMF+ is much more object based than is EMF or WMF, so the U_PMR_*_set and most U_PMF_*_set functions return a pointer to a PseudoObject. PseudoObjects are structs that contain a data field to hold the object in EMF+ file byte order, size information, and some type information. This is sufficient to allow complex records to be built up from the various sorts of nested objects which they normally contain. If something goes wrong a NULL pointer is returned and recsize is set to 0.

EMF+ does not use a separate set of endian functions, _get and _set routines convert from/to the EMF+ file byte order on the fly.

Compile with "U_VALGRIND" defined defined to enable code which lets valgrind check each record for uninitialized data.

Compile with "SOL8" defined for Solaris 8 or 9 (Sparc).

    WARNING:  Microsoft's EMF+ documentation is little-endian for everything EXCEPT       *
    bitfields,  which are big-endian.   See EMF+ manual section 1.3.2                     *
    That documentation also uses 0 as the MOST significant bit, N-1 as the least.         *
    This code is little-endian throughout, and 0 is the LEAST significant bit             *

Function Documentation

U_PMF_POINT* POINTF_To_POINT16_LE ( U_PMF_POINTF points,
int  count 
)

Allocate and construct an array of U_POINT16 objects from a set of U_PMF_POINTF objects, endianness in and out is LE.

Returns
pointer to an array of U_POINT16 structures.
Parameters
pointspointer to the source U_POINT structures
countnumber of members in points

If a coordinate is out of range it saturates at boundary.

U_PMF_POINTF* pointfs_transform ( U_PMF_POINTF points,
int  count,
U_XFORM  xform 
)

Allocate and construct an array of U_PMF_POINTF objects which have been subjected to a U_XFORM.

Returns
pointer to an array of U_PMF_POINTF structures.
Parameters
pointspointer to the source U_PMF_POINTF structures
countnumber of members in points
xformU_XFORM to apply
U_PMF_RECTF* rectfs_transform ( U_PMF_RECTF Rects,
int  Count,
U_XFORM  Xform 
)

Allocate and construct an array of U_PMF_RECTF objects which have been subjected to a U_XFORM.

Returns
pointer to an array of U_PMF_RECTF structures.
Parameters
Rectspointer to the source U_PMF_RECTF structures
Countnumber of members in Rects
XformU_XFORM to apply. Rotation is ignored, only translation is applied.
U_PMF_TRANSFORMMATRIX tm_for_gradrect ( U_FLOAT  Angle,
U_FLOAT  w,
U_FLOAT  h,
U_FLOAT  x,
U_FLOAT  y,
U_FLOAT  Periods 
)

Utility function calculate the transformation matrix needed to make a gradient run precisely corner to corner of a rectangle.

Parameters
AngleRotation in degrees clockwise of the gradient. 0 is horizontal gradient.
wWidth of the rectangle
hHeight of the rectangle
xX coordinate of upper left corner of rectangle
yY coordinate of upper left corner of rectangle
PeriodsPeriods of gradient corner to corner. 1.0 is one, corner to corner.
Returns
Transformation matrix. All values are zero if Periods, w, or h are less than or equal to zero.
int U_DPO_clear ( U_DPSEUDO_OBJ dpo)

Clear U_DPSEUDO_OBJ's. Memory is retained, Elements and Used values are set to 0.

Returns
1 on success, 0 on error.

It is much more efficient to clear a DPO and reuse it than to free that DPO and create another.

int U_DPO_free ( U_DPSEUDO_OBJ **  dpo)

Free U_DPSEUDO_OBJ's.

Returns
1 on success, 0 on error.
uint8_t* U_LOAD_GUID ( char *  string)

Load a GUID from text format into EMF+ file binary format.

\param  string  Curly GUID as text, minus the barckets and dashes.
\return GUID in EMF+ file binary format.

This accepts a string that is 16 bytes long = 32 characters hex (no dash spaces or brackets) as text. Text form is; Data1|Data2|Data3|Data4, first three are stored as little endian integers of 4,2,2 bytes, respectively, last is stored like a string (big endian), after conversion from text hex to binary.

This function is not normally called by end user code.

int U_OA_append ( U_OBJ_ACCUM oa,
const char *  data,
int  size,
int  Type,
int  Id 
)

Append data to an U_OBJ_ACCUM structure.

Parameters
oapointer to the U_OBJ_ACCUM structure
datadata to add
sizebytes in data
Typeobject type
IdObject ID
Returns
0 on success, !0 on error. -1 on Type change, -2 on Id change

Safe to test for Id, Type changes by calling with size=0.

int U_OA_clear ( U_OBJ_ACCUM oa)

Clear an U_OBJ_ACCUM structure. Accumulated storage is retained.

Parameters
oapointer to the U_OBJ_ACCUM structure
Returns
0 on success, !0 on error.
int U_OA_release ( U_OBJ_ACCUM oa)

Release an U_OBJ_ACCUM structure. Accumulated storage is free'd.

Parameters
oapointer to the U_OBJ_ACCUM structure
Returns
0 on success, !0 on error.
int U_OID_To_BT ( uint32_t  OID)

Convert from PseudoObject OID to BrushType enumeration.

Returns
BT value on success, -1 if no match
Parameters
OIDPseudoObject OID (based on EMF+ manual chapter number. )

Only OIDs that map to BT's are supported.

int U_OID_To_CLCDT ( uint32_t  OID)

Convert from PseudoObject OID to CustomLineCapDataType Enumeration.

Returns
BT value on success, -1 if no match
Parameters
OIDPseudoObject OID (based on EMF+ manual chapter number. )

Only OIDs that map to CLCDT's are supported.

uint8_t* U_OID_To_GUID ( uint32_t  OID)

Generate the 16 byte form from OID of the ImageEffects Identifier.

Parameters
OIDOID of the ImageEffects Identifier
Returns
pointer to 16 byte buffer holding the long GUID binary form, or NULL on error.

EMF+ manual 2.1.3.1, Microsoft name: ImageEffects Identifier

int U_OID_To_IDT ( uint32_t  OID)

Convert from PseudoObject OID to ImageDataType Enumeration.

Returns
BT value on success, -1 if no match
Parameters
OIDPseudoObject OID (based on EMF+ manual chapter number. )

Only OIDs that map to IDT's are supported.

int U_OID_To_OT ( uint32_t  OID)

Convert from PseudoObject OID to ObjectType enumeration.

Returns
OT value on success, 0 if no match
Parameters
OIDPseudoObject OID (based on EMF+ manual chapter number. )

Only OTs that may be stored in the EMF+ object table are supported.

int U_OID_To_RNDT ( uint32_t  OID)

Convert from PseudoObject OID to RegionNodeDataType Enumeration.

Returns
BT value on success, -1 if no match
Parameters
OIDPseudoObject OID (based on EMF+ manual chapter number. )

Only OIDs that map to RNDT's are supported.

int U_PATH_arcto ( U_DPSEUDO_OBJ Path,
U_FLOAT  Start,
U_FLOAT  Sweep,
U_FLOAT  Rot,
U_PMF_RECTF Rect,
uint8_t  Flags,
int  StartSeg 
)

Append an "arcto" set of points to a path (Bezier points are calculated, and these are appended.

Parameters
PathAddress of a pointer to the U_PSEUDO_OBJ that holds points
StartStart angle, >=0.0, degrees clockwise from 3:00
SweepSweep angle, -360<= angle <=360, degrees clockwise from Start
RotRotation angle to apply to coordinate system (Start and Rect), positive is degrees clockwise
RectU_PMF_RECTF that defines the bounding rectangle.
FlagsFlags (U_PTP_None, U_PTP_DashMode, U_PTP_PathMarker, U_PTP_NoBit, but NOT U_PTP_CloseSubpath)
StartSegIf set, the arc starts a new segment, if clear, continue the existing segment. Starting a new segment does not automatically apply U_PATH_closepath to the existing path.
Returns
1 on success, 0 on error.

Based on Luc Maisonobe's work, http://www.spaceroots.org/documents/ellipse/

int U_PATH_closepath ( U_DPSEUDO_OBJ Path)

Set the closepath bit in the last point.

Parameters
PathAddress of a DoublePseudoObject holding the path to act upon.
Returns
1 on success, 0 on error.
U_DPSEUDO_OBJ* U_PATH_create ( int  Elements,
const U_PMF_POINTF Points,
uint8_t  First,
uint8_t  Others 
)

Create U_DPSEUDO_OBJ's for the Points and Types of a path.

Parameters
ElementsNumber of elements in Points. May be zero, which creates an empty path.
PointsArray of U_PMF_POINTF values.
FirstApply to first point, unsigned byte, lower 4 bits hold the PathPointType flag upper 4 bits hold the PathPointType enumeration. Must have U_PPT_Start set.
OthersApply to all other points, unsigned byte, lower 4 bits hold the PathPointType flag upper 4 bits hold the PathPointType enumeration. Must have U_PPT_Line or U_PPT_Bezier set.
Returns
pointer to the DU_PSEUDO_OBJ object, NULL on error
int U_PATH_lineto ( U_DPSEUDO_OBJ Path,
U_PMF_POINTF  Point,
uint8_t  Flags 
)

Append a "lineto" point to a path.

Parameters
PathAddress of a DoublePseudoObject holding the path to append to.
PointU_PMF_POINTF point to draw to.
FlagsFlags may be (U_PTP_None, U_PTP_DashMode, U_PTP_PathMarker, U_PTP_NoBit, U_PTP_CloseSubpath)
Returns
1 on success, 0 on error.
int U_PATH_moveto ( U_DPSEUDO_OBJ Path,
U_PMF_POINTF  Point,
uint8_t  Flags 
)

Append a "moveto" point to a path.

Parameters
PathAddress of a DoublePseudoObject holding the path to append to.
PointPoint to move to.
FlagsFlags may be (U_PTP_None, U_PTP_DashMode, U_PTP_PathMarker, U_PTP_NoBit, U_PTP_CloseSubpath)
Returns
1 on success, 0 on error.
int U_PATH_polybezierto ( U_DPSEUDO_OBJ Path,
uint32_t  Elements,
const U_PMF_POINTF Points,
uint8_t  Flags,
uint8_t  StartSeg 
)

Append a "polybezierto" set of point to a path.

Parameters
PathAddress of a DoublePseudoObject holding the path to append to.
Elementsnumber of Points
PointsBezier points. Optional starting point, then N sets of 3, example: [P1] (Q12A Q12B P2) (Q23A Q23B P3).
FlagsFlags (U_PTP_None, U_PTP_DashMode, U_PTP_PathMarker, U_PTP_NoBit, but NOT U_PTP_CloseSubpath)
StartSegIf set, use U_PPT_Start PathPointType enumeration for first point, otherwise use U_PPT_Bezier.
Returns
1 on success, 0 on error.

If Start is set Elements must be 1 + multiple of 3. Ie, P1 Q12A Q12B P2 Q23A Q23B P3

If Start is clear Elements must be a multiple of 3. Ie, (P1, already in path) Q12A Q12B P2 Q23A Q23B P3

int U_PATH_polygon ( U_DPSEUDO_OBJ Path,
uint32_t  Elements,
const U_PMF_POINTF Points,
uint8_t  Flags 
)

Append a "polygon" set of points to a path.

Parameters
PathAddress of a DoublePseudoObject holding the path to append to.
Elementsnumber of Points and Flags
PointsLine points.
FlagsFlags (U_PTP_None, U_PTP_DashMode, U_PTP_PathMarker, U_PTP_NoBit, but NOT U_PTP_CloseSubpath)
Returns
1 on success, 0 on error.
int U_PATH_polylineto ( U_DPSEUDO_OBJ Path,
uint32_t  Elements,
const U_PMF_POINTF Points,
uint8_t  Flags,
uint8_t  StartSeg 
)

Append a "polylineto" set of point to a path.

Parameters
PathAddress of a DoublePseudoObject holding the path to append to.
Elementsnumber of Points and Flags
PointsLine points.
FlagsFlags (U_PTP_None, U_PTP_DashMode, U_PTP_PathMarker, U_PTP_NoBit, but NOT U_PTP_CloseSubpath)
StartSegIf set, use U_PPT_Start PathPointType enumeration for first point, otherwise use U_PPT_Line.
Returns
1 on success, 0 on error.
U_PSEUDO_OBJ* U_PMF_4NUM_set ( uint32_t  BrushID)

Create and set a PMF_4NUM PseudoObject (used for BrushID's)

Returns
Pointer to PseudoObject, NULL on error
Parameters
BrushIDU_PMF_BRUSH object in the EMF+ object table (0-63, inclusive)
int U_PMF_ARGB_get ( const char *  contents,
uint8_t *  Blue,
uint8_t *  Green,
uint8_t *  Red,
uint8_t *  Alpha 
)

Get data from a U_PMF_ARGB object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
BlueBlue color (0-255)
GreenGreen color (0-255)
RedRed color (0-255)
AlphaAlpha (0-255)

EMF+ manual 2.2.2.1, Microsoft name: EmfPlusARGB Object

U_PSEUDO_OBJ* U_PMF_ARGB_set ( uint8_t  Alpha,
uint8_t  Red,
uint8_t  Green,
uint8_t  Blue 
)

Create and set a U_PMF_ARGB PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
AlphaAlpha (0-255)
RedRed color (0-255)
GreenGreen color (0-255)
BlueBlue color (0-255)

EMF+ manual 2.2.2.1, Microsoft name: EmfPlusARGB Object

U_PSEUDO_OBJ* U_PMF_ARGBN_set ( uint32_t  Count,
U_PMF_ARGB Colors 
)

Create and set an Array of U_PMF_ARGB valus in a PseudoObject.

Returns
Pointer to PseudoObject containing the count, followed by the array of colors, NULL on error
Parameters
CountNumber of entries in Colors
ColorsArray of ARGB values

EMF+ manual 2.2.2.1, Microsoft name: EmfPlusARGB Object

U_PMF_ARGB U_PMF_ARGBOBJ_set ( uint8_t  Alpha,
uint8_t  Red,
uint8_t  Green,
uint8_t  Blue 
)

Set a U_PMF_ARGB object.

Returns
Object
Parameters
AlphaAlpha (0-255)
RedRed color (0-255)
GreenGreen color (0-255)
BlueBlue color (0-255)

EMF+ manual 2.2.2.1, Microsoft name: EmfPlusARGB Object

int U_PMF_BITMAP_get ( const char *  contents,
U_PMF_BITMAP Bs,
const char **  Data 
)

Get data from a U_PMF_BITMAP object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
Bspointer to U_PMF_BITMAP structure, with no variable part
Datapointer to variable part

EMF+ manual 2.2.2.2, Microsoft name: EmfPlusBitmap Object

U_PSEUDO_OBJ* U_PMF_BITMAP_set ( const U_PMF_BITMAP Bs,
const U_PSEUDO_OBJ Bm 
)

Create and set a U_PMF_BITMAP PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
Bspointer to U_PMF_BITMAP structure, with no variable part
BmU_PSEUDO_OBJ containing an U_PMF_BITMAPDATA or U_PMF_COMPRESSEDIMAGE object

EMF+ manual 2.2.2.2, Microsoft name: EmfPlusBitmap Object

int U_PMF_BITMAPDATA_get ( const char *  contents,
U_PMF_PALETTE Ps,
const char **  Colors,
const char **  Data 
)

Get data from a U_PMF_BITMAPDATA object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
Pspointer to U_PMF_PALETTE structure, with no variable part
ColorsColor part of U_PMF_PALETTE object
DataAn array of bytes, meaning depends on fields in U_PMF_BITMAP object and the PixelFormat enumeration.

EMF+ manual 2.2.2.3, Microsoft name: EmfPlusBitmapData Object

U_PSEUDO_OBJ* U_PMF_BITMAPDATA_set ( const U_PSEUDO_OBJ Ps,
int  cbBm,
const char *  Bm 
)

Create and set a U_PMF_BITMAPDATA PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
Ps(optional) U_PSEUDO_OBJ containing a U_PMF_PALETTE structure
cbBmBytes in Bm
BmAn array of bytes, meaning depends on fields in U_PMF_BITMAP object and the PixelFormat enumeration.

EMF+ manual 2.2.2.3, Microsoft name: EmfPlusBitmapData Object

int U_PMF_BLENDCOLORS_get ( const char *  contents,
uint32_t *  Elements,
U_FLOAT **  Positions,
const char **  Colors 
)

Get data from a U_PMF_BLENDCOLORS object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
ElementsNumber of members in Positions and Colors
PositionsCaller must free. Pointer to memory holding positions along gradient line.
ColorsCaller must NOT free memory ,Pointer to memory holding colors at positions on gradient line.

EMF+ manual 2.2.2.4, Microsoft name: EmfPlusBlendColors Object

U_PSEUDO_OBJ* U_PMF_BLENDCOLORS_linear_set ( uint32_t  Elements,
U_PMF_ARGB  StartColor,
U_PMF_ARGB  EndColor 
)

Create and set a U_PMF_BLENDCOLORS PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
Elementsmembers in osition, inluding Start and End (0.0 - 1.0)
StartColorStart Color (U_PMF_ARGB)
EndColorEnd Color (U_PMF_ARGB)

EMF+ manual 2.2.2.5, Microsoft name: EmfPlusBlendFactors Object

Positions always start at 0.0 and always end at 1.0. It is not well documented but other start and end values generally do not work.

U_PSEUDO_OBJ* U_PMF_BLENDCOLORS_set ( uint32_t  Elements,
const U_FLOAT Positions,
const U_PSEUDO_OBJ Colors 
)

Create and set a U_PMF_BLENDCOLORS PseudoObject.

Returns
Pointer to PseudoObject, NULL on Positions and Colors
Parameters
Elementsnumber of elements in Positions, must agree with the number of Colors.
Positionspositions along gradient line. The first position MUST be 0.0 and the last MUST be 1.0.
ColorsU_PSEUDO_OBJ containing an array of U_PMF_ARGB objects: object colors at positions on gradient line

EMF+ manual 2.2.2.4, Microsoft name: EmfPlusBlendColors Object

int U_PMF_BLENDFACTORS_get ( const char *  contents,
uint32_t *  Elements,
U_FLOAT **  Positions,
U_FLOAT **  Factors 
)

Get data from a U_PMF_BLENDFACTORS object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
Elementsmembers in each array
PositionsCaller must free. Pointer to memory holding positions along gradient line.
FactorsCaller must free. Pointer to memory holding blending factors, 0.0->1.0 values, inclusive along gradient line.

EMF+ manual 2.2.2.5, Microsoft name: EmfPlusBlendFactors Object

U_PSEUDO_OBJ* U_PMF_BLENDFACTORS_linear_set ( uint32_t  Elements,
U_FLOAT  StartFactor,
U_FLOAT  EndFactor 
)

Create and set a U_PMF_BLENDFACTORS PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
Elementsmembers in osition, inluding Start and End (0.0 - 1.0)
StartFactorStart Factor (0.0 - 1.0)
EndFactorEnd Factor (0.0 - 1.0)

EMF+ manual 2.2.2.5, Microsoft name: EmfPlusBlendFactors Object

Positions always start at 0.0 and always end at 1.0. It is not well documented but other start and end values generally do not work.

U_PSEUDO_OBJ* U_PMF_BLENDFACTORS_set ( uint32_t  Elements,
const U_FLOAT Positions,
const U_FLOAT Factors 
)

Create and set a U_PMF_BLENDFACTORS PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
Elementsmembers in each array
Positionspositions along gradient line. The first position MUST be 0.0 and the last MUST be 1.0.
Factorsblending factors, 0.0->1.0 values, inclusiv

EMF+ manual 2.2.2.5, Microsoft name: EmfPlusBlendFactors Object

int U_PMF_BOUNDARYPATHDATA_get ( const char *  contents,
int32_t *  Size,
const char **  Data 
)

Get data from a U_PMF_BOUNDARYPATHDATA object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
Sizebytes in Data
Databoundary of the brush

EMF+ manual 2.2.2.6, Microsoft name: EmfPlusBoundaryPathData Object

U_PSEUDO_OBJ* U_PMF_BOUNDARYPATHDATA_set ( const U_PSEUDO_OBJ Path)

Create and set a U_PMF_BOUNDARYPATHDATA PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
PathU_PSEUDO_OBJ containing U_PMF_PATH object

EMF+ manual 2.2.2.6, Microsoft name: EmfPlusBoundaryPathData Object

int U_PMF_BOUNDARYPOINTDATA_get ( const char *  contents,
int32_t *  Elements,
U_PMF_POINTF **  Points 
)

Get data from a U_PMF_BOUNDARYPOINTDATA object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
ElementsMembers in POints
PointsCaller must free. Pointer to memory holding points along gradient line. Boundary of the brush.

EMF+ manual 2.2.2.7, Microsoft name: EmfPlusBoundaryPointData Object

U_PSEUDO_OBJ* U_PMF_BOUNDARYPOINTDATA_set ( uint32_t  Elements,
const U_PMF_POINTF Points 
)

Create and set a U_PMF_BOUNDARYPOINTDATA PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
Elementsmembers in each array
Pointsarray of U_PMF_POINTF

EMF+ manual 2.2.2.7, Microsoft name: EmfPlusBoundaryPointData Object

int U_PMF_BRUSH_get ( const char *  contents,
uint32_t *  Version,
uint32_t *  Type,
const char **  Data 
)

Get data from a U_PMF_BRUSH object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
VersionEmfPlusGraphicsVersion object
TypeBrushType Enumeration
Dataone of the 5 types of Brush data

EMF+ manual 2.2.1.1, Microsoft name: EmfPlusBrush Object

U_PSEUDO_OBJ* U_PMF_BRUSH_set ( uint32_t  Version,
const U_PSEUDO_OBJ Bd 
)

Create and set a U_PMF_BRUSH PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
VersionEmfPlusGraphicsVersion object
BdU_PSEUDO_OBJ containing one of the 5 types of Brush data

EMF+ manual 2.2.1.1, Microsoft name: EmfPlusBrush Object

int U_PMF_CHARACTERRANGE_get ( const char *  contents,
int32_t *  First,
int32_t *  Length 
)

Get data from a U_PMF_CHARACTERRANGE object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
FirstFirst position in range
LengthRange length

EMF+ manual 2.2.2.8, Microsoft name: EmfPlusCharacterRange Object

U_PSEUDO_OBJ* U_PMF_CHARACTERRANGE_set ( int32_t  First,
int32_t  Length 
)

Create and set a U_PMF_CHARACTERRANGE PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
FirstFirst position in range
LengthRange length

EMF+ manual 2.2.2.8, Microsoft name: EmfPlusCharacterRange Object

int U_PMF_CMN_HDR_get ( const char **  contents,
U_PMF_CMN_HDR Header 
)

Get the entire EMF+ record header.

Parameters
contentsRecord from which to extract data, will be offset by header size.
HeaderLocation to store data (may be NULL)
Returns
1 If Header is Null, nothing is stored but contents is still offset.
int U_PMF_COMPOUNDLINEDATA_get ( const char *  contents,
int32_t *  Elements,
U_FLOAT **  Widths 
)

Get data from a U_PMF_COMPOUNDLINEDATA object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
ElementsMembers in the array
WidthsCaller must free. Pointer to memory holding Line or gap widths (0.0 <-> 1.0, fraction of total line width ).

EMF+ manual 2.2.2.9, Microsoft name: EmfPlusCompoundLineData Object

U_PSEUDO_OBJ* U_PMF_COMPOUNDLINEDATA_set ( int32_t  Elements,
const char *  Widths 
)

Create and set a U_PMF_COMPOUNDLINEDATA PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
ElementsMembers in Widths
WidthsArray of U_FLOAT Line or gap widths (0.0 <-> 1.0, fraction of total line width )

EMF+ manual 2.2.2.9, Microsoft name: EmfPlusCompoundLineData Object

int U_PMF_COMPRESSEDIMAGE_get ( const char *  contents,
const char **  Data 
)

Get data from a U_PMF_COMPRESSEDIMAGE object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
DataStored image in one of the supported formats.

EMF+ manual 2.2.2.10, Microsoft name: EmfPlusCompressedImage Object

This function does not do anything useful, but it is included so that all objects have a corresponding _get().

U_PSEUDO_OBJ* U_PMF_COMPRESSEDIMAGE_set ( int32_t  cbImage,
const char *  Image 
)

Create and set a U_PMF_COMPRESSEDIMAGE PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
cbImageBytes in Image
ImageStored image in one of the supported formats (GIF, PNG, etc.).

EMF+ manual 2.2.2.10, Microsoft name: EmfPlusCompressedImage Object

char* U_PMF_CURLYGUID_set ( uint8_t *  GUID)

Create a string containing the curly bracket form of the 16 byte GUID value.

Returns
number of bytes in record, 0 on error
Parameters
GUIDpointer to the 16 unsigned bytes
Returns
string in curly bracket form. http://msdn.microsoft.com/en-us/library/cc230316.aspx

Text form is Data1-Data2-Data3-Data4, the first 3 are stored as little endian integers, the last as a string (big endian).

int U_PMF_CUSTOMENDCAPDATA_get ( const char *  contents,
int32_t *  Size,
const char **  Data 
)

Get data from a U_PMF_CUSTOMENDCAPDATA object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
SizeBytes in Data
DataDescription of linecap

EMF+ manual 2.2.2.11, Microsoft name: EmfPlusCustomEndCapData Object

U_PSEUDO_OBJ* U_PMF_CUSTOMENDCAPDATA_set ( const U_PSEUDO_OBJ Clc)

Create and set a U_PMF_CUSTOMENDCAPDATA PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
ClcU_PSEUDO_OBJ containing a U_PMF_CUSTOMLINECAP object

EMF+ manual 2.2.2.11, Microsoft name: EmfPlusCustomEndCapData Object

int U_PMF_CUSTOMLINECAP_get ( const char *  contents,
uint32_t *  Version,
uint32_t *  Type,
const char **  Data 
)

Get data from a U_PMF_CUSTOMLINECAP object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
VersionEmfPlusGraphicsVersion object
TypeCustomLineCapData Enumeration
Dataone of the 2 types of Linecap data

EMF+ manual 2.2.1.2, Microsoft name: EmfPlusCustomLineCap Object

U_PSEUDO_OBJ* U_PMF_CUSTOMLINECAP_set ( uint32_t  Version,
const U_PSEUDO_OBJ Ld 
)

Create and set a U_PMF_CUSTOMLINECAP PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
VersionEmfPlusGraphicsVersion object
LdU_PSEUDO_OBJ containing one of the 2 types of Linecap data

EMF+ manual 2.2.1.2, Microsoft name: EmfPlusCustomLineCap Object

int U_PMF_CUSTOMLINECAPARROWDATA_get ( const char *  contents,
U_PMF_CUSTOMLINECAPARROWDATA Ccad 
)

Get data from a U_PMF_CUSTOMLINECAPARROWDATA object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
Ccadpointer to U_PMF_CUSTOMLINECAPARROWDATA structure

EMF+ manual 2.2.2.12, Microsoft name: EmfPlusCustomLineCapArrowData Object

U_PSEUDO_OBJ* U_PMF_CUSTOMLINECAPARROWDATA_set ( U_FLOAT  Width,
U_FLOAT  Height,
U_FLOAT  MiddleInset,
uint32_t  FillState,
uint32_t  StartCap,
uint32_t  EndCap,
uint32_t  Join,
U_FLOAT  MiterLimit,
U_FLOAT  WidthScale 
)

Create and set a U_PMF_CUSTOMLINECAPARROWDATA PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
WidthArrow cap width (is multiplied by line width before draw)
HeightArrow cap length (is multiplied by line width before draw)
MiddleInsetPixels between outer edge and filled region
FillStateIf set, fill, otherwise, only border
StartCapLineCap enumeration (type of cap)
EndCapLineCap enumeration
JoinLineJoin enumeration
MiterLimitMaximum (miter length / line width)
WidthScaleScale for U_PMF_CUSTOMLINECAP object

EMF+ manual 2.2.2.12, Microsoft name: EmfPlusCustomLineCapArrowData Object

int U_PMF_CUSTOMLINECAPDATA_get ( const char *  contents,
U_PMF_CUSTOMLINECAPDATA Clcd,
const char **  Data 
)

Get data from a U_PMF_CUSTOMLINECAPDATA object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
Clcdpointer to U_PMF_CUSTOMLINECAPDATA structure, with no variable part
Datavariable part of U_PMF_CUSTOMLINECAPDATA

EMF+ manual 2.2.2.13, Microsoft name: EmfPlusCustomLineCapData Object

U_PSEUDO_OBJ* U_PMF_CUSTOMLINECAPDATA_set ( uint32_t  Flags,
uint32_t  Cap,
U_FLOAT  Inset,
uint32_t  StartCap,
uint32_t  EndCap,
uint32_t  Join,
U_FLOAT  MiterLimit,
U_FLOAT  WidthScale,
const U_PSEUDO_OBJ Clcod 
)

Create and set a U_PMF_CUSTOMLINECAPDATA PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
FlagsCustomLineCapData flags
CapLineCap enumeration (type of cap)
InsetDistance line cap start -> line end
StartCapLineCap enumeration
EndCapLineCap enumeration
JoinLineJoin enumeration
MiterLimitMaximum (miter length / line width)
WidthScaleScale for U_PMF_CUSTOMLINECAP object
ClcodU_PSEUDO_OBJ containing a U_PMF_CUSTOMLINECAPOPTIONALDATA object

EMF+ manual 2.2.2.13, Microsoft name: EmfPlusCustomLineCapData Object

int U_PMF_CUSTOMLINECAPOPTIONALDATA_get ( const char *  contents,
uint32_t  Flags,
const char **  FillData,
const char **  LineData 
)

Get data from a U_PMF_CUSTOMLINECAPOPTIONALDATA object.

Returns
on success 3,5, or 7 (for varying combinations of data present) or 1 (no data is present), 0 on error
Parameters
contentsRecord from which to extract data
Flagsbits set to indicate the presence of FillData and/or LineData
FillDataPath to fill (optional)
LineDataPath to stroke (optional)

EMF+ manual 2.2.2.14, Microsoft name: EmfPlusCustomLineCapOptionalData Object

U_PSEUDO_OBJ* U_PMF_CUSTOMLINECAPOPTIONALDATA_set ( const U_PSEUDO_OBJ Fill,
const U_PSEUDO_OBJ Line 
)

Create and set a U_PMF_CUSTOMLINECAPOPTIONALDATA PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
FillU_PSEUDO_OBJ containing a U_PMF_FILLPATHOBJ object (optional)
LineU_PSEUDO_OBJ containing a U_PMF_LINEPATH object (optional)

EMF+ manual 2.2.2.14, Microsoft name: EmfPlusCustomLineCapOptionalData Object

int U_PMF_CUSTOMSTARTCAPDATA_get ( const char *  contents,
int32_t *  Size,
const char **  Data 
)

Get data from a U_PMF_CUSTOMSTARTCAPDATA object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
SizeBytes in Data
DataDescription of linecap

EMF+ manual 2.2.2.15, Microsoft name: EmfPlusCustomStartCapData Object

U_PSEUDO_OBJ* U_PMF_CUSTOMSTARTCAPDATA_set ( const U_PSEUDO_OBJ Clc)

Create and set a U_PMF_CUSTOMSTARTCAPDATA PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
ClcU_PSEUDO_OBJ containing a U_PMF_CUSTOMLINECAPDATA object

EMF+ manual 2.2.2.15, Microsoft name: EmfPlusCustomStartCapData Object

int U_PMF_DASHEDLINEDATA_get ( const char *  contents,
int32_t *  Elements,
U_FLOAT **  Lengths 
)

Get data from a U_PMF_DASHEDLINEDATA object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
ElementsMembers in the array
LengthsCaller must free. Pointer to memory holding lengths of dashes and spaces.

EMF+ manual 2.2.2.16, Microsoft name: EmfPlusDashedLineData Object

U_PSEUDO_OBJ* U_PMF_DASHEDLINEDATA_set ( int32_t  Elements,
const U_FLOAT Lengths 
)

Create and set a U_PMF_DASHEDLINEDATA PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
ElementsMembers in Lengths
LengthsArray of U_FLOAT holding lengths of dashes and spaces.

EMF+ manual 2.2.2.16, Microsoft name: EmfPlusDashedLineData Object

U_PSEUDO_OBJ* U_PMF_DASHEDLINEDATA_set2 ( U_FLOAT  Unit,
int  StdPat 
)

Utility function to create and set a U_PMF_DASHEDLINEDATA PseudoObject from one of a predefined set of patterns.

Returns
Pointer to PseudoObject, NULL on error
Parameters
UnitLength of the repeat unit
StdPatMembers in Lengths

EMF+ manual 2.2.2.16, Microsoft name: EmfPlusDashedLineData Object

int U_PMF_FILLPATHOBJ_get ( const char *  contents,
int32_t *  Size,
const char **  Data 
)

Get data from a U_PMF_FILLPATHOBJ object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
SizeBytes in Data
DataPath specification

EMF+ manual 2.2.2.17, Microsoft name: EmfPlusFillPath Object

U_PSEUDO_OBJ* U_PMF_FILLPATHOBJ_set ( const U_PSEUDO_OBJ Path)

Create and set a U_PMF_FILLPATHOBJ PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
PathU_PSEUDO_OBJ containing a U_PMF_PATH object

EMF+ manual 2.2.2.17, Microsoft name: EmfPlusFillPath Object

int U_PMF_FOCUSSCALEDATA_get ( const char *  contents,
uint32_t *  Count,
U_FLOAT ScaleX,
U_FLOAT ScaleY 
)

Get data from a U_PMF_FOCUSSCALEDATA object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
Countmust be 2
ScaleXvalue 0.0 <-> 1.0
ScaleYvalue 0.0 <-> 1.0

EMF+ manual 2.2.2.18, Microsoft name: EmfPlusFocusScaleData Object

U_PSEUDO_OBJ* U_PMF_FOCUSSCALEDATA_set ( U_FLOAT  ScaleX,
U_FLOAT  ScaleY 
)

Create and set a U_PMF_FOCUSSCALEDATA PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
ScaleXvalue 0.0 <-> 1.0
ScaleYvalue 0.0 <-> 1.0

EMF+ manual 2.2.2.18, Microsoft name: EmfPlusFocusScaleData Object

int U_PMF_FONT_get ( const char *  contents,
uint32_t *  Version,
U_FLOAT EmSize,
uint32_t *  SizeUnit,
int32_t *  FSFlags,
uint32_t *  Length,
const char **  Data 
)

Get data from a U_PMF_FONT object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
VersionEmfPlusGraphicsVersion object
EmSizeem size in units of SizeUnit
SizeUnitUnitType enumeration
FSFlagsFontStyle flags
LengthNumber of Unicode Characters in FamilyName
DataUnicode (UTF-16LE) name of font family

EMF+ manual 2.2.1.3, Microsoft name: EmfPlusFont Object

U_PSEUDO_OBJ* U_PMF_FONT_set ( uint32_t  Version,
U_FLOAT  EmSize,
uint32_t  SizeUnit,
int32_t  FSFlags,
uint32_t  Length,
const uint16_t *  Font 
)

Create and set a U_PMF_FONT PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
VersionEmfPlusGraphicsVersion object
EmSizeem size in units of SizeUnit
SizeUnitUnitType enumeration
FSFlagsFontStyle flags
LengthNumber of Unicode Characters in FamilyName
FontUnicode (UTF-16LE) fontname

EMF+ manual 2.2.1.3, Microsoft name: EmfPlusFont Object

int U_PMF_GRAPHICSVERSION_get ( const char *  contents,
int *  Signature,
int *  GrfVersion 
)

Get data from a U_PMF_GRAPHICSVERSION object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
SignatureMust be U_GFVR_PMF (0xDBC01)
GrfVersionGraphicsVersion enumeration

EMF+ manual 2.2.2.19, Microsoft name: EmfPlusGraphicsVersion Object

U_PSEUDO_OBJ* U_PMF_GRAPHICSVERSION_set ( int  GrfVersion)

Create and set a U_PMF_GRAPHICSVERSION object (Signature always set to 0xDBC01)

Returns
Pointer to PseudoObject, NULL on error
Parameters
GrfVersionGraphicsVersion enumeration

EMF+ manual 2.2.2.19, Microsoft name: EmfPlusGraphicsVersion Object

U_PMF_GRAPHICSVERSION U_PMF_GRAPHICSVERSIONOBJ_set ( int  GrfVersion)

Create and set a U_PMF_GRAPHICSVERSION object Structure (Signature always set to 0xDBC01)

Returns
U_PMF_GRAPHICSVERSION
Parameters
GrfVersionGraphicsVersion enumeration

EMF+ manual 2.2.2.19, Microsoft name: EmfPlusGraphicsVersion Object

int U_PMF_HATCHBRUSHDATA_get ( const char *  contents,
uint32_t *  Style,
U_PMF_ARGB Foreground,
U_PMF_ARGB Background 
)

Get data from a U_PMF_HATCHBRUSHDATA object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
StyleHatchStyle enumeration
ForegroundHatch pattern line color
BackgroundHatch pattern bkground color

EMF+ manual 2.2.2.20, Microsoft name: EmfPlusHatchBrushData Object

U_PSEUDO_OBJ* U_PMF_HATCHBRUSHDATA_set ( uint32_t  Style,
const U_PSEUDO_OBJ Fg,
const U_PSEUDO_OBJ Bg 
)

Create and set a U_PMF_HATCHBRUSHDATA PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
StyleHatchStyle enumeration
FgU_PSEUDO_OBJ containing a U_ARGB object, Foreground hatch pattern line color
BgU_PSEUDO_OBJ containing a U_ARGB object, Background hatch pattern line color

EMF+ manual 2.2.2.20, Microsoft name: EmfPlusHatchBrushData Object

int U_PMF_HEADERFIELDS_get ( const char *  contents,
uint16_t *  Type,
uint16_t *  Flags,
uint32_t *  Size,
uint32_t *  Datasize 
)

Retrieve whichever header fields are requested. NULL pointers do not retrieve.

Parameters
contentsRecord from which to extract data, will be incremented by header size.
TypeRecord type
FlagsRecord flags
SizeRecords size
DatasizeData size
Returns
1 on success, 0 on failure.
uint16_t U_PMF_HEADERFLAGS_get ( const char *  contents)

Get the 16 bit unsigned Flags field from a header.

Parameters
contentsRecord from which to extract data, will be incremented by header size.
Returns
Flags field In many records the only value needed from the header is Flags. Rather than mapping the entire Header and returning it, in these instances this function may be called to just get this one value.
int U_PMF_IE_BLUR_get ( const char *  contents,
U_FLOAT Radius,
uint32_t *  ExpandEdge 
)

Get data from a U_PMF_IE_BLUR object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
RadiusBlur radius in pixels
ExpandEdge1: expand bitmap by Radius; 0: bitmap size unchanged

EMF+ manual 2.2.3.1, Microsoft name: BlurEffect Object

U_PSEUDO_OBJ* U_PMF_IE_BLUR_set ( U_FLOAT  Radius,
uint32_t  ExpandEdge 
)

Create and set a U_PMF_IE_BLUR PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
RadiusBlur radius in pixels
ExpandEdge1: expand bitmap by Radius; 0: bitmap size unchanged

EMF+ manual 2.2.3.1, Microsoft name: BlurEffect Object

int U_PMF_IE_BRIGHTNESSCONTRAST_get ( const char *  contents,
int32_t *  Brightness,
int32_t *  Contrast 
)

Get data from a U_PMF_IE_BRIGHTNESSCONTRAST object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
Brightness-255 to 255, 0 is unchanged, positive increases, negative decreases
Contrast-100 to 100, 0 is unchanged, positive increases, negative decreases

EMF+ manual 2.2.3.2, Microsoft name: BrightnessContrastEffect Object

U_PSEUDO_OBJ* U_PMF_IE_BRIGHTNESSCONTRAST_set ( int32_t  Brightness,
int32_t  Contrast 
)

Create and set a U_PMF_IE_BRIGHTNESSCONTRAST PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
Brightness-255 to 255, 0 is unchanged, positive increases, negative decreases
Contrast-100 to 100, 0 is unchanged, positive increases, negative decreases

EMF+ manual 2.2.3.2, Microsoft name: BrightnessContrastEffect Object

int U_PMF_IE_COLORBALANCE_get ( const char *  contents,
int32_t *  CyanRed,
int32_t *  MagentaGreen,
int32_t *  YellowBlue 
)

Get data from a U_PMF_IE_COLORBALANCE object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
CyanRed-100 to 100, 0 is unchanged, positive increases Red & decreases Cyan, negative is opposite
MagentaGreen-100 to 100, 0 is unchanged, positive increases Green & decreases Magenta, negative is opposite
YellowBlue-100 to 100, 0 is unchanged, positive increases Blue & decreases Yellow, negative is opposite

EMF+ manual 2.2.3.3, Microsoft name: ColorBalanceEffect Object

U_PSEUDO_OBJ* U_PMF_IE_COLORBALANCE_set ( int32_t  CyanRed,
int32_t  MagentaGreen,
int32_t  YellowBlue 
)

Create and set a U_PMF_IE_COLORBALANCE PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
CyanRed-100 to 100, 0 is unchanged, positive increases Red & decreases Cyan, negative is opposite
MagentaGreen-100 to 100, 0 is unchanged, positive increases Green & decreases Magenta, negative is opposite
YellowBlue-100 to 100, 0 is unchanged, positive increases Blue & decreases Yellow, negative is opposite

EMF+ manual 2.2.3.3, Microsoft name: ColorBalanceEffect Object

int U_PMF_IE_COLORCURVE_get ( const char *  contents,
uint32_t *  Adjust,
uint32_t *  Channel,
int32_t *  Intensity 
)

Get data from a U_PMF_IE_COLORCURVE object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
AdjustCurveAdjustment enumeration
ChannelCurveChannel enumeration
Intensityadjustment to apply. "Adjust" determines what field this is and range values.

EMF+ manual 2.2.3.4, Microsoft name: ColorCurveEffect Object

U_PSEUDO_OBJ* U_PMF_IE_COLORCURVE_set ( uint32_t  Adjust,
uint32_t  Channel,
int32_t  Intensity 
)

Create and set a U_PMF_IE_COLORCURVE PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
AdjustCurveAdjustment enumeration
ChannelCurveChannel enumeration
Intensityadjustment to apply. "Adjust" determines what field this is and range values.

EMF+ manual 2.2.3.4, Microsoft name: ColorCurveEffect Object

int U_PMF_IE_COLORLOOKUPTABLE_get ( const char *  contents,
const uint8_t **  BLUT,
const uint8_t **  GLUT,
const uint8_t **  RLUT,
const uint8_t **  ALUT 
)

Get data from a U_PMF_IE_COLORLOOKUPTABLE object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
BLUTBlue color lookup table
GLUTGreen color lookup table
RLUTRed color lookup table
ALUTAlpha color lookup table

EMF+ manual 2.2.3.5, Microsoft name: ColorLookupTableEffect Object

U_PSEUDO_OBJ* U_PMF_IE_COLORLOOKUPTABLE_set ( const uint8_t *  BLUT,
const uint8_t *  GLUT,
const uint8_t *  RLUT,
const uint8_t *  ALUT 
)

Create and set a U_PMF_IE_COLORLOOKUPTABLE PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
BLUTBlue color lookup table
GLUTGreen color lookup table
RLUTRed color lookup table
ALUTAlpha color lookup table

EMF+ manual 2.2.3.5, Microsoft name: ColorLookupTableEffect Object. All tables have 256 entries.

int U_PMF_IE_COLORMATRIX_get ( const char *  contents,
U_PMF_IE_COLORMATRIX Matrix 
)

Get data from a U_PMF_IE_COLORMATRIX object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
Matrix5 x 5 color transformation matrix, First 4 rows are [{4 multiplier values},0.0] for R,G,B,A, last Row is [{4 color translation valuess}, 1.0]

EMF+ manual 2.2.3.6, Microsoft name: ColorMatrixEffect Object

U_PSEUDO_OBJ* U_PMF_IE_COLORMATRIX_set ( const U_FLOAT Matrix)

Create and set a U_PMF_IE_COLORMATRIX PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
Matrix5 x 5 color transformation matrix, First 4 rows are [{4 multiplier values},0.0] for R,G,B,A, last Row is [{4 color translation valuess}, 1.0]

EMF+ manual 2.2.3.6, Microsoft name: ColorMatrixEffect Object

int U_PMF_IE_HUESATURATIONLIGHTNESS_get ( const char *  contents,
int32_t *  Hue,
int32_t *  Saturation,
int32_t *  Lightness 
)

Get data from a U_PMF_IE_HUESATURATIONLIGHTNESS object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
Hue-180 to 180, 0 is unchanged
Saturation-100 to 100, 0 is unchanged
Lightness-100 to 100, 0 is unchanged

EMF+ manual 2.2.3.7, Microsoft name: HueSaturationLightnessEffect Object

U_PSEUDO_OBJ* U_PMF_IE_HUESATURATIONLIGHTNESS_set ( int32_t  Hue,
int32_t  Saturation,
int32_t  Lightness 
)

Create and set a U_PMF_IE_HUESATURATIONLIGHTNESS PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
Hue-180 to 180, 0 is unchanged
Saturation-100 to 100, 0 is unchanged
Lightness-100 to 100, 0 is unchanged

EMF+ manual 2.2.3.7, Microsoft name: HueSaturationLightnessEffect Object

int U_PMF_IE_LEVELS_get ( const char *  contents,
int32_t *  Highlight,
int32_t *  Midtone,
int32_t *  Shadow 
)

Get data from a U_PMF_IE_LEVELS object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
Highlight0 to 100, 100 is unchanged
Midtone-100 to 100, 0 is unchanged
Shadow0 to 100, 0 is unchanged

EMF+ manual 2.2.3.8, Microsoft name: LevelsEffect Object

U_PSEUDO_OBJ* U_PMF_IE_LEVELS_set ( int32_t  Highlight,
int32_t  Midtone,
int32_t  Shadow 
)

Create and set a U_PMF_IE_LEVELS PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
Highlight0 to 100, 100 is unchanged
Midtone-100 to 0, 0 is unchanged
Shadow0 to 100, 0 is unchanged

EMF+ manual 2.2.3.8, Microsoft name: LevelsEffect Object

int U_PMF_IE_REDEYECORRECTION_get ( const char *  contents,
int32_t *  Elements,
U_RECTL **  Rects 
)

Get data from a U_PMF_IE_REDEYECORRECTION object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
ElementsNumber of members in Rects
RectsCaller must free. Pointer to memory holding an array of U_RECTL.

EMF+ manual 2.2.3.9, Microsoft name: RedEyeCorrectionEffect Object

U_PSEUDO_OBJ* U_PMF_IE_REDEYECORRECTION_set ( uint32_t  Elements,
const U_RECTL Rects 
)

Create and set a U_PMF_IE_REDEYECORRECTION PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
ElementsNumber of members in Rects
RectsArray of U_RECTL rectangular area(s) to apply red eye correction

EMF+ manual 2.2.3.9, Microsoft name: RedEyeCorrectionEffect Object

int U_PMF_IE_SHARPEN_get ( const char *  contents,
U_FLOAT Radius,
int32_t *  Sharpen 
)

Get data from a U_PMF_IE_SHARPEN object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
RadiusSharpening radius in pixels
Sharpen0 to 100, 0 is unchanged

EMF+ manual 2.2.3.10, Microsoft name: SharpenEffect Object

U_PSEUDO_OBJ* U_PMF_IE_SHARPEN_set ( U_FLOAT  Radius,
int32_t  Sharpen 
)

Create and set a U_PMF_IE_SHARPEN PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
RadiusSharpening radius in pixels
Sharpen0 to 100, 0 is unchanged

EMF+ manual 2.2.3.10, Microsoft name: SharpenEffect Object

int U_PMF_IE_TINT_get ( const char *  contents,
int32_t *  Hue,
int32_t *  Amount 
)

Get data from a U_PMF_IE_TINT object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
Hue-180 to 180, [positive==clockwise] rotation in degrees starting from blue
Amount-100 [add black] to 100[add white], 0 is unchanged. Change in hue on specified axis

EMF+ manual 2.2.3.11, Microsoft name: TintEffect Object

U_PSEUDO_OBJ* U_PMF_IE_TINT_set ( const int32_t  Hue,
const int32_t  Amount 
)

Create and set a U_PMF_IE_TINT PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
Hue-180 to 180, [positive==clockwise] rotation in degrees starting from blue
Amount-100 [add black] to 100[add white], 0 is unchanged. Change in hue on specified axis

EMF+ manual 2.2.3.11, Microsoft name: TintEffect Object

int U_PMF_IMAGE_get ( const char *  contents,
uint32_t *  Version,
uint32_t *  Type,
const char **  Data 
)

Get data from a U_PMF_IMAGE object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
VersionEmfPlusGraphicsVersion object
TypeImageDataType Enumeration
Dataone of the 2 types of image data

EMF+ manual 2.2.1.4, Microsoft name: EmfPlusImage Object

U_PSEUDO_OBJ* U_PMF_IMAGE_set ( uint32_t  Version,
const U_PSEUDO_OBJ Id 
)

Create and set a U_PMF_IMAGE PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
VersionEmfPlusGraphicsVersion object
IdU_PSEUDO_OBJ containing one of the 2 types of image data

EMF+ manual 2.2.1.4, Microsoft name: EmfPlusImage Object

int U_PMF_IMAGEATTRIBUTES_get ( const char *  contents,
uint32_t *  Version,
uint32_t *  WrapMode,
uint32_t *  ClampColor,
uint32_t *  ObjectClamp 
)

Get data from a U_PMF_IMAGEATTRIBUTES object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
VersionEmfPlusGraphicsVersion object
WrapModeWrapMode object
ClampColorEmfPlusARGB object
ObjectClampObjectClamp Identifiers

EMF+ manual 2.2.1.5, Microsoft name: EmfPlusImageAttributes Object

U_PSEUDO_OBJ* U_PMF_IMAGEATTRIBUTES_set ( uint32_t  Version,
uint32_t  WrapMode,
uint32_t  ClampColor,
uint32_t  ObjectClamp 
)

Create and set a U_PMF_IMAGEATTRIBUTES PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
VersionEmfPlusGraphicsVersion object
WrapModeWrapMode object
ClampColorEmfPlusARGB object
ObjectClampObjectClamp Identifiers

EMF+ manual 2.2.1.5, Microsoft name: EmfPlusImageAttributes Object

int U_PMF_INTEGER15_get ( const char **  contents,
U_FLOAT Value 
)

Get data from a U_PMF_INTEGER15 object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
Value15 bit signed integer (stored in an integer)

EMF+ manual 2.2.2.22, Microsoft name: EmfPlusInteger15 Object

U_PSEUDO_OBJ* U_PMF_INTEGER15_set ( int  Value)

Create and set a U_PMF_INTEGER15 PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
Value15 bit signed integer (stored in an integer, range 32677 <-> -32678, inclusive)

EMF+ manual 2.2.2.22, Microsoft name: EmfPlusInteger15 Object

int U_PMF_INTEGER7_get ( const char **  contents,
U_FLOAT Value 
)

Get data from a U_PMF_INTEGER7 object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
Value7 bit signed integer (stored in an integer)

EMF+ manual 2.2.2.21, Microsoft name: EmfPlusInteger7 Object

U_PSEUDO_OBJ* U_PMF_INTEGER7_set ( int  Value)

Create and set a U_PMF_INTEGER7 PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
Value7 bit signed integer (stored in an integer, range 63 <-> -64, inclusive)

EMF+ manual 2.2.2.21, Microsoft name: EmfPlusInteger7 Object

int U_PMF_KNOWNCURLYGUID_set ( const char *  string)

Identify a known curly GUID.

Parameters
stringCurly GUID form.
Returns
EmageEffects Enumerator

EMF+ manual 2.1.3.1, Microsoft name: ImageEffects Identifier

int U_PMF_LANGUAGEIDENTIFIER_get ( U_PMF_LANGUAGEIDENTIFIER  LId,
int *  SubLId,
int *  PriLId 
)

Get data from a U_PMF_LANGUAGEIDENTIFIER object.

Returns
1 on success, 0 on error
Parameters
LIdU_PMF_LANGUAGEIDENTIFIER from which to extract data
SubLIdExample: code for USA
PriLIdExample: code for English

EMF+ manual 2.2.2.23, Microsoft name: EmfPlusLanguageIdentifier Object

This type is defined as 16 bits in the manual section, but it is only ever used as part of a 32 bit field!

U_PSEUDO_OBJ* U_PMF_LANGUAGEIDENTIFIER_set ( U_PMF_LANGUAGEIDENTIFIER  LId)

Create and set a U_PMF_LANGUAGEIDENTIFIER PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
LIdLanguage Identifier as produced by U_PMF_LANGUAGEIDENTIFIEROBJ_set().

EMF+ manual 2.2.2.23, Microsoft name: EmfPlusLanguageIdentifier Object

U_PMF_LANGUAGEIDENTIFIER U_PMF_LANGUAGEIDENTIFIEROBJ_set ( int  SubLId,
int  PriLId 
)

Create and set a U_PMF_LANGUAGEIDENTIFIER value in 4 byte unsigned int, in NATIVE byte order.

Returns
LID value in least significant two bytes and 0 in most significant two bytes.
Parameters
SubLIdExample: code for USA
PriLIdExample: code for English

EMF+ manual 2.2.2.23, Microsoft name: EmfPlusLanguageIdentifier Object

int U_PMF_LEN_BYTEDATA ( const char *  contents)

Calculate the length in bytes of objects which are a 4 byte count followed by count bytes.

Returns
>=0 length == success, <0 error Object types whose size may be derived with this function are: U_PMF_BOUNDARYPATHDATA U_PMF_BOUNDARYPOINTDATA U_PMF_CUSTOMSTARTCAPDATA U_PMF_PATH U_PMF_LINEPATH U_PMF_REGIONNODEPATH
int U_PMF_LEN_FLOATDATA ( const char *  contents)

Calculate the length in bytes of objects which are a 4 byte Count followed by Count * float bytes.

Returns
>=0 length == success, <0 error Object types whose size may be derived with this function are: U_PMF_COMPOUNDLINEDATA U_PMF_DASHEDLINEDATA
int U_PMF_LEN_OPTPENDATA ( const char *  PenData,
uint32_t  Flags 
)

Return the size of an OptPenData object from an EMF+ record.

Parameters
PenDataAddress in memory where the PenData object starts.
FlagsPenData Flags that indicate which fields are present.
Returns
size of the object in bytes
int U_PMF_LEN_PENDATA ( const char *  PenData)

Return the size of a PenData object from an EMF+ record.

Parameters
PenDataAddress in memory where the PenData object starts.
Returns
size of the object in bytes
int U_PMF_LEN_REL715 ( const char *  contents,
int  Elements 
)

Calculate the length in bytes of a relative path object composed of U_PMF_INTEGER7 and U_PMF_INTER15 values.

Returns
>=0 length == success, <0 error
Parameters
contentsStart of a relative path consisting of int7 and int15 X,Y pairs.
Elementsnumber of relative X,Y pairs in the object
int U_PMF_LINEARGRADIENTBRUSHDATA_get ( const char *  contents,
U_PMF_LINEARGRADIENTBRUSHDATA Lgbd,
const char **  Data 
)

Get data from a U_PMF_LINEARGRADIENTBRUSHDATA object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
LgbdU_PMF_LINEARGRADIENTBRUSHDATA structure, with no variable part
Datavariable part of U_PMF_LINEARGRADIENTBRUSHDATA

EMF+ manual 2.2.2.24, Microsoft name: EmfPlusLinearGradientBrushData Object

U_PSEUDO_OBJ* U_PMF_LINEARGRADIENTBRUSHDATA_set ( const U_PMF_LINEARGRADIENTBRUSHDATA Lgbd,
const U_PSEUDO_OBJ Lgbod 
)

Create and set a U_PMF_LINEARGRADIENTBRUSHDATA PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
LgbdU_PMF_LINEARGRADIENTBRUSHDATA object (constant part)
LgbodU_PSEUDO_OBJ containing a U_PMF_LINEARGRADIENTBRUSHOPTIONALDATA object (variable part of a U_PMF_LINEARGRADIENTBRUSHDATA object)

EMF+ manual 2.2.2.24, Microsoft name: EmfPlusLinearGradientBrushData Object

int U_PMF_LINEARGRADIENTBRUSHOPTIONALDATA_get ( const char *  contents,
uint32_t  Flags,
U_PMF_TRANSFORMMATRIX Tm,
const char **  Bc,
const char **  BfH,
const char **  BfV 
)

Get data from a U_PMF_LINEARGRADIENTBRUSHOPTIONALDATA object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
FlagsBrushData flags - indicates which of the following date fields are present.
TmTransformation matrix
BcU_PMF_BLENDCOLORS object or NULL
BfHU_PMF_BLENDFACTORS (H) object or NULL
BfVU_PMF_BLENDFACTORS (V) object or NULL (WARNING, GDI+ defines this field but does not render it. DO NOT USE.)

EMF+ manual 2.2.2.25, Microsoft name: EmfPlusLinearGradientBrushOptionalData Object

U_PSEUDO_OBJ* U_PMF_LINEARGRADIENTBRUSHOPTIONALDATA_set ( uint32_t *  Flags,
const U_PSEUDO_OBJ Tm,
const U_PSEUDO_OBJ Bc,
const U_PSEUDO_OBJ BfH,
const U_PSEUDO_OBJ BfV 
)

Create and set a U_PMF_LINEARGRADIENTBRUSHOPTIONALDATA PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
FlagsBits are set that indicate which of the following were included. The caller must clear before passing it in.
TmU_PSEUDO_OBJ containing a U_PMF_TRANSFORMMATRIX object
BcU_PSEUDO_OBJ containing a U_PMF_BLENDCOLORS object or NULL
BfHU_PSEUDO_OBJ containing a U_PMF_BLENDFACTORS (H) object or NULL
BfVU_PSEUDO_OBJ containing a U_PMF_BLENDFACTORS (V) object or NULL (WARNING, GDI+ defines this field but does not render it. DO NOT USE.)

EMF+ manual 2.2.2.25, Microsoft name: EmfPlusLinearGradientBrushOptionalData Object

The rectangular gradients repeat in a tiled pattern. Tm can rotate and offset the gradient within each tile. The gradient wraps when it is offset.

int U_PMF_LINEPATH_get ( const char *  contents,
int32_t *  Size,
const char **  Data 
)

Get data from a U_PMF_LINEPATH object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
SizeBytes in Data
DataOutline path

EMF+ manual 2.2.2.26, Microsoft name: EmfPlusLinePath Object

U_PSEUDO_OBJ* U_PMF_LINEPATH_set ( const U_PSEUDO_OBJ Path)

Create and set a U_PMF_LINEPATH PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
PathU_PSEUDO_OBJ containing a U_PMF_PATH object

EMF+ manual 2.2.2.26, Microsoft name: EmfPlusLinePath Object

void U_PMF_MEMCPY_DSTSHIFT ( char **  Dst,
const void *  Src,
size_t  Size 
)

copy data and shift destination pointer by the amount of data moved

Parameters
DstDestination in memory (this must not be NULL)
SrcSource in memory (if this is NULL, fill with that many zero bytes instead)
SizeNumber of bytes to move
void U_PMF_MEMCPY_SRCSHIFT ( void *  Dst,
const char **  Src,
size_t  Size 
)

copy data and shift source pointer by the amount of data moved

Parameters
DstDestination in memory
SrcSource in memory
SizeNumber of bytes to move
int U_PMF_METAFILE_get ( const char *  contents,
uint32_t *  Type,
uint32_t *  Size,
const char **  Data 
)

Get data from a U_PMF_METAFILE object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
Type
SizeBytes in Data
DataVarious types of data, like an EMF metafile, WMF metafile, another EMF+ metafile

EMF+ manual 2.2.2.27, Microsoft name: EmfPlusMetafile Object

U_PSEUDO_OBJ* U_PMF_METAFILE_set ( void  )

Create and set a U_PMF_METAFILE object (NOT SUPPORTED!)

Returns
Null

EMF+ manual 2.2.2.27, Microsoft name: EmfPlusMetafile Object

int U_PMF_PALETTE_get ( const char *  contents,
uint32_t *  Flags,
uint32_t *  Elements,
const char **  Colors 
)

Get data from a U_PMF_PALETTE object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
FlagsPaletteStyle flags
ElementsMembers in the array
ColorsPalette data (array of colors)

EMF+ manual 2.2.2.28, Microsoft name: EmfPlusPalette Object

U_PSEUDO_OBJ* U_PMF_PALETTE_set ( uint32_t  Flags,
uint32_t  Elements,
const U_PMF_ARGB Pd 
)

Create and set a U_PMF_PALETTE PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
FlagsPaletteStyle flags
ElementsMembers in Lengths
PdArray of U_PMF_ARGB holding colors of palettes. (Palette Data)

EMF+ manual 2.2.2.28, Microsoft name: EmfPlusPalette Object

int U_PMF_PATH_get ( const char *  contents,
uint32_t *  Version,
uint32_t *  Count,
uint16_t *  Flags,
const char **  Points,
const char **  Types 
)

Get data from a U_PMF_PATH object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
VersionEmfPlusGraphicsVersion object
CountNumber of points and point types in this object
FlagsPathPoint Flags
Pointsarray of points type PMFPointR, PMFPoint, or PMFPointF
Typesarray of U_PMF_PATHPOINTTYPERLE and/or U_PMF_PATHPOINTTYPE

EMF+ manual 2.2.1.6, Microsoft name: EmfPlusPath Object

U_PSEUDO_OBJ* U_PMF_PATH_set ( uint32_t  Version,
const U_PSEUDO_OBJ Points,
const U_PSEUDO_OBJ Types 
)

Create and set a U_PMF_PATH PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
VersionEmfPlusGraphicsVersion object
PointsU_PSEUDO_OBJ containing array of points (of type PMFPointR, PMFPoint, or PMFPointF, determined by U_PPF_P and U_PPF_C bits in Flags)
TypesU_PSEUDO_OBJ containing array of types (U_PMF_PATHPOINTTYPE or U_PMF_PATHPOINTTYPERLE, determined by U_PPF_R big in Flags)

EMF+ manual 2.2.1.6, Microsoft name: EmfPlusPath Object

U_PSEUDO_OBJ* U_PMF_PATH_set2 ( uint32_t  Version,
const U_DPSEUDO_OBJ Path 
)

Create and set a U_PMF_PATH PseudoObject that uses U_PMF_POINTF coordinates.

Returns
Pointer to PseudoObject, NULL on error
Parameters
VersionEmfPlusGraphicsVersion object
PathU_DPSEUDO_OBJ containing a path.

EMF+ manual 2.2.1.6, Microsoft name: EmfPlusPath Object

U_PSEUDO_OBJ* U_PMF_PATH_set3 ( uint32_t  Version,
const U_DPSEUDO_OBJ Path 
)

Create and set a U_PMF_PATH PseudoObject that uses U_PMF_POINT (int 16) coordinates.

Returns
Pointer to PseudoObject, NULL on error
Parameters
VersionEmfPlusGraphicsVersion object
PathU_DPSEUDO_OBJ containing a path.

EMF+ manual 2.2.1.6, Microsoft name: EmfPlusPath Object

int U_PMF_PATHGRADIENTBRUSHDATA_get ( const char *  contents,
U_PMF_PATHGRADIENTBRUSHDATA Pgbd,
const char **  Gradient,
const char **  Boundary,
const char **  Data 
)

Get data from a U_PMF_PATHGRADIENTBRUSHDATA object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
Pgbdconstant part of U_PMF_PATHGRADIENTBRUSHDATA object
Gradientvariable part of U_PMF_LINEARGRADIENTBRUSHDATA, Color Gradient with Elements members
Boundaryvariable part of U_PMF_LINEARGRADIENTBRUSHDATA, U_PMF_BOUNDARYPATHDATA object if BrushDataPath bit set in Flag, else U_PMF_BOUNDARYPOINTDATA object
Datavariable part of U_PMF_LINEARGRADIENTBRUSHDATA, exact composition depends on Flags

EMF+ manual 2.2.2.29, Microsoft name: EmfPlusPathGradientBrushData Object

U_PSEUDO_OBJ* U_PMF_PATHGRADIENTBRUSHDATA_set ( uint32_t  Flags,
int32_t  WrapMode,
U_PMF_ARGB  CenterColor,
U_PMF_POINTF  Center,
const U_PSEUDO_OBJ Gradient,
const U_PSEUDO_OBJ Boundary,
const U_PSEUDO_OBJ Data 
)

Create and set a U_PMF_PATHGRADIENTBRUSHDATA PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
FlagsPaletteStyle flags
WrapModeWrapMode enumeration
CenterColorU_PMF_ARGB Center color
CenterCenter coordinates
GradientU_PSEUDO_OBJ containing an Array of U_PMF_ARGB holding colors of Gradient
BoundaryU_PSEUDO_OBJ containing a U_PMF_BOUNDARYPATHDATA or U_PMF_BOUNDARYPOINTDATA object. (Boundary Data)
Datavariable part of U_PMF_LINEARGRADIENTBRUSHDATA, exact composition depends on Flags

EMF+ manual 2.2.2.29, Microsoft name: EmfPlusPathGradientBrushData Object

int U_PMF_PATHGRADIENTBRUSHOPTIONALDATA_get ( const char *  contents,
uint32_t  Flags,
U_PMF_TRANSFORMMATRIX Matrix,
const char **  Pattern,
const char **  Data 
)

Get data from a U_PMF_PATHGRADIENTBRUSHOPTIONALDATA object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
Flagsbits set to indicate the presence of FillData and/or LineData
MatrixTransformation matrix
PatternBlend Pattern
DataFocus scales for the brush

EMF+ manual 2.2.2.30, Microsoft name: EmfPlusPathGradientBrushOptionalData Object

U_PSEUDO_OBJ* U_PMF_PATHGRADIENTBRUSHOPTIONALDATA_set ( uint32_t  Flags,
const U_PSEUDO_OBJ Tm,
const U_PSEUDO_OBJ Pd,
const U_PSEUDO_OBJ Fsd 
)

Create and set a U_PMF_PATHGRADIENTBRUSHOPTIONALDATA PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
FlagsPaletteStyle flags
TmU_PSEUDO_OBJ containing a U_PMF_TRANSFORMMATRIX. (Transformation matrix)
PdU_PSEUDO_OBJ containing a U_PMF_BLENDCOLORS or U_PMF_BLENDFACTORS object. (Pattern Data)
FsdU_PSEUDO_OBJ containing a U_PMF_FOCUSSSCALEDATA object. (Focus Scale Data)

EMF+ manual 2.2.2.30, Microsoft name: EmfPlusPathGradientBrushOptionalData Object

int U_PMF_PATHPOINTTYPE_get ( const char *  contents,
int *  Flags,
int *  Type 
)

Get data from a U_PMF_PATHPOINTTYPE object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
FlagsPathPointType flags
TypePathPointType enumeration

EMF+ manual 2.2.2.31, Microsoft name: EmfPlusPathPointType Object

Note: order of 4bit fields appears to be shown in the LE column, not as documented in the BE column.

U_PSEUDO_OBJ* U_PMF_PATHPOINTTYPE_set ( uint32_t  Elements,
const uint8_t *  Ppt 
)

Create and set an ARRAY of U_PMF_PATHPOINTTYPE objects.

Returns
Pointer to PseudoObject, NULL on error
Parameters
ElementsNumber of entries in Flags and Enumerations
PptArray of unsigned bytes, lower 4 bits hold the PathPointType flag upper 4 bits hold the PathPointType enumeration.

EMF+ manual 2.2.2.31, Microsoft name: EmfPlusPathPointType Object

U_PSEUDO_OBJ* U_PMF_PATHPOINTTYPE_set2 ( uint32_t  Elements,
uint8_t  First,
uint8_t  Others 
)

Create and set an ARRAY of U_PMF_PATHPOINTTYPE objects, with a preceding Elements count.

Returns
Pointer to PseudoObject, NULL on error
Parameters
ElementsNumber of elements to add. First is added once and Others Elements-1 times.
FirstApply to first point, unsigned byte, lower 4 bits hold the PathPointType flag upper 4 bits hold the PathPointType enumeration.
OthersApply to all other points, unsigned byte, lower 4 bits hold the PathPointType flag upper 4 bits hold the PathPointType enumeration.

EMF+ manual 2.2.2.31, Microsoft name: EmfPlusPathPointType Object

int U_PMF_PATHPOINTTYPERLE_get ( const char *  contents,
int *  Bezier,
int *  RL,
int *  Ppt 
)

Get data from a U_PMF_PATHPOINTTYPERLE object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
BezierSet: Bezier curve, Clear: straight line
RLRun Length
PptPathPointType enumeration

EMF+ manual 2.2.2.32, Microsoft name: EmfPlusPathPointTypeRLE Object

U_PSEUDO_OBJ* U_PMF_PATHPOINTTYPERLE_set ( uint32_t  Elements,
const uint8_t *  Bz,
const uint8_t *  RL,
const uint8_t *  Ppte 
)

Create and set an ARRAY of U_PMF_PATHPOINTTYPERLE objects.

Returns
Pointer to PseudoObject containing first the number of elements, then an array of U_PMF_PATHPOINTTYPERLE, NULL on error
Parameters
ElementsNumber of entries in the arrays
BzArray of unsigned bytes, if not zero, element has Bezier bit set
RLArray of unsigned bytes, Run lengths.
PpteArray of unsigned bytes, PathPointType enumerations.

EMF+ manual 2.2.2.32, Microsoft name: EmfPlusPathPointTypeRLE Object

int U_PMF_PEN_get ( const char *  contents,
uint32_t *  Version,
uint32_t *  Type,
const char **  PenData,
const char **  Brush 
)

Get data from a U_PMF_PEN object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
VersionEmfPlusGraphicsVersion object
Typemust be zero
PenDataPen description
BrushBrush Description

EMF+ manual 2.2.1.7, Microsoft name: EmfPlusPen Object

U_PSEUDO_OBJ* U_PMF_PEN_set ( uint32_t  Version,
const U_PSEUDO_OBJ PenData,
const U_PSEUDO_OBJ Brush 
)

Create and set a U_PMF_PEN PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
VersionEmfPlusGraphicsVersion object
PenDataU_PSEUDO_OBJ containing U_PMF_PENDATA object
BrushU_PSEUDO_OBJ containing U_PMF_BRUSH object

EMF+ manual 2.2.1.7, Microsoft name: EmfPlusPen Object

int U_PMF_PENDATA_get ( const char *  contents,
uint32_t *  Flags,
uint32_t *  Unit,
U_FLOAT Width,
const char **  Data 
)

Get data from a U_PMF_PENDATA object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
FlagsPenData flags
UnitUnitType enumeration
WidthWidth in units set by Unit
DataOptional pen data, exact composition depends on Flags

EMF+ manual 2.2.2.33, Microsoft name: EmfPlusPenData Object

U_PSEUDO_OBJ* U_PMF_PENDATA_set ( uint32_t  Unit,
U_FLOAT  Width,
const U_PSEUDO_OBJ Pod 
)

Create and set a U_PMF_PENDATA PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
UnitUnitType enumeration
WidthWidth in units set by Unit
PodU_PSEUDO_OBJ containing first the PenData flags then a U_PMF_PENOPTIONALDATA object (the second part may be an empty if Flags is 0)

EMF+ manual 2.2.2.33, Microsoft name: EmfPlusPenData Object

int U_PMF_PENOPTIONALDATA_get ( const char *  contents,
uint32_t  Flags,
U_PMF_TRANSFORMMATRIX Matrix,
int32_t *  StartCap,
int32_t *  EndCap,
uint32_t *  Join,
U_FLOAT MiterLimit,
int32_t *  Style,
int32_t *  DLCap,
U_FLOAT DLOffset,
const char **  DLData,
int32_t *  Alignment,
const char **  CmpndLineData,
const char **  CSCapData,
const char **  CECapData 
)

Get data from a U_PMF_PENOPTIONALDATA object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
Flags;PenData Flags - indicated which of the many fields are present.
Matrix;Transformation matrix
StartCapLineCapType enumeration
EndCapLineCapType enumeration
JoinLineJoinType enumeration
MiterLimitMaximum (miter length / line width)
StyleLineStyle enumeration
DLCapDashedLineCapType enumeration
DLOffsetDistance line start to first dash start
DLDataDash and space widths
AlignmentPenAlignment enumeration
CmpndLineDataCompount Line (parallel lines drawn instead of one)
CSCapDataCustom start cap
CECapDataCustom end cap

EMF+ manual 2.2.2.34, Microsoft name: EmfPlusPenOptionalData Object

This object consists of a large number of optional and or variable values, which are returned, or not, depending on bits in Flags.

U_PSEUDO_OBJ* U_PMF_PENOPTIONALDATA_set ( uint32_t  Flags,
U_PSEUDO_OBJ Tm,
int32_t  StartCap,
int32_t  EndCap,
uint32_t  Join,
U_FLOAT  MiterLimit,
int32_t  Style,
int32_t  DLCap,
U_FLOAT  DLOffset,
U_PSEUDO_OBJ DLData,
int32_t  PenAlignment,
U_PSEUDO_OBJ CmpndLineData,
U_PSEUDO_OBJ CSCapData,
U_PSEUDO_OBJ CECapData 
)

Create and set a U_PMF_PENOPTIONALDATA PseudoObject.

Returns
Pointer to PseudoObject, NULL on error. Returned PO contains first the Flags, then the PO proper.
Parameters
FlagsDetermines which of the values are stored.
TmU_PSEUDO_OBJ containing a U_PMF_TRANSFORMMATRIX object (Transformation matrix)
StartCapLineCapType enumeration
EndCapLineCapType enumeration
JoinLineJoinType enumeration
MiterLimitMaximum (miter length / line width)
StyleLineStyle enumeration
DLCapDashedLineCapType enumeration
DLOffsetDistance line start to first dash start
DLDataU_PSEUDO_OBJ containing a U_PMF_DASHEDLINEDATA object Dash and space widths
PenAlignmentPenAlignment enumeration
CmpndLineDataU_PSEUDO_OBJ containing a U_PMF_COMPOUNDLINEDATA object Compount Line (parallel lines drawn instead of one)
CSCapDataU_PSEUDO_OBJ containing a U_PMF_CUSTOMSTARTCAPDATA object Custom start cap
CECapDataU_PSEUDO_OBJ containing a U_PMF_CUSTOMENDCAPDATA object Custom end cap

EMF+ manual 2.2.2.34, Microsoft name: EmfPlusPenOptionalData Object

int U_PMF_POINT_get ( const char **  contents,
U_FLOAT X,
U_FLOAT Y 
)

Get data from a U_PMF_POINT object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data. On return position is offset by sizeof(U_PMF_POINT).
XX coordinate
YY coordinate

EMF+ manual 2.2.2.35, Microsoft name: EmfPlusPoint Object

U_PSEUDO_OBJ* U_PMF_POINT_set ( uint32_t  Elements,
const U_PMF_POINT Coords 
)

Create and set an ARRAY of U_PMF_POINT objects.

Returns
Pointer to PseudoObject, NULL on error
Parameters
ElementsNumber of pairs of points in Coords
CoordsArray of X,Y pairs.

EMF+ manual 2.2.2.35, Microsoft name: EmfPlusPoint Object

int U_PMF_POINTF_get ( const char **  contents,
U_FLOAT X,
U_FLOAT Y 
)

Get data from a U_PMF_POINTF object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data. On return position is offset by sizeof(U_PMF_POINTF).
XX coordinate
YY coordinate

EMF+ manual 2.2.2.36, Microsoft name: EmfPlusPointF Object

U_PSEUDO_OBJ* U_PMF_POINTF_set ( uint32_t  Elements,
const U_PMF_POINTF Coords 
)

Create and set an ARRAY of U_PMF_POINTF objects, with a leading Elements value.

Returns
Pointer to PseudoObject, NULL on error
Parameters
ElementsNumber of pairs of points in Coords
CoordsArray of X,Y pairs.

EMF+ manual 2.2.2.36, Microsoft name: EmfPlusPointF Object

int U_PMF_POINTR_get ( const char **  contents,
U_FLOAT X,
U_FLOAT Y 
)

Get data from a U_PMF_POINTR object.

Returns
size in bytes traversed on success, 0 on error
Parameters
contentsRecord from which to extract data. On return position is offset by returned size.
XX coordinate
YY coordinate

EMF+ manual 2.2.2.37, Microsoft name: EmfPlusPointR Object

U_PSEUDO_OBJ* U_PMF_POINTR_set ( uint32_t  Elements,
const U_PMF_POINTF Coords 
)

Create and set an ARRAY of U_PMF_POINTR objects.

Returns
Pointer to PseudoObject, NULL on error
Parameters
ElementsNumber of pairs of points in Coords
CoordsArray of X,Y pairs. These are absolute coordinates, they are converted to Relative here.

EMF+ manual 2.2.2.37, Microsoft name: EmfPlusPointR Object

int U_PMF_PTRSAV_COND ( const char **  Dst,
const char *  Src,
int  Doit 
)

save pointer to data and shift source pointer by the amount of data moved

Returns
1 on sucess, 0 on error
Parameters
DstDestination in memory
SrcSource in memory or NULL. If NULL Dst is set to NULL.
DoitAssign if true, otherwise, set to NULL
void U_PMF_PTRSAV_SHIFT ( const char **  Dst,
const char **  Src,
size_t  Size 
)

save pointer to data and shift source pointer by the amount of data moved

Parameters
DstDestination in memory
SrcSource in memory or NULL. If NULL Dst is set to NULL.
SizeNumber of bytes to move
U_PSEUDO_OBJ* U_PMF_RECT4_set ( int16_t  X,
int16_t  Y,
int16_t  Width,
int16_t  Height 
)

Create and set a U_PMF_RECT object.

Returns
Pointer to PseudoObject, NULL on error
Parameters
XUL X value
YUL Y value
WidthWidth
HeightHeight

EMF+ manual 2.2.2.38, Microsoft name: EmfPlusRect Object

int U_PMF_RECT_get ( const char **  contents,
int16_t *  X,
int16_t *  Y,
int16_t *  Width,
int16_t *  Height 
)

Get data from a U_PMF_RECT object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
XUL X value
YUL Y value
WidthWidth
HeightHeight

EMF+ manual 2.2.2.38, Microsoft name: EmfPlusRect Object

U_PSEUDO_OBJ* U_PMF_RECT_set ( U_PMF_RECT Rect)

Create and set a U_PMF_RECT object.

Returns
Pointer to PseudoObject, NULL on error
Parameters
RectU_PMF_RECT structures

EMF+ manual 2.2.2.38, Microsoft name: EmfPlusRect Object

U_PSEUDO_OBJ* U_PMF_RECTF4_set ( U_FLOAT  X,
U_FLOAT  Y,
U_FLOAT  Width,
U_FLOAT  Height 
)

Create and set a U_PMF_RECTF object in a PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
XUL X value
YUL Y value
WidthWidth
HeightHeight

EMF+ manual 2.2.2.39, Microsoft name: EmfPlusRectF Object

int U_PMF_RECTF_get ( const char **  contents,
U_FLOAT X,
U_FLOAT Y,
U_FLOAT Width,
U_FLOAT Height 
)

Get data from a U_PMF_RECTF object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
XUL X value
YUL Y value
WidthWidth
HeightHeight

EMF+ manual 2.2.2.39, Microsoft name: EmfPlusRectF Object

U_PSEUDO_OBJ* U_PMF_RECTF_set ( U_PMF_RECTF Rect)

Create and set a U_PMF_RECTF object in a PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
RectU_PMF_RECTF structure

EMF+ manual 2.2.2.39, Microsoft name: EmfPlusRectF Object

U_PSEUDO_OBJ* U_PMF_RECTFN_set ( uint32_t  Elements,
U_PMF_RECTF Rects 
)

Create and set an array of U_PMF_RECTF objects in a PseudoObject.

Returns
Pointer to PseudoObject, NULL on error. PseudoObject contains Elements followed by the array of U_PMF_RECTF objects.
Parameters
ElementsNumber of elements in Rects
RectsArray of U_PMF_RECTF structures

EMF+ manual 2.2.2.39, Microsoft name: EmfPlusRectF Object

U_PSEUDO_OBJ* U_PMF_RECTN_set ( uint32_t  Elements,
U_PMF_RECT Rects 
)

Create and set an array of U_PMF_RECT objects in a PseudoObject.

Returns
Pointer to PseudoObject, NULL on error. PseudoObject contains Elements followed by the array of U_PMF_RECT objects.
Parameters
ElementsNumber of elements in Rects
RectsArray of U_PMF_RECT structures

EMF+ manual 2.2.2.38, Microsoft name: EmfPlusRect Object

int U_PMF_REGION_get ( const char *  contents,
uint32_t *  Version,
uint32_t *  Count,
const char **  Nodes 
)

Get data from a U_PMF_REGION object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
VersionEmfPlusGraphicsVersion object
CountNumber of CHILD nodes. This is one less than the total number of U_PMF_REGIONNODE objects in Nodes.
NodesNodes defining region

EMF+ manual 2.2.1.8, Microsoft name: EmfPlusRegion Object

U_PSEUDO_OBJ* U_PMF_REGION_set ( uint32_t  Version,
uint32_t  Count,
const U_PSEUDO_OBJ Nodes 
)

Create and set a U_PMF_REGION PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
VersionEmfPlusGraphicsVersion object
CountNumber of CHILD nodes. This is one less than the total number of U_PMF_REGIONNODE objects in Nodes.
NodesU_PSEUDO_OBJ containing U_PMF_REGIONNODE object (Nodes defining region, may be a single element or a binary tree)

EMF+ manual 2.2.1.8, Microsoft name: EmfPlusRegion Object

int U_PMF_REGIONNODE_get ( const char *  contents,
uint32_t *  Type,
const char **  Data 
)

Get data from a U_PMF_REGIONNODE object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
TypeRegionNodeDataType
DataDepending on Type: U_PMF_REGIONNODEPATH, U_PMF_RECTF, or U_PMF_REGIONNODECHILDNODES

EMF+ manual 2.2.2.40, Microsoft name: EmfPlusRegionNode Object

U_PSEUDO_OBJ* U_PMF_REGIONNODE_set ( int32_t  Type,
const U_PSEUDO_OBJ Rnd 
)

Create and set a U_PMF_REGIONNODE PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
TypeRegionNodeDataType Enumeration
Rnd(optional) U_PSEUDO_OBJ containing a U_PMF_REGIONNODEPATH, U_PMF_RECTF, or U_PMF_REGIONNODECHILDNODES object (Region Node Data)

EMF+ manual 2.2.2.40, Microsoft name: EmfPlusRegionNode Object

U_PSEUDO_OBJ* U_PMF_REGIONNODECHILDNODES_set ( const U_PSEUDO_OBJ Left,
const U_PSEUDO_OBJ Right 
)

Create and set a U_PMF_REGIONNODECHILDNODES PseudoObject.

Returns
Pointer to PseudoObject containing a U_PMF_REGIONNODECHILDNODES_OID object, NULL on error
Parameters
LeftU_PSEUDO_OBJ containing a U_PMF_REGIONNODE object
RightU_PSEUDO_OBJ containing a U_PMF_REGIONNODE object

EMF+ manual 2.2.2.41, Microsoft name: EmfPlusRegionNodeChildNodes Object

int U_PMF_REGIONNODEPATH_get ( const char *  contents,
int32_t *  Size,
const char **  Data 
)

Get data from a U_PMF_REGIONNODEPATH object.

There is no U_PMF_REGIONNODECHILDNODES_get!

The Region object is recursive allowing U_PMF_REGIONNODECHILDNODES -> U_PMF_REGIONNODE -> U_PMF_REGIONNODECHILDNODES etc. So the data stored in each node must be handled as the tree is followed recursively.

See U_PMF_REGIONNODECHILDNODES_print() and U_PMF_REGIONNODE_print() for an example.

EMF+ manual 2.2.2.41, Microsoft name: EmfPlusRegionNodeChildNodes Object

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
SizeBytes in Data
DataBoundary of region node

EMF+ manual 2.2.2.42, Microsoft name: EmfPlusRegionNodePath Object

U_PSEUDO_OBJ* U_PMF_REGIONNODEPATH_set ( const U_PSEUDO_OBJ Path)

Create and set a U_PMF_REGIONNODEPATH PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
PathU_PSEUDO_OBJ containing a U_PMF_PATH object

EMF+ manual 2.2.2.42, Microsoft name: EmfPlusRegionNodePath Object

void U_PMF_REPCPY_DSTSHIFT ( char **  Dst,
const void *  Src,
size_t  Size,
size_t  Reps 
)

Copy the single instance at Src repeatedly to Dst.

Parameters
DstDestination in memory
SrcSource in memory (if this is NULL, fill with that many zero bytes instead)
Sizenumber of bytes in single instance that is template.
RepsNumber of instances of the template to opy
int U_PMF_SERIAL_array_copy_get ( const char **  Src,
void **  Dst,
size_t  Units,
size_t  Reps,
int  SE,
int  Cond 
)

Conditionally extract an array of data from a source, allocating space to hold it.

Returns
1 on success, 0 on error.
Parameters
Srcwhere the data is coming from. It is incremented by the number of bytes retrieved.
DstCaller must free. Where the pointer to the data will be stored. Reps * Units bytes will be allocated,
Unitsnumber of bytes in each unit of the data field
Repsnumber of repeats of units in the data field. If a Ptr is NULL, then Units*Reps 0 bytes are stored. If a Ptr is NOT NULL, and Units or Reps, is zero an error is signaled. If a Ptr is NULL and Units*Reps is 0, nothing happens.
SElogical (Source Endian). Only relevant for Sizes of 2 or 4 Indicates when Bytes may need to be rearranged when they are retrieved. U_XE no change (this is used when the data has already been set to the proper orientation or it is not known) U_LE source is Little Endian U_BE source is Big Endian. U_XX error
CondStore the data into *Dst if true, set *Dst to NULL otherwise.
int U_PMF_SERIAL_get ( const char **  Src,
void *  Dst,
size_t  Units,
size_t  Reps,
int  SE 
)

Extract a single data field from a source.

Returns
1 on success, 0 on error.
Parameters
Srcwhere the data is coming from. It is incremented by the number of bytes retrieved.
Dstwhere the data will be stored. This must either be NULL (in which case the Src is advanced and nothing is stored, or it must be allocated to Reps * Units bytes!!!!
Unitsnumber of bytes in each unit of the data field
Repsnumber of repeats of units in the data field. If a Ptr is NULL, then Units*Reps 0 bytes are stored. If a Ptr is NOT NULL, and Units or Reps, is zero an error is signaled. If a Ptr is NULL and Units*Reps is 0, nothing happens.
SElogical (Source Endian). Only relevant for Sizes of 2 or 4 Indicates when Bytes may need to be rearranged when they are retrieved. U_XE no change (this is used when the data has already been set to the proper orientation or it is not known) U_LE source is Little Endian U_BE source is Big Endian. U_XX error
U_PSEUDO_OBJ* U_PMF_SERIAL_set ( uint32_t  Type,
const U_SERIAL_DESC List 
)

create a PseudoObject with data in the correct byte order for an EMF+ file.

Returns
The PseudoObject on success, NULL on error.
Parameters
Typethe type of the PseudoObject that is created. Allowed values are in U_PID_Values.
Listan array of U_SERIAL_DESC structures containing the data to store.

The U_PMF_SERIAL_set() function should not ever be called directly by end user code.

Each U_SERIAL_DESC element in List consists of Data fields and a description of that data. List is terminated by the first U_SERIAL_DESC element having a TE value of U_XX.

Data fields: an array of a basic type of Units bytes repeated Reps times with the target byte order described in TE.

Ptrs: Address of the first byte of the data fields.

Units: Number of bytes of in each data field unit

Reps: Number of repeats of the unit in data fields. If a Ptr is NULL, and Units*Reps is not zero, then Units*Reps 0x00 bytes are stored. If a Ptr is NULL, and Units*Reps is zero, this U_SERIAL_DESC is ignored. if a Ptr is NOT NULL, and Units * Reps is not zero, then the data is stored in the indicated byte order. If a Ptr is NOT NULL, and Units or Reps is zero an error is signaled.

TE: (Target Endian) the byte order in which to store each unit of a data field as defined in U_Endian. Byte swapping is only enabled when Units is 2 or 4. In addition to the byte order values U_XE, U_LE, and U_BE, and the array terminator U_XX, the value may also be U_RP. U_RP means there is only a single unit in the data fields, but it is to be copied to the target Reps times. That is, the data was passed in with a form of run length encoding.

Creates an empty PseudoObject if all pointers are NULL and all sizes are zero.

int U_PMF_SOLIDBRUSHDATA_get ( const char *  contents,
U_PMF_ARGB Color 
)

Get data from a U_PMF_SOLIDBRUSHDATA object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
ColorColor of brush

EMF+ manual 2.2.2.43, Microsoft name: EmfPlusSolidBrushData Object

U_PSEUDO_OBJ* U_PMF_SOLIDBRUSHDATA_set ( const U_PSEUDO_OBJ Color)

Create and set a U_PMF_SOLIDBRUSHDATA PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
ColorU_PSEUDO_OBJ containing a U_PMF_ARGB object

EMF+ manual 2.2.2.43, Microsoft name: EmfPlusSolidBrushData Object

int U_PMF_STRINGFORMAT_get ( const char *  contents,
U_PMF_STRINGFORMAT Sfs,
const char **  Data 
)

Get data from a U_PMF_STRINGFORMAT object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
Sfspointer to U_PMF_STRINGFORMAT structure, with no variable part
Datapointer to variable part

EMF+ manual 2.2.1.9, Microsoft name: EmfPlusStringFormat Object

U_PSEUDO_OBJ* U_PMF_STRINGFORMAT_set ( U_PMF_STRINGFORMAT Sfs,
const U_PSEUDO_OBJ Sfd 
)

Create and set a U_PMF_STRINGFORMAT PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
Sfspointer to U_PMF_STRINGFORMAT structure, with no variable part
Sfd(optional) U_PSEUDO_OBJ containing U_PMF_STRINGFORMATDATA object

EMF+ manual 2.2.1.9, Microsoft name: EmfPlusStringFormat Object

int U_PMF_STRINGFORMATDATA_get ( const char *  contents,
uint32_t  TabStopCount,
uint32_t  RangeCount,
const U_FLOAT **  TabStops,
const U_PMF_CHARACTERRANGE **  CharRange 
)

Get data from a U_PMF_STRINGFORMATDATA object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
TabStopCountEntries in TabStop array
RangeCountEntries in CharRange array
TabStopsArray of tabstop locations
CharRangeArray of character ranges in the text

EMF+ manual 2.2.2.44, Microsoft name: EmfPlusStringFormatData Object

U_PSEUDO_OBJ* U_PMF_STRINGFORMATDATA_set ( uint32_t  TabStopCount,
U_FLOAT TabStops,
const U_PSEUDO_OBJ Ranges 
)

Create and set a U_PMF_STRINGFORMATDATA PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
TabStopCountEntries in TabStop array
TabStops(optional) Array of tabstop locations
Ranges(optional) U_PSEUDO_OBJ containing an array of U_PMF_CHARACTERRANGE objects

EMF+ manual 2.2.2.44, Microsoft name: EmfPlusStringFormatData Object

int U_PMF_TEXTUREBRUSHDATA_get ( const char *  contents,
uint32_t *  Flags,
int32_t *  WrapMode,
const char **  Data 
)

Get data from a U_PMF_TEXTUREBRUSHDATA object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
FlagsBrushData flags
WrapModeWrapMode enumeration
DataOptional texture data

EMF+ manual 2.2.2.45, Microsoft name: EmfPlusTextureBrushData Object

U_PSEUDO_OBJ* U_PMF_TEXTUREBRUSHDATA_set ( uint32_t  Flags,
uint32_t  WrapMode,
const U_PSEUDO_OBJ Tbod 
)

Create and set a U_PMF_TEXTUREBRUSHDATA PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
FlagsBrushData flags
WrapModeWrapMode enumeration
TbodU_PSEUDO_OBJ containing an U_PMF_TEXTUREBRUSHOPTIONALDATA object

EMF+ manual 2.2.2.45, Microsoft name: EmfPlusTextureBrushData Object

int U_PMF_TEXTUREBRUSHOPTIONALDATA_get ( const char *  contents,
int  HasImage,
U_PMF_TRANSFORMMATRIX Matrix,
const char **  Image 
)

Get data from a U_PMF_TEXTUREBRUSHOPTIONALDATA object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HasImageTrue if this object has an Image
MatrixTransformation matrix, present if Flag BrushDataTransform is set.
ImageImage that contains the texture.

EMF+ manual 2.2.2.46, Microsoft name: EmfPlusTextureBrushOptionalData Object

U_PSEUDO_OBJ* U_PMF_TEXTUREBRUSHOPTIONALDATA_set ( const U_PSEUDO_OBJ Tm,
const U_PSEUDO_OBJ Image 
)

Create and set a U_PMF_TEXTUREBRUSHOPTIONALDATA PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
Tm(optional) U_PSEUDO_OBJ containing an U_PMF_TRANSFORMMATRIX object
Image(optional) U_PSEUDO_OBJ containing an U_PMF_IMAGE object

EMF+ manual 2.2.2.46, Microsoft name: EmfPlusTextureBrushOptionalData Object

int U_PMF_TRANSFORMMATRIX_get ( const char *  contents,
U_PMF_TRANSFORMMATRIX Matrix 
)

Get data from a U_PMF_TRANSFORMMATRIX object.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
MatrixTransformation matrix, present if Flag BrushDataTransform is set.

EMF+ manual 2.2.2.47, Microsoft name: EmfPlusTransformMatrix Object

U_PSEUDO_OBJ* U_PMF_TRANSFORMMATRIX_set ( U_PMF_TRANSFORMMATRIX Tm)

Create and set a U_PMF_TRANSFORMMATRIX PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
TmU_PMF_TRANSFORMMATRIX_ object

EMF+ manual 2.2.2.47, Microsoft name: EmfPlusTransformMatrix Object

int U_PMF_VARPOINTS_get ( const char **  contents,
uint16_t  Flags,
int  Elements,
U_PMF_POINTF **  Points 
)

Get data from a variable POINTS object, which may be U_PMF_POINTS, U_PMF_POINTF, or U_PMF_POINTR.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
FlagsRecord flags (bits U_PPF_C and U_PPF_P are referenced)
ElementsNumber of points to retrieve.
PointsCaller must free. Array of U_PMF_POINTF coordinates.
int U_PMF_VARRECTS_get ( const char **  contents,
uint16_t  Flags,
int  Elements,
U_PMF_RECTF **  Rects 
)

Get data from a variable RECTS object, which may be U_PMF_RECT or U_PMF_RECTF.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
FlagsRecord flags (bit U_PPF_C is referenced)
ElementsNumber of rects to retrieve.
RectsCaller must free. Array of U_PMF_RECTF coordinates.

Rects in record may be either U_PMF_RECT or U_PMF_RECTF, but this function always returns U_PMF_RECTF

int U_PMR_BEGINCONTAINER_get ( const char *  contents,
U_PMF_CMN_HDR Header,
int *  UTenum,
U_PMF_RECTF DstRect,
U_PMF_RECTF SrcRect,
uint32_t *  StackID 
)

Get data from a U_PMR_BEGINCONTAINER record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header
UTenumUnitType enumeration
DstRectwith SrcRect specifies a transformation
SrcRectwith DstRect specifies a transformation
StackIDEMF+ Object Stack Index to use for this graphics container

EMF+ manual 2.3.7.1, Microsoft name: EmfPlusBeginContainer Record, Index 0x27

U_PSEUDO_OBJ* U_PMR_BEGINCONTAINER_set ( int  UTenum,
U_PSEUDO_OBJ DstRect,
U_PSEUDO_OBJ SrcRect,
uint32_t  StackID 
)

Create and set a U_PMR_BEGINCONTAINER PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
UTenumUnitType enumeration
DstRecta U_PSEUDO_OBJ containing a U_PMF_RECTF object. with SrcRect specifies a transformation
SrcRecta U_PSEUDO_OBJ containing a U_PMF_RECTF object. with DstRect specifies a transformation
StackIDEMF+ Object Stack Index to use for this graphics container

EMF+ manual 2.3.7.1, Microsoft name: EmfPlusBeginContainer Record, Index 0x27

int U_PMR_BEGINCONTAINERNOPARAMS_get ( const char *  contents,
U_PMF_CMN_HDR Header,
uint32_t *  StackID 
)

Get data from a U_PMR_BEGINCONTAINERNOPARAMS record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header
StackIDEMF+ Object Stack Index to use for this graphics container

EMF+ manual 2.3.7.2, Microsoft name: EmfPlusBeginContainerNoParams Record, Index 0x28

U_PSEUDO_OBJ* U_PMR_BEGINCONTAINERNOPARAMS_set ( int  StackID)

Create and set a U_PMR_BEGINCONTAINERNOPARAMS PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
StackIDEMF+ Object Stack Index to use for this graphics container

EMF+ manual 2.3.7.2, Microsoft name: EmfPlusBeginContainerNoParams Record, Index 0x28

int U_PMR_CLEAR_get ( const char *  contents,
U_PMF_CMN_HDR Header,
U_PMF_ARGB Color 
)

Get data from a U_PMR_CLEAR record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header (ignore flags)
ColorErase everything preceding, set background ARGB color.

EMF+ manual 2.3.4.1, Microsoft name: EmfPlusClear Record, Index 0x09

U_PSEUDO_OBJ* U_PMR_CLEAR_set ( const U_PSEUDO_OBJ Color)

Create and set a U_PMR_CLEAR PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
ColorU_PSEUDO_OBJ containing a U_PMF_ARGB object.

EMF+ manual 2.3.4.1, Microsoft name: EmfPlusClear Record, Index 0x09

Erase everything preceding, set background ARGB to Color.

int U_PMR_COMMENT_get ( const char *  contents,
U_PMF_CMN_HDR Header,
const char **  Data 
)

Get data from a U_PMR_COMMENT record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header (ignore flags)
DataPrivate data, may be anything

EMF+ manual 2.3.2.1, Microsoft name: EmfPlusComment Record, Index 0x03

U_PSEUDO_OBJ* U_PMR_COMMENT_set ( size_t  cbData,
const void *  Data 
)

Create and set a U_PMR_COMMENT PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
cbDataNumber of bytes in Data, must be a multiple of 4
DataPrivate data, may be anything. Stored in PseudoObject without adjusting byte order.

EMF+ manual 2.3.2.1, Microsoft name: EmfPlusComment Record, Index 0x03

int U_PMR_DRAWARC_get ( const char *  contents,
U_PMF_CMN_HDR Header,
uint32_t *  PenID,
int *  ctype,
U_FLOAT Start,
U_FLOAT Sweep,
U_PMF_RECTF Rect 
)

Get data from a U_PMR_DRAWARC record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header
PenIDU_PMF_PEN object in the EMF+ object table (0-63, inclusive)
ctypeSet: int16_t coordinates; Clear: U_FLOAT coordinates
StartStart angle, >=0.0, degrees clockwise from 3:00
SweepSweep angle, -360<= angle <=360, degrees clockwise from Start
RectCaller must free. Bounding rectangle. Coordinate type set by ctype.

EMF+ manual 2.3.4.2, Microsoft name: EmfPlusDrawArc Record, Index 0x12

U_PSEUDO_OBJ* U_PMR_DRAWARC_set ( uint32_t  PenID,
U_FLOAT  Start,
U_FLOAT  Sweep,
const U_PSEUDO_OBJ Rect 
)

Create and set a U_PMR_DRAWARC PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
PenIDU_PMF_PEN object in the EMF+ object table (0-63, inclusive)
StartStart angle, >=0.0, degrees clockwise from 3:00
SweepSweep angle, -360<= angle <=360, degrees clockwise from Start
RectU_PSEUDO_OBJ containing a U_PMF_RECT or U_PMF_RECTF object

EMF+ manual 2.3.4.2, Microsoft name: EmfPlusDrawArc Record, Index 0x12

int U_PMR_DRAWBEZIERS_get ( const char *  contents,
U_PMF_CMN_HDR Header,
uint32_t *  PenID,
int *  ctype,
int *  RelAbs,
uint32_t *  Elements,
U_PMF_POINTF **  Points 
)

Get data from a U_PMR_DRAWBEZIERS record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header
PenIDU_PMF_PEN object in the EMF+ object table (0-63, inclusive)
ctypeSet: int16_t coordinates; Clear: U_FLOAT coordinates
RelAbsSet: Coordinates are relative; Clear: Coordinates are absolute and their type is set by ctype
ElementsNumber of members in the Data array
PointsCaller must free. Array of U_POINT_F = Sequence of points to connect. Coordinate type set by ctype and RelAbs.

EMF+ manual 2.3.4.3, Microsoft name: EmfPlusDrawBeziers Record, Index 0x19

U_PSEUDO_OBJ* U_PMR_DRAWBEZIERS_set ( uint32_t  PenID,
const U_PSEUDO_OBJ Points 
)

Create and set a U_PMR_DRAWBEZIERS PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
PenIDU_PMF_PEN object in the EMF+ object table (0-63, inclusive)
PointsU_PSEUDO_OBJ containing first Elements, then a U_PMF_POINT, U_PMF_POINTR or U_PMF_POINTF object

EMF+ manual 2.3.4.3, Microsoft name: EmfPlusDrawBeziers Record, Index 0x19

int U_PMR_DRAWCLOSEDCURVE_get ( const char *  contents,
U_PMF_CMN_HDR Header,
uint32_t *  PenID,
int *  ctype,
int *  RelAbs,
U_FLOAT Tension,
uint32_t *  Elements,
U_PMF_POINTF **  Points 
)

Get data from a U_PMR_DRAWCLOSEDCURVE record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header
PenIDU_PMF_PEN object in the EMF+ object table (0-63, inclusive)
ctypeSet: int16_t coordinates; Clear: U_FLOAT coordinates
RelAbsSet: Coordinates are relative; Clear: Coordinates are absolute and their type is set by ctype
TensionControls splines, 0 is straight line, >0 is curved
ElementsNumber of members in the Data array
PointsCaller must free. Array of U_POINT_F = Sequence of points to connect. Coordinate type set by ctype and RelAbs.

EMF+ manual 2.3.4.4, Microsoft name: EmfPlusDrawClosedCurve Record, Index 0x17

U_PSEUDO_OBJ* U_PMR_DRAWCLOSEDCURVE_set ( uint32_t  PenID,
U_FLOAT  Tension,
const U_PSEUDO_OBJ Points 
)

Create and set a U_PMR_DRAWCLOSEDCURVE PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
PenIDU_PMF_PEN object in the EMF+ object table (0-63, inclusive)
TensionControls splines, 0 is straight line, >0 is curved
PointsU_PSEUDO_OBJ containing a U_PMF_POINT, U_PMF_POINTR or U_PMF_POINTF object

EMF+ manual 2.3.4.4, Microsoft name: EmfPlusDrawClosedCurve Record, Index 0x17

Curve is a cardinal spline.

References sent by MS support:

http://alvyray.com/Memos/CG/Pixar/spline77.pdf

http://msdn.microsoft.com/en-us/library/4cf6we5y(v=vs.110).aspx

int U_PMR_DRAWCURVE_get ( const char *  contents,
U_PMF_CMN_HDR Header,
uint32_t *  PenID,
int *  ctype,
U_FLOAT Tension,
uint32_t *  Offset,
uint32_t *  NSegs,
uint32_t *  Elements,
U_PMF_POINTF **  Points 
)

Get data from a U_PMR_DRAWCURVE record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header
PenIDU_PMF_PEN object in the EMF+ object table (0-63, inclusive)
ctypeSet: int16_t coordinates; Clear: U_FLOAT coordinates
TensionControls splines, 0 is straight line, >0 is curved
OffsetElement in Points that is the spline's starting point
NSegsNumber of segments
ElementsNumber of members in Data array
PointsCaller must free. Array of U_POINT_F = Sequence of points to connect. Coordinate type set by ctype and RelAbs.

EMF+ manual 2.3.4.5, Microsoft name: EmfPlusDrawCurve Record, Index 0x18

U_PSEUDO_OBJ* U_PMR_DRAWCURVE_set ( uint32_t  PenID,
U_FLOAT  Tension,
uint32_t  Offset,
uint32_t  NSegs,
const U_PSEUDO_OBJ Points 
)

Create and set a U_PMR_DRAWCURVE PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
PenIDU_PMF_PEN object in the EMF+ object table (0-63, inclusive)
TensionControls splines, 0 is straight line, >0 is curved
OffsetThe starting point in the list of points, 0 is first.
NSegsNumber of segments to draw. Starting at Offset go NSegs straight lines, must not run out of points..
PointsU_PSEUDO_OBJ containing an element count then a series of U_PMF_POINT or U_PMF_POINTF object

EMF+ manual 2.3.4.5, Microsoft name: EmfPlusDrawCurve Record, Index 0x18

Curve is a cardinal spline, using doubled terminator points to generate curves for the terminal segments.

References sent by MS support:

http://alvyray.com/Memos/CG/Pixar/spline77.pdf

http://msdn.microsoft.com/en-us/library/4cf6we5y(v=vs.110).aspx

int U_PMR_DRAWDRIVERSTRING_get ( const char *  contents,
U_PMF_CMN_HDR Header,
uint32_t *  FontID,
int *  btype,
U_FLOAT Tension,
uint32_t *  BrushID,
uint32_t *  DSOFlags,
uint32_t *  HasMatrix,
uint32_t *  Elements,
uint16_t **  Glyphs,
U_PMF_POINTF **  Points,
U_PMF_TRANSFORMMATRIX **  Matrix 
)

Get data from a U_PMR_DRAWDRIVERSTRING record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header
FontIDU_PMF_FONT object in the EMF+ object table (0-63, inclusive)
btypeSet: BrushID is an U_PFM_ARGB; Clear: index of U_PMF_BRUSH object in EMF+ object table.
TensionControls splines, 0 is straight line, >0 is curved
BrushIDColor or index of U_PMF_BRUSH object in the EMF+ object table, depends on Flags bit0
DSOFlagsDriverStringOptions flags
HasMatrixIf 1 record contains a TransformMatrix field, if 0 it does not.
ElementsNumber of members in Glyphs and Positions array
GlyphsCaller must free. If U_DSO_CmapLookup is set in DSOFlags this is an array of UTF16LE characters, otherwise, it is an array of indices into the U_PMF_FONT object indexed by Object_ID in flags.
PointsCaller must free. Coordinates of each member of Glyphs. U_DSO_RealizedAdvance set in DSOFlags Relative then positions are calculated relative to the first glyph which is stored in Positions, otherwise, all glyph positions are stored in Positions.
MatrixCaller must free. Transformation to apply to Glyphs & Positions. Present if HasMatrix is 1

EMF+ manual 2.3.4.6, Microsoft name: EmfPlusDrawDriverString Record, Index 0x36

U_PSEUDO_OBJ* U_PMR_DRAWDRIVERSTRING_set ( uint32_t  FontID,
U_FLOAT  Tension,
const U_PSEUDO_OBJ BrushID,
uint32_t  DSOFlags,
uint32_t  HasMatrix,
uint32_t  GlyphCount,
const uint16_t *  Glyphs,
const U_PSEUDO_OBJ Points,
const U_PSEUDO_OBJ Tm 
)

Create and set a U_PMR_DRAWDRIVERSTRING PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
FontIDU_PMF_FONT object in the EMF+ object table (0-63, inclusive)
TensionControls splines, 0 is straight line, >0 is curved
BrushIDU_PSEUDO_OBJ containing a U_PMF_ARGB or a U_PMF_4NUM. Color or U_PMF_BRUSH object in the EMF+ object table (0-63, inclusive)
DSOFlagsDriverStringOptions flags
HasMatrixIf 1 record contains a TransformMatrix field, if 0 it does not.
GlyphCountThe number of Elements in Glyphs, must agree with the number of elements in Points.
GlyphsIf U_DSO_CmapLookup is set in DSOFlags this is an array of UTF16LE characters, otherwise, it is an array of indices into the U_PMF_FONT object indexed by Object_ID in flags.
PointsU_PSEUDO_OBJ containing a U_PMF_POINTF object
TmU_PSEUDO_OBJ containing a U_PMF_TRANSFORMMATRIX object. Apply to Glyphs & Positions. Present if HasMatrix is 1

EMF+ manual 2.3.4.6, Microsoft name: EmfPlusDrawDriverString Record, Index 0x36

int U_PMR_DRAWELLIPSE_get ( const char *  contents,
U_PMF_CMN_HDR Header,
uint32_t *  PenID,
int *  ctype,
U_PMF_RECTF Rect 
)

Get data from a U_PMR_DRAWELLIPSE record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header
PenIDU_PMF_PEN object in the EMF+ object table (0-63, inclusive)
ctypeSet: int16_t coordinates; Clear: U_FLOAT coordinates
RectCaller must free. Bounding rectangle. Coordinate type set by ctype.

EMF+ manual 2.3.4.7, Microsoft name: EmfPlusDrawEllipse Record, Index 0x0F

U_PSEUDO_OBJ* U_PMR_DRAWELLIPSE_set ( uint32_t  PenID,
const U_PSEUDO_OBJ Rect 
)

Create and set a U_PMR_DRAWELLIPSE PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
PenIDU_PMF_PEN object in the EMF+ object table (0-63, inclusive)
RectU_PSEUDO_OBJ containing a U_PMF_RECT or U_PMF_RECTF object

EMF+ manual 2.3.4.7, Microsoft name: EmfPlusDrawEllipse Record, Index 0x0F

U_PSEUDO_OBJ* U_PMR_drawfill ( uint32_t  PathID,
uint32_t  PenID,
const U_PSEUDO_OBJ BrushID 
)

Create a U_PSEUDO_OBJ containing a U_PMR_FILLPATH and U_PMR_DRAWPATH records.

Returns
pointer to U_PSEUDO_OBJ or NULL on error.
Parameters
PathIDU_PMF_PATH object in the EMF+ object table (0-63, inclusive)
PenIDU_PMF_PEN object in the EMF+ object table (0-63, inclusive)
BrushIDU_PSEUDO_OBJ containing a U_PMF_ARGB or a U_PMF_4NUM. Color or U_PMF_BRUSH object in the EMF+ object table (0-63, inclusive)
int U_PMR_DRAWIMAGE_get ( const char *  contents,
U_PMF_CMN_HDR Header,
uint32_t *  ImgID,
int *  ctype,
uint32_t *  ImgAttrID,
int32_t *  SrcUnit,
U_PMF_RECTF SrcRect,
U_PMF_RECTF DstRect 
)

Get data from a U_PMR_DRAWIMAGE record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header
ImgIDU_PMF_IMAGE object in the EMF+ object table (0-63, inclusive)
ctypeSet: int16_t coordinates; Clear: U_FLOAT coordinates
ImgAttrIDindex of a U_PMF_IMAGEATTRIBUTES object in the object table
SrcUnitUnitType enumeration
SrcRectRegion of image
DstRectDestination rectangle for image. Coordinate type set by ctype.

EMF+ manual 2.3.4.8, Microsoft name: EmfPlusDrawImage Record, Index 0x1A

U_PSEUDO_OBJ* U_PMR_DRAWIMAGE_set ( uint32_t  ImgID,
int32_t  ImgAttrID,
int32_t  SrcUnit,
const U_PSEUDO_OBJ SrcRect,
const U_PSEUDO_OBJ DstRect 
)

Create and set a U_PMR_DRAWIMAGE PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
ImgIDU_PMF_IMAGE object in the EMF+ object table (0-63, inclusive)
ImgAttrIDindex of a U_PMF_IMAGEATTRIBUTES object in the object table
SrcUnitUnitType enumeration
SrcRectU_PSEUDO_OBJ containing a U_PMF_RECTF object, Source region of image
DstRectU_PSEUDO_OBJ containing a U_PMF_RECT or U_PMF_RECTF object

EMF+ manual 2.3.4.8, Microsoft name: EmfPlusDrawImage Record, Index 0x1A

int U_PMR_DRAWIMAGEPOINTS_get ( const char *  contents,
U_PMF_CMN_HDR Header,
uint32_t *  ImgID,
int *  ctype,
int *  etype,
int *  RelAbs,
uint32_t *  ImgAttrID,
int32_t *  SrcUnit,
U_PMF_RECTF SrcRect,
uint32_t *  Elements,
U_PMF_POINTF **  Points 
)

Get data from a U_PMR_DRAWIMAGEPOINTS record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header
ImgIDU_PMF_IMAGE object in the EMF+ object table (0-63, inclusive)
ctypeSet: int16_t coordinates; Clear: U_FLOAT coordinates
etypeSet: effect from previous U_PMR_SERIALIZABLEOBJECT record will be applied; Clear: no effect applied
RelAbsSet: Data is relative, Clear: if it is absolute
ImgAttrIDEmfPlusImageAttributes object
SrcUnitUnitType enumeration
SrcRectRegion of image
ElementsNumber of members in Points, must be 3
PointsCaller must free. 3 points of a parallelogram.. Coordinate type set by ctype and RelAbs.

EMF+ manual 2.3.4.9, Microsoft name: EmfPlusDrawImagePoints Record, Index 0x1B

U_PSEUDO_OBJ* U_PMR_DRAWIMAGEPOINTS_set ( uint32_t  ImgID,
int  etype,
int32_t  ImgAttrID,
int32_t  SrcUnit,
const U_PSEUDO_OBJ SrcRect,
const U_PSEUDO_OBJ Points 
)

Create and set a U_PMR_DRAWIMAGEPOINTS PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
ImgIDU_PMF_IMAGE object in the EMF+ object table (0-63, inclusive)
etypeSet: effect from previous U_PMR_SERIALIZABLEOBJECT record will be applied; Clear: no effect applied
ImgAttrIDindex of a U_PMF_IMAGEATTRIBUTES object in the object table
SrcUnitUnitType enumeration
SrcRectU_PSEUDO_OBJ containing a U_PMF_RECTF object, Source region of image
PointsU_PSEUDO_OBJ containing an array of 3 (U_PMF_POINT, U_PMF_POINTF, or U_PMF_POINTF) objects. These points are the UL, UR, and LL vertices of a parallelogram.

EMF+ manual 2.3.4.9, Microsoft name: EmfPlusDrawImagePoints Record, Index 0x1B

WARNING! Windows XP Preview does not show filter effects, whether or not U_PPF_E is set. They are visible if the EMF+ file is inserted as an image into PowerPoint.

int U_PMR_drawline ( uint32_t  PenID,
uint32_t  PathID,
U_PMF_POINTF  Start,
U_PMF_POINTF  End,
int  Dashed,
U_PSEUDO_OBJ sum,
EMFTRACK et 
)

Utility function to draw a line.

Returns
1 on success, 0 on error.
Parameters
PenIDIndex of U_PMF_PEN object to use in the EMF+ object table (0-63, inclusive)
PathIDIndex of U_PMF_PATH object to use in the EMF+ object table (0-63, inclusive)
StartU_PMF_POINTF coordinates of start of line.
EndU_PMF_POINTF coordinates of end of line.
DashedSet if the line is dashed, clear if it is not.
sumPseudoObject used for scratch space
etEMFTRACK used to write records to EMF file
int U_PMR_DRAWLINES_get ( const char *  contents,
U_PMF_CMN_HDR Header,
uint32_t *  PenID,
int *  ctype,
int *  dtype,
int *  RelAbs,
uint32_t *  Elements,
U_PMF_POINTF **  Points 
)

Get data from a U_PMR_DRAWLINES record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header
PenIDU_PMF_PEN object in the EMF+ object table (0-63, inclusive)
ctypeSet: int16_t coordinates; Clear: U_FLOAT coordinates
dtypeSet: path must be closed, Clear: path is open
RelAbsSet: Coordinates are relative; Clear: Coordinates are absolute and their type is set by ctype
ElementsNumber of members in Points
PointsCaller must free. Array of U_POINT_F = Sequence of points to connect. Coordinate type set by ctype and RelAbs.

EMF+ manual 2.3.4.10, Microsoft name: EmfPlusDrawLines Record, Index 0x0D

U_PSEUDO_OBJ* U_PMR_DRAWLINES_set ( uint32_t  PenID,
int  dtype,
const U_PSEUDO_OBJ Points 
)

Create and set a U_PMR_DRAWLINES PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
PenIDU_PMF_PEN object in the EMF+ object table (0-63, inclusive)
dtypeSet: path must be closed, Clear: path is open
PointsU_PSEUDO_OBJ containing an array of 3 U_PMF_POINT, U_PMF_POINTR, or U_PMF_POINTF objects

EMF+ manual 2.3.4.10, Microsoft name: EmfPlusDrawLines Record, Index 0x0D

int U_PMR_DRAWPATH_get ( const char *  contents,
U_PMF_CMN_HDR Header,
uint32_t *  PathID,
uint32_t *  PenID 
)

Get data from a U_PMR_DRAWPATH record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header
PathIDU_PMF_PATH object in the EMF+ object table (0-63, inclusive)
PenIDU_PMF_PEN object in the EMF+ object table (0-63, inclusive)

EMF+ manual 2.3.4.11, Microsoft name: EmfPlusDrawPath Record, Index 0x15

U_PSEUDO_OBJ* U_PMR_DRAWPATH_set ( uint32_t  PathID,
uint32_t  PenID 
)

Create and set a U_PMR_DRAWPATH PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
PathIDU_PMF_PATH object in the EMF+ object table (0-63, inclusive)
PenIDU_PMF_PEN object in the EMF+ object table (0-63, inclusive)

EMF+ manual 2.3.4.11, Microsoft name: EmfPlusDrawPath Record, Index 0x15

int U_PMR_DRAWPIE_get ( const char *  contents,
U_PMF_CMN_HDR Header,
uint32_t *  PenID,
int *  ctype,
U_FLOAT Start,
U_FLOAT Sweep,
U_PMF_RECTF Rect 
)

Get data from a U_PMR_DRAWPIE record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header
PenIDU_PMF_PEN object in the EMF+ object table (0-63, inclusive)
ctypeSet: int16_t coordinates; Clear: U_FLOAT coordinates
StartStart angle, >=0.0, degrees clockwise from 3:00
SweepSweep angle, -360<= angle <=360, degrees clockwise from Start
RectCaller must free. Bounding rectangle. Coordinate type set by ctype.

EMF+ manual 2.3.4.12, Microsoft name: EmfPlusDrawPie Record, Index 0x0D

U_PSEUDO_OBJ* U_PMR_DRAWPIE_set ( uint32_t  PenID,
U_FLOAT  Start,
U_FLOAT  Sweep,
const U_PSEUDO_OBJ Rect 
)

Create and set a U_PMR_DRAWPIE PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
PenIDU_PMF_PEN object in the EMF+ object table (0-63, inclusive)
StartStart angle, >=0.0, degrees clockwise from 3:00
SweepSweep angle, -360<= angle <=360, degrees clockwise from Start
RectU_PSEUDO_OBJ containing a U_PMF_RECT or U_PMF_RECTF object

EMF+ manual 2.3.4.12, Microsoft name: EmfPlusDrawPie Record, Index 0x0D

int U_PMR_DRAWRECTS_get ( const char *  contents,
U_PMF_CMN_HDR Header,
uint32_t *  PenID,
int *  ctype,
uint32_t *  Elements,
U_PMF_RECTF **  Rects 
)

Get data from a U_PMR_DRAWRECTS record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header
PenIDU_PMF_PEN object in the EMF+ object table (0-63, inclusive)
ctypeSet: int16_t coordinates; Clear: U_FLOAT coordinates
ElementsNumber of members in Rects
RectsCaller must free. Array of U_PMF_RECTF rectangles to draw.

EMF+ manual 2.3.4.13, Microsoft name: EmfPlusDrawRects Record, Index 0x0B

Rects in record may be either U_PMF_RECT or U_PMF_RECTF, but this function always returns U_PMF_RECTF

U_PSEUDO_OBJ* U_PMR_DRAWRECTS_set ( uint32_t  PenID,
const U_PSEUDO_OBJ Rects 
)

Create and set a U_PMR_DRAWRECTS PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
PenIDU_PMF_PEN object in the EMF+ object table (0-63, inclusive)
RectsU_PSEUDO_OBJ containing 1 rect OR a count N follwed by N rects. Rects may be either U_PMF_RECT or U_PMF_RECTF

EMF+ manual 2.3.4.13, Microsoft name: EmfPlusDrawRects Record, Index 0x0B

int U_PMR_drawstring ( const char *  string,
int  Vpos,
uint32_t  FontID,
const U_PSEUDO_OBJ BrushID,
uint32_t  FormatID,
U_PMF_STRINGFORMAT  Sfs,
const char *  FontName,
U_FLOAT  Height,
U_FontInfoParams fip,
uint32_t  FontFlags,
U_FLOAT  x,
U_FLOAT  y,
U_PSEUDO_OBJ sum,
EMFTRACK et 
)

Utility function for drawing strings onto the baseline in one call.

Returns
1 on success, 0 on error.
Parameters
stringText to draw in UTF-8 format
VposStringAlignment Enumeration. Always drawn on baseline, but using one of these three modes.
FontIDIndex of U_PMF_FONT object to use in the EMF+ object table (0-63, inclusive)
BrushIDU_PSEUDO_OBJ containing a U_PMF_ARGB or a U_PMF_4NUM. Color or U_PMF_BRUSH object in the EMF+ object table (0-63, inclusive)
FormatIDindex of U_PMF_STRINGFORMAT object to use in the EMF+ Object Table.
SfsStringFormat structure. Ignored values: StringAlignment, LineAlign, Flags
FontNameName of font to draw with
HeightHeight of font in pixels (positive)
fipU_FontInfoParams (ascent, descent, and so forth)
FontFlagsFontStyle Flags
xX position in pixels of left side of EM box of first character
yY position in pixels of baseline of first character
sumPseudoObject used for scratch space
etEMFTRACK used to write records to EMF file

EMF+ manual 2.3.4.14, Microsoft name: EmfPlusDrawString Record, Index 0x1C

For most fonts Ascent and Descent are used to adjust the bounding box to properly position the baseline. Some fonts, like Verdana, are strange and they position the baseline on the bottom of the bounding box if that box has the same height as the font. For those fonts specify 0.0 for both Ascent and Descent.

int U_PMR_DRAWSTRING_get ( const char *  contents,
U_PMF_CMN_HDR Header,
uint32_t *  FontID,
int *  btype,
uint32_t *  BrushID,
uint32_t *  FormatID,
uint32_t *  Elements,
U_PMF_RECTF Rect,
uint16_t **  String 
)

Get data from a U_PMR_DRAWSTRING record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header
FontIDU_PMF_FONT object in the EMF+ object table (0-63, inclusive)
btypeSet: BrushID is an U_PFM_ARGB; Clear: index of U_PMF_BRUSH object in EMF+ object table.
BrushIDColor or index of U_PMF_BRUSH object in the EMF+ object table, depending on btype.
FormatIDU_PMF_STRINGFORMAT object in EMF+ Object Table.
ElementsNumber of characters in the string.
RectString's bounding box.
StringCaller must free. Array of UFT-16LE unicode characters.

EMF+ manual 2.3.4.14, Microsoft name: EmfPlusDrawString Record, Index 0x1C

U_PSEUDO_OBJ* U_PMR_DRAWSTRING_set ( uint32_t  FontID,
const U_PSEUDO_OBJ BrushID,
uint32_t  FormatID,
uint32_t  Length,
const U_PSEUDO_OBJ Rect,
const uint16_t *  Text 
)

Create and set a U_PMR_DRAWSTRING PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
FontIDU_PMF_FONT object in the EMF+ object table (0-63, inclusive)
BrushIDU_PSEUDO_OBJ containing a U_PMF_ARGB or a U_PMF_4NUM. Color or U_PMF_BRUSH object in the EMF+ object table (0-63, inclusive)
FormatIDU_PMF_STRINGFORMAT object in EMF+ Object Table.
LengthNumber of characters in the string.
RectU_PSEUDO_OBJ containing a U_PMF_RECTF object, string's bounding box
TextArray of UFT-16LE unicode characters.

EMF+ manual 2.3.4.14, Microsoft name: EmfPlusDrawString Record, Index 0x1C

int U_PMR_ENDCONTAINER_get ( const char *  contents,
U_PMF_CMN_HDR Header,
uint32_t *  StackID 
)

Get data from a U_PMR_ENDCONTAINER record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header
StackIDEMF+ Object Stack Index of this graphics container

EMF+ manual 2.3.7.3, Microsoft name: EmfPlusEndContainer Record, Index 0x29

U_PSEUDO_OBJ* U_PMR_ENDCONTAINER_set ( int  StackID)

Create and set a U_PMR_ENDCONTAINER PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
StackIDEMF+ Object Stack Index to use for this graphics container

EMF+ manual 2.3.7.3, Microsoft name: EmfPlusEndContainer Record, Index 0x29

int U_PMR_ENDOFFILE_get ( const char *  contents,
U_PMF_CMN_HDR Header 
)

Get data from a U_PMR_ENDOFFILE record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header (ignore flags)

EMF+ manual 2.3.3.1, Microsoft name: EmfPlusEndOfFile Record, Index 0x02

U_PSEUDO_OBJ* U_PMR_ENDOFFILE_set ( void  )

Create and set a U_PMR_ENDOFFILE PseudoObject.

Returns
Pointer to PseudoObject, NULL on error

EMF+ manual 2.3.3.1, Microsoft name: EmfPlusEndOfFile Record, Index 0x02

int U_PMR_FILLCLOSEDCURVE_get ( const char *  contents,
U_PMF_CMN_HDR Header,
int *  btype,
int *  ctype,
int *  ftype,
int *  RelAbs,
uint32_t *  BrushID,
U_FLOAT Tension,
uint32_t *  Elements,
U_PMF_POINTF **  Points 
)

Get data from a U_PMR_FILLCLOSEDCURVE record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header
btypeSet: BrushID is an U_PFM_ARGB; Clear: is index of U_PMF_BRUSH object in EMF+ object table.
ctypeSet: int16_t coordinates; Clear: U_FLOAT coordinates
ftypeSet: winding fill; Clear: alternate fill
RelAbsSet: Coordinates are relative; Clear: Coordinates are absolute and their type is set by ctype
BrushIDColor or index of U_PMF_BRUSH object in the EMF+ object table, depending on btype.
TensionControls splines, 0 is straight line, >0 is curved
ElementsNumber of members in Points
PointsCaller must free. Array of U_POINT_F = Sequence of points to connect. Coordinate type set by ctype and RelAbs.

EMF+ manual 2.3.4.15, Microsoft name: EmfPlusFillClosedCurve Record, Index 0x16

U_PSEUDO_OBJ* U_PMR_FILLCLOSEDCURVE_set ( int  ftype,
U_FLOAT  Tension,
const U_PSEUDO_OBJ BrushID,
const U_PSEUDO_OBJ Points 
)

Create and set a U_PMR_FILLCLOSEDCURVE PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
ftypeIf U_WINDING use winding fill, else use fill
BrushIDU_PSEUDO_OBJ containing a U_PMF_ARGB or a U_PMF_4NUM. Color or U_PMF_BRUSH object in the EMF+ object table (0-63, inclusive)
TensionControls splines, 0 is straight line, >0 is curved
PointsU_PSEUDO_OBJ containing a U_PMF_POINT, U_PMF_POINTR or U_PMF_POINTF object

EMF+ manual 2.3.4.15, Microsoft name: EmfPlusFillClosedCurve Record, Index 0x16

int U_PMR_FILLELLIPSE_get ( const char *  contents,
U_PMF_CMN_HDR Header,
int *  btype,
int *  ctype,
uint32_t *  BrushID,
U_PMF_RECTF Rect 
)

Get data from a U_PMR_FILLELLIPSE record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header
btypeSet: BrushID is an U_PFM_ARGB; Clear: is index of U_PMF_BRUSH object in EMF+ object table.
ctypeSet: int16_t coordinates; Clear: U_FLOAT coordinates
BrushIDColor or index of U_PMF_BRUSH object in the EMF+ object table, depending on btype.
RectCaller must free. Bounding box for elliptical pie segment being drawn. Coordinate type set by ctype.

EMF+ manual 2.3.4.16, Microsoft name: EmfPlusFillEllipse Record, Index 0x0E

U_PSEUDO_OBJ* U_PMR_FILLELLIPSE_set ( const U_PSEUDO_OBJ BrushID,
const U_PSEUDO_OBJ Rect 
)

Create and set a U_PMR_FILLELLIPSE PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
BrushIDU_PSEUDO_OBJ containing a U_PMF_ARGB or a U_PMF_4NUM. Color or U_PMF_BRUSH object in the EMF+ object table (0-63, inclusive)
RectU_PSEUDO_OBJ containing a U_PMF_RECT or U_PMF_RECTF object

EMF+ manual 2.3.4.16, Microsoft name: EmfPlusFillEllipse Record, Index 0x0E

int U_PMR_FILLPATH_get ( const char *  contents,
U_PMF_CMN_HDR Header,
uint32_t *  PathID,
int *  btype,
uint32_t *  BrushID 
)

Get data from a U_PMR_FILLPATH record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header
btypeSet: BrushID is an U_PFM_ARGB; Clear: is index of U_PMF_BRUSH object in EMF+ object table.
PathIDU_PMF_PATH object in the EMF+ object table (0-63, inclusive)
BrushIDColor or index of U_PMF_BRUSH object in the EMF+ object table, depending on btype.

EMF+ manual 2.3.4.17, Microsoft name: EmfPlusFillPath Record, Index 0x14

Note: U_PMF_FILLPATHOBJ is the object, U_PMF_FILLPATH is the file record

U_PSEUDO_OBJ* U_PMR_FILLPATH_set ( uint32_t  PathID,
const U_PSEUDO_OBJ BrushID 
)

Create and set a U_PMR_FILLPATH PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
PathIDU_PMF_PATH object in the EMF+ object table (0-63, inclusive)
BrushIDU_PSEUDO_OBJ containing a U_PMF_ARGB or a U_PMF_4NUM. Color or U_PMF_BRUSH object in the EMF+ object table (0-63, inclusive)

EMF+ manual 2.3.4.17, Microsoft name: EmfPlusFillPath Record, Index 0x14

int U_PMR_FILLPIE_get ( const char *  contents,
U_PMF_CMN_HDR Header,
int *  btype,
int *  ctype,
uint32_t *  BrushID,
U_FLOAT Start,
U_FLOAT Sweep,
U_PMF_RECTF Rect 
)

Get data from a U_PMR_FILLPIE record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header
btypeSet: BrushID is an U_PFM_ARGB; Clear: is index of U_PMF_BRUSH object in EMF+ object table.
ctypeSet: int16_t coordinates; Clear: U_FLOAT coordinates
BrushIDColor or index of U_PMF_BRUSH object in the EMF+ object table, depending on btype.
StartStart angle, >=0.0, degrees clockwise from 3:00
SweepSweep angle, -360<= angle <=360, degrees clockwise from Start
RectBounding box for elliptical pie segment being filled. Coordinate type set by ctype.

EMF+ manual 2.3.4.18, Microsoft name: EmfPlusFillPie Record, Index 0x10

U_PSEUDO_OBJ* U_PMR_FILLPIE_set ( U_FLOAT  Start,
U_FLOAT  Sweep,
const U_PSEUDO_OBJ BrushID,
const U_PSEUDO_OBJ Rect 
)

Create and set a U_PMR_FILLPIE PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
StartStart angle, >=0.0, degrees clockwise from 3:00
SweepSweep angle, -360<= angle <=360, degrees clockwise from Start
BrushIDU_PSEUDO_OBJ containing a U_PMF_ARGB or a U_PMF_4NUM. Color or U_PMF_BRUSH object in the EMF+ object table (0-63, inclusive)
RectU_PSEUDO_OBJ containing a U_PMF_RECT or U_PMF_RECTF object

EMF+ manual 2.3.4.18, Microsoft name: EmfPlusFillPie Record, Index 0x10

int U_PMR_FILLPOLYGON_get ( const char *  contents,
U_PMF_CMN_HDR Header,
int *  btype,
int *  ctype,
int *  RelAbs,
uint32_t *  BrushID,
uint32_t *  Elements,
U_PMF_POINTF **  Points 
)

Get data from a U_PMR_FILLPOLYGON record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header
btypeSet: BrushID is an U_PFM_ARGB; Clear: is index of U_PMF_BRUSH object in EMF+ object table.
ctypeSet: int16_t coordinates; Clear: U_FLOAT coordinates
RelAbsSet: U_PMF_PathPointTypeRLE and/or U_PMF_PathPointType objects; Clear: only U_PMF_PathPointType
BrushIDColor or index of U_PMF_BRUSH object in the EMF+ object table, depending on btype.
ElementsNumber of members in Data.
PointsSequence of points to connect with line segments. Coordinate type set by ctype and RelAbs.

EMF+ manual 2.3.4.19, Microsoft name: EmfPlusFillPolygon Record, Index 0x0C

U_PSEUDO_OBJ* U_PMR_FILLPOLYGON_set ( const U_PSEUDO_OBJ BrushID,
const U_PSEUDO_OBJ Points 
)

Create and set a U_PMR_FILLPOLYGON PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
BrushIDU_PSEUDO_OBJ containing a U_PMF_ARGB or a U_PMF_4NUM. Color or U_PMF_BRUSH object in the EMF+ object table (0-63, inclusive)
PointsU_PSEUDO_OBJ containing an array of 3 U_PMF_POINT, U_PMF_POINTR, or U_PMF_POINTF objects

EMF+ manual 2.3.4.19, Microsoft name: EmfPlusFillPolygon Record, Index 0x0C

int U_PMR_FILLRECTS_get ( const char *  contents,
U_PMF_CMN_HDR Header,
int *  btype,
int *  ctype,
uint32_t *  BrushID,
uint32_t *  Elements,
U_PMF_RECTF **  Rects 
)

Get data from a U_PMR_FILLRECTS record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header
btypeSet: BrushID is an U_PFM_ARGB; Clear: is index of U_PMF_BRUSH object in EMF+ object table.
ctypeSet: int16_t coordinates; Clear: U_FLOAT coordinates
BrushIDColor or index of U_PMF_BRUSH object in the EMF+ object table, depending on btype.
ElementsNumber of members in Data.
RectsCaller must free. Array of U_PMF_RECTF rectangles to draw.

EMF+ manual 2.3.4.20, Microsoft name: EmfPlusFillRects Record, Index 0x0A

EMF+ files have been encountered where BrushID must be a color, because it has a value like FFFF0000 but the flags are set wrong, so that U_PPF_B is not set. Detect these by BrushID >63 for btype=0 and correct. If the opposite problem occurs it cannot be reliably detected, so it cannot be corrected.

Rects in record may be either U_PMF_RECT or U_PMF_RECTF, but this function always returns U_PMF_RECTF

U_PSEUDO_OBJ* U_PMR_FILLRECTS_set ( const U_PSEUDO_OBJ BrushID,
const U_PSEUDO_OBJ Rects 
)

Create and set a U_PMR_FILLRECTS PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
BrushIDU_PSEUDO_OBJ containing a U_PMF_ARGB or a U_PMF_4NUM. Color or U_PMF_BRUSH object in the EMF+ object table (0-63, inclusive)
RectsU_PSEUDO_OBJ containing 1 rect OR a count N followed by N rects. Rects may be either U_PMF_RECT or U_PMF_RECTF

EMF+ manual 2.3.4.20, Microsoft name: EmfPlusFillRects Record, Index 0x0A

int U_PMR_FILLREGION_get ( const char *  contents,
U_PMF_CMN_HDR Header,
uint32_t *  RgnID,
int *  btype,
int *  ctype,
uint32_t *  BrushID 
)

Get data from a U_PMR_FILLREGION record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header
RgnIDU_PMF_REGION object in the EMF+ object table (0-63, inclusive)
btypeSet: BrushID is an U_PFM_ARGB; Clear: is index of U_PMF_BRUSH object in EMF+ object table.
ctypeSet: int16_t coordinates; Clear: U_FLOAT coordinates
BrushIDColor or index of U_PMF_BRUSH object in the EMF+ object table, depending on btype.

EMF+ manual 2.3.4.21, Microsoft name: EmfPlusFillRegion Record, Index 0x13

U_PSEUDO_OBJ* U_PMR_FILLREGION_set ( uint32_t  RgnID,
const U_PSEUDO_OBJ BrushID 
)

Create and set a U_PMR_FILLREGION PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
RgnIDU_PMF_REGION object in the EMF+ object table (0-63, inclusive)
BrushIDU_PSEUDO_OBJ containing a U_PMF_ARGB or a U_PMF_4NUM. Color or U_PMF_BRUSH object in the EMF+ object table (0-63, inclusive)

EMF+ manual 2.3.4.21, Microsoft name: EmfPlusFillRegion Record, Index 0x13

int U_PMR_GETDC_get ( const char *  contents,
U_PMF_CMN_HDR Header 
)

Get data from a U_PMR_GETDC record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header (ignore flags)

EMF+ manual 2.3.3.2, Microsoft name: EmfPlusGetDC Record, Index 0x04

U_PSEUDO_OBJ* U_PMR_GETDC_set ( void  )

Create and set a U_PMR_GETDC PseudoObject.

Returns
Pointer to PseudoObject, NULL on error

EMF+ manual 2.3.3.2, Microsoft name: EmfPlusGetDC Record, Index 0x04

int U_PMR_HEADER_get ( const char *  contents,
U_PMF_CMN_HDR Header,
U_PMF_GRAPHICSVERSION Version,
int *  IsDual,
int *  IsVideo,
uint32_t *  LogicalDpiX,
uint32_t *  LogicalDpiY 
)

Get data from a U_PMR_HEADER record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header (ignore flags)
VersionEmfPlusGraphicsVersion object
IsDualset = Dual-mode file, clear= EMF+ only file.
IsVideoset = video device, clear= printer. Ignore all other bits.
LogicalDpiXHorizontal resolution reference device in DPI
LogicalDpiYVertical resolution reference device in DPI

EMF+ manual 2.3.3.3, Microsoft name: EmfPlusHeader Record, Index 0x01

U_PSEUDO_OBJ* U_PMR_HEADER_set ( int  IsDual,
int  IsVideo,
const U_PSEUDO_OBJ Version,
uint32_t  LogicalDpiX,
uint32_t  LogicalDpiY 
)

Create and set a U_PMR_HEADER PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
IsDualset = Dual-mode file, clear= EMF+ only file.
IsVideoset = video device, clear= printer. Ignore all other bits.
VersionU_PSEUDO_OBJ containing a U_PMF_GRAPHICSVERSION object
LogicalDpiXHorizontal resolution reference device in DPI
LogicalDpiYVertical resolution reference device in DPI

EMF+ manual 2.3.3.3, Microsoft name: EmfPlusHeader Record, Index 0x01

int U_PMR_MULTIFORMATEND_get ( const char *  contents,
U_PMF_CMN_HDR Header 
)

Get data from a U_PMR_MULTIFORMATEND record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header (ignore flags)

EMF+ manual mentioned in 2.1.1.1, reserved, not otherwise documented, Microsoft name: EmfPlusMultiFormatEnd Record, Index 0x06

int U_PMR_MULTIFORMATSECTION_get ( const char *  contents,
U_PMF_CMN_HDR Header 
)

Get data from a U_PMR_MULTIFORMATSECTION record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header (ignore flags)

EMF+ manual mentioned in 2.1.1.1, reserved, not otherwise documented, Microsoft name: EmfPlusMultiFormatSection Record, Index 0x06

int U_PMR_MULTIFORMATSTART_get ( const char *  contents,
U_PMF_CMN_HDR Header 
)

Get data from a U_PMR_MULTIFORMATSTART record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header (ignore flags)

EMF+ manual mentioned in 2.1.1.1, reserved, not otherwise documented, Microsoft name: EmfPlusMultiFormatStart Record, Index 0x05

int U_PMR_MULTIPLYWORLDTRANSFORM_get ( const char *  contents,
U_PMF_CMN_HDR Header,
int *  xmtype,
U_PMF_TRANSFORMMATRIX Matrix 
)

Get data from a U_PMR_MULTIPLYWORLDTRANSFORM record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header
xmtypeSet: Post multiply; Clear: Pre multiply
MatrixTransformation matrix

EMF+ manual 2.3.9.1, Microsoft name: EmfPlusMultiplyWorldTransform Record, Index 0x2C

U_PSEUDO_OBJ* U_PMR_MULTIPLYWORLDTRANSFORM_set ( int  xmtype,
U_PSEUDO_OBJ Tm 
)

Create and set a U_PMR_MULTIPLYWORLDTRANSFORM PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
xmtypeSet: Post multiply; Clear: Pre multiply
Tma U_PSEUDO_OBJ containing a U_PMF_TRANSFORMMATRIX. (Transformation matrix)

EMF+ manual 2.3.9.1, Microsoft name: EmfPlusMultiplyWorldTransform Record, Index 0x2C

char* U_pmr_names ( unsigned int  idx)

Look up the name of the EMR+ record by type. Returns U_EMR_INVALID if out of range.

Returns
name of the PMR record, "U_EMR_INVALID" if out of range.
Parameters
idxPMR record type WITHOUT the U_PMR_RECFLAG bit.
int U_PMR_OBJECT_get ( const char *  contents,
U_PMF_CMN_HDR Header,
uint32_t *  ObjID,
int *  otype,
int *  ntype,
uint32_t *  TSize,
const char **  Data 
)

Get data from a U_PMR_OBJECT record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header
ObjIDIndex for this object in the EMF+ object table (0-63, inclusive)
otypeObjectType enumeration
ntypeSet: object definition continue bit is set
TSizeIf ntype is set, holds the total number of data bytes split across multiple records. If ntype is clear, has no meaning.
DataObject's data. Type from otype.

EMF+ manual 2.3.5.1, Microsoft name: EmfPlusObject Record, Index 0x13

OTHER NOTES: All objects are to be stored in the same table and retrieved by index. Documentation indicates that this table contains only 64 slots, although the index field which references it can code for values 0-127. If a new object has the same index as an existing object the old one is deleted and the new one goes into its storage slot. The continuation bit (U_PPF_N) is documented as indicating that the object is continued into the next record. Examination of emf+ records in emf files produced by PowerPoint 2003 show that changing the ObjID also serves as a continued record terminator, and that it apparently overrides the value for the continue bit. That is, even though the preceding records said that it was continued, the change of ObjID terminates that preceding record without adding any more data to it. In one example the sequential emf+ records were: ObjID type size continue 0 5 65008 Y 0 5 65008 Y 0 5 63104 Y 1 8 24 N A DrawImagePoints record followed that referenced ObjID 0. Examination of the records with continue set showed that data in each was preceded by a uint32_t size value equivalent to the size of the data that had been split across multiple records, in this case 0x0002F254 = 193108. It is not clear at present if this size value will also be present at the end of a continued series that terminates by not using the continue bit, rather than changing the ObjID.

U_PSEUDO_OBJ* U_PMR_OBJECT_PO_set ( uint32_t  ObjID,
U_PSEUDO_OBJ Po 
)

Create and set a U_PMR_OBJECT PseudoObject from another PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
ObjIDIndex for this object in the EMF+ object table (0-63, inclusive)
PoU_PSEUDO_OBJ containing an object type that may be stored in the EMF+ object table
U_PSEUDO_OBJ* U_PMR_OBJECT_set ( uint32_t  ObjID,
int  otype,
int  ntype,
uint32_t  TSize,
size_t  cbData,
const char *  Data 
)

Create and set a U_PMR_OBJECT PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
ObjIDIndex for this object in the EMF+ object table (0-63, inclusive)
otypeObjectType enumeration for this Object
ntypeSet: object definition continues in next record; Clear: this is the sole object definition record
TSizeIf ntype is set the total number of data bytes split across multiple records. If ntype is clear, it is ignored.
cbDataObject's data size, in bytes.
DataObject's data. Type from otype.

EMF+ manual 2.3.5.1, Microsoft name: EmfPlusObject Record, Index 0x13

Normally this is only called by U_PMR_OBJECT_PO_set().

U_PMR_OBJECT records can only hold a maximum of 65020 bytes of data. If the object is larger than that then multiple U_PMR_OBJECT records are created, one after the other. If this happens each record has cbData following ph, and the ntype flag is set. If all of the data is less than 65020 then cbData is NOT entered following ph, and the ntype flag is clear.

Call initially in all cases with ntype clear and TSize = 0. If the record needs to be fragmented the function will call itself recursively to do so.

int U_PMR_OFFSETCLIP_get ( const char *  contents,
U_PMF_CMN_HDR Header,
U_FLOAT dX,
U_FLOAT dY 
)

Get data from a U_PMR_OFFSETCLIP record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header (ignore flags)
dXhorizontal translation offset to apply to clipping region
dYvertical translation offset to apply to clipping region

EMF+ manual 2.3.1.1, Microsoft name: EmfPlusOffsetClip Record, Index 0x35

U_PSEUDO_OBJ* U_PMR_OFFSETCLIP_set ( U_FLOAT  dX,
U_FLOAT  dY 
)

Create and set a U_PMR_OFFSETCLIP PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
dXhorizontal translation offset to apply to clipping region
dYvertical translation offset to apply to clipping region

EMF+ manual 2.3.1.1, Microsoft name: EmfPlusOffsetClip Record, Index 0x35

int U_PMR_RESETCLIP_get ( const char *  contents,
U_PMF_CMN_HDR Header 
)

Get data from a U_PMR_RESETCLIP record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header (ignore flags)

EMF+ manual 2.3.1.2, Microsoft name: EmfPlusResetClip Record, Index 0x31

U_PSEUDO_OBJ* U_PMR_RESETCLIP_set ( void  )

Create and set a U_PMR_RESETCLIP PseudoObject.

Returns
Pointer to PseudoObject, NULL on error

EMF+ manual 2.3.1.2, Microsoft name: EmfPlusResetClip Record, Index 0x31

int U_PMR_RESETWORLDTRANSFORM_get ( const char *  contents,
U_PMF_CMN_HDR Header 
)

Get data from a U_PMR_RESETWORLDTRANSFORM record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header

EMF+ manual 2.3.9.2, Microsoft name: EmfPlusResetWorldTransform Record, Index 0x2B

U_PSEUDO_OBJ* U_PMR_RESETWORLDTRANSFORM_set ( void  )

Create and set a U_PMR_RESETWORLDTRANSFORM PseudoObject.

Returns
Pointer to PseudoObject, NULL on error

EMF+ manual 2.3.9.2, Microsoft name: EmfPlusResetWorldTransform Record, Index 0x2B

int U_PMR_RESTORE_get ( const char *  contents,
U_PMF_CMN_HDR Header,
uint32_t *  StackID 
)

Get data from a U_PMR_RESTORE record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header
StackIDState (level) to restore from the EMF+ Graphics Stack. Must have been put on the GS with a U_PMR_SAVE.

EMF+ manual 2.3.7.4, Microsoft name: EmfPlusRestore Record, Index 0x26

U_PSEUDO_OBJ* U_PMR_RESTORE_set ( int  StackID)

Create and set a U_PMR_RESTORE PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
StackIDEMF+ Graphics State Stack to restore from. Must have been put on the GSS with a U_PMR_SAVE.

EMF+ manual 2.3.7.4, Microsoft name: EmfPlusRestore Record, Index 0x26

int U_PMR_ROTATEWORLDTRANSFORM_get ( const char *  contents,
U_PMF_CMN_HDR Header,
int *  xmtype,
U_FLOAT Angle 
)

Get data from a U_PMR_ROTATEWORLDTRANSFORM record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header
xmtypeSet: Post multiply; Clear: Pre multiply
AngleRotation angle, in degrees

EMF+ manual 2.3.9.3, Microsoft name: EmfPlusRotateWorldTransform Record, Index 0x2F

U_PSEUDO_OBJ* U_PMR_ROTATEWORLDTRANSFORM_set ( int  xmtype,
U_FLOAT  Angle 
)

Create and set a U_PMR_ROTATEWORLDTRANSFORM PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
xmtypeSet: Post multiply; Clear: Pre multiply
AngleRotation angle, in degrees

EMF+ manual 2.3.9.3, Microsoft name: EmfPlusRotateWorldTransform Record, Index 0x2F

int U_PMR_SAVE_get ( const char *  contents,
U_PMF_CMN_HDR Header,
uint32_t *  StackID 
)

Get data from a U_PMR_SAVE record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header
StackIDState (level) to save.on the EMF+ Graphics Stack

EMF+ manual 2.3.7.5, Microsoft name: EmfPlusSave Record, Index 0x25

U_PSEUDO_OBJ* U_PMR_SAVE_set ( int  StackID)

Create and set a U_PMR_SAVE PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
StackIDEMF+ Graphics State Stack to restore from. Must have been put on the GSS with a U_PMR_SAVE.

EMF+ manual 2.3.7.5, Microsoft name: EmfPlusSave Record, Index 0x25

int U_PMR_SCALEWORLDTRANSFORM_get ( const char *  contents,
U_PMF_CMN_HDR Header,
int *  xmtype,
U_FLOAT Sx,
U_FLOAT Sy 
)

Get data from a U_PMR_SCALEWORLDTRANSFORM record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header
xmtypeSet: Post multiply; Clear: Pre multiply.
SxX scale factor.
SyY scale factor.

EMF+ manual 2.3.9.4, Microsoft name: EmfPlusScaleWorldTransform Record, Index 0x2E

U_PSEUDO_OBJ* U_PMR_SCALEWORLDTRANSFORM_set ( int  xmtype,
U_FLOAT  X,
U_FLOAT  Y 
)

Create and set a U_PMR_SCALEWORLDTRANSFORM PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
xmtypeSet: Post multiply; Clear: Pre multiply
XScale in X
YScale in Y

EMF+ manual 2.3.9.4, Microsoft name: EmfPlusScaleWorldTransform Record, Index 0x2E

int U_PMR_SERIALIZABLEOBJECT_get ( const char *  contents,
U_PMF_CMN_HDR Header,
uint8_t *  GUID,
uint32_t *  Size,
const char **  Data 
)

Get data from a U_PMR_SERIALIZABLEOBJECT record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header
GUIDImageEffects identifier.
SizeBytes in Data.
Data"Serialized image effects parameter block". One of the ImageEffects objects.

EMF+ manual 2.3.5.2, Microsoft name: EmfPlusSerializableObject Record, Index 0x38

U_PSEUDO_OBJ* U_PMR_SERIALIZABLEOBJECT_set ( const U_PSEUDO_OBJ Siepb)

Create and set a U_PMR_SERIALIZABLEOBJECT PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
SiepbU_PSEUDO_OBJ containing a "Serialized image effects parameter block". One of the ImageEffects objects.

EMF+ manual 2.3.5.2, Microsoft name: EmfPlusSerializableObject Record, Index 0x38

This sets an ImageEffect in the renderer, which will be applied to the next EmfPlusDrawImagePoints record that is encountered. The image effect is "consumed" by that EmfPlusDrawImagePoints record, resetting the renderer to its original state.

WARNING! Windows XP Preview does not show filter effects, whether or not U_PPF_E is set. They are visible if the EMF+ file is inserted as an image into PowerPoint.

int U_PMR_SETANTIALIASMODE_get ( const char *  contents,
U_PMF_CMN_HDR Header,
int *  SMenum,
int *  aatype 
)

Get data from a U_PMR_SETANTIALIASMODE record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header
SMenumSmoothingMode enumeration
aatypeSet: anti-aliasing on; Clear: anti-aliasing off

EMF+ manual 2.3.6.1, Microsoft name: EmfPlusSetAntiAliasMode Record, Index 0x1E

U_PSEUDO_OBJ* U_PMR_SETANTIALIASMODE_set ( int  SMenum,
int  aatype 
)

Create and set a U_PMR_SETANTIALIASMODE PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
SMenumSmoothingMode enumeration
aatypeSet: anti-aliasing on; Clear: anti-aliasing off

EMF+ manual 2.3.6.1, Microsoft name: EmfPlusSetAntiAliasMode Record, Index 0x1E

int U_PMR_SETCLIPPATH_get ( const char *  contents,
U_PMF_CMN_HDR Header,
uint32_t *  PathID,
int *  CMenum 
)

Get data from a U_PMR_SETCLIPPATH record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header
CMenumCombineMode enumeration..
PathIDU_PMF_PATH object in the EMF+ object table (0-63, inclusive)

EMF+ manual 2.3.1.3, Microsoft name: EmfPlusSetClipPath Record, Index 0x33

U_PSEUDO_OBJ* U_PMR_SETCLIPPATH_set ( uint32_t  PathID,
uint32_t  CMenum 
)

Create and set a U_PMR_SETCLIPPATH PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
CMenumCombineMode enumeration..
PathIDU_PMF_PATH object in the EMF+ object table (0-63, inclusive)

EMF+ manual 2.3.1.3, Microsoft name: EmfPlusSetClipPath Record, Index 0x33

int U_PMR_SETCLIPRECT_get ( const char *  contents,
U_PMF_CMN_HDR Header,
int *  CMenum,
U_PMF_RECTF Rect 
)

Get data from a U_PMR_SETCLIPRECT record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header (ignore flags)
CMenumCombine mode enumeration.
RectRectangle used with CombineMode enumeration from Header.Flags

EMF+ manual 2.3.1.4, Microsoft name: EmfPlusSetClipRect Record, Index 0x32

U_PSEUDO_OBJ* U_PMR_SETCLIPRECT_set ( uint32_t  CMenum,
const U_PSEUDO_OBJ Rect 
)

Create and set a U_PMR_SETCLIPRECT PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
CMenumCombineMode enumeration..
RectU_PSEUDO_OBJ containing an U_PMF_RECTF object or an array of U_PMF_RECTF objects (the first is used)

EMF+ manual 2.3.1.4, Microsoft name: EmfPlusSetClipRect Record, Index 0x32

int U_PMR_SETCLIPREGION_get ( const char *  contents,
U_PMF_CMN_HDR Header,
uint32_t *  PathID,
int *  CMenum 
)

Get data from a U_PMR_SETCLIPREGION record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header
CMenumCombineMode enumeration..
PathIDU_PMF_PATH object in the EMF+ object table (0-63, inclusive)

EMF+ manual 2.3.1.5, Microsoft name: EmfPlusSetClipRegion Record, Index 0x34

U_PSEUDO_OBJ* U_PMR_SETCLIPREGION_set ( uint32_t  PathID,
uint32_t  CMenum 
)

Create and set a U_PMR_SETCLIPREGION PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
PathIDU_PMF_PATH object in the EMF+ object table (0-63, inclusive)
CMenumCombineMode enumeration..

EMF+ manual 2.3.1.5, Microsoft name: EmfPlusSetClipRegion Record, Index 0x34

int U_PMR_SETCOMPOSITINGMODE_get ( const char *  contents,
U_PMF_CMN_HDR Header,
int *  CMenum 
)

Get data from a U_PMR_SETCOMPOSITINGMODE record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header
CMenumCompositingMode enumeration

EMF+ manual 2.3.6.2, Microsoft name: EmfPlusSetCompositingMode Record, Index 0x23

U_PSEUDO_OBJ* U_PMR_SETCOMPOSITINGMODE_set ( int  CMenum)

Create and set a U_PMR_SETCOMPOSITINGMODE PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
CMenumCompositingMode enumeration

EMF+ manual 2.3.6.2, Microsoft name: EmfPlusSetCompositingMode Record, Index 0x23

int U_PMR_SETCOMPOSITINGQUALITY_get ( const char *  contents,
U_PMF_CMN_HDR Header,
int *  CQenum 
)

Get data from a U_PMR_SETCOMPOSITINGQUALITY record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header
CQenumCompositingQuality enumeration

EMF+ manual 2.3.6.3, Microsoft name: EmfPlusSetCompositingQuality Record, Index 0x24

U_PSEUDO_OBJ* U_PMR_SETCOMPOSITINGQUALITY_set ( int  CQenum)

Create and set a U_PMR_SETCOMPOSITINGQUALITY PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
CQenumCompositingQuality enumeration

EMF+ manual 2.3.6.3, Microsoft name: EmfPlusSetCompositingQuality Record, Index 0x24

int U_PMR_SETINTERPOLATIONMODE_get ( const char *  contents,
U_PMF_CMN_HDR Header,
int *  IMenum 
)

Get data from a U_PMR_SETINTERPOLATIONMODE record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header
IMenumInterpolationMode enumeration

EMF+ manual 2.3.6.4, Microsoft name: EmfPlusSetInterpolationMode Record, Index 0x21

U_PSEUDO_OBJ* U_PMR_SETINTERPOLATIONMODE_set ( int  IMenum)

Create and set a U_PMR_SETINTERPOLATIONMODE PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
IMenumInterpolationMode enumeration

EMF+ manual 2.3.6.4, Microsoft name: EmfPlusSetInterpolationMode Record, Index 0x21

int U_PMR_SETPAGETRANSFORM_get ( const char *  contents,
U_PMF_CMN_HDR Header,
int *  PUenum,
U_FLOAT Scale 
)

Get data from a U_PMR_SETPAGETRANSFORM record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header
PUenumPage Unit, UnitType enumeration
ScaleScale factor to convert page space to device space

EMF+ manual 2.3.9.5, Microsoft name: EmfPlusSetPageTransform Record, Index 0x30

U_PSEUDO_OBJ* U_PMR_SETPAGETRANSFORM_set ( int  PUenum,
U_FLOAT  Scale 
)

Create and set a U_PMR_SETPAGETRANSFORM PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
PUenumPage Unit, in UnitType enumeration
ScaleScale factor to convert page space to device space

EMF+ manual 2.3.9.5, Microsoft name: EmfPlusSetPageTransform Record, Index 0x30

Defines Page Space -> Device Space transformation

int U_PMR_SETPIXELOFFSETMODE_get ( const char *  contents,
U_PMF_CMN_HDR Header,
int *  POMenum 
)

Get data from a U_PMR_SETPIXELOFFSETMODE record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header
POMenumPixelOffsetMode enumeration.

EMF+ manual 2.3.6.5, Microsoft name: EmfPlusSetPixelOffsetMode Record, Index 0x22

U_PSEUDO_OBJ* U_PMR_SETPIXELOFFSETMODE_set ( int  POMenum)

Create and set a U_PMR_SETPIXELOFFSETMODE PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
POMenumPixelOffsetMode enumeration

EMF+ manual 2.3.6.5, Microsoft name: EmfPlusSetPixelOffsetMode Record, Index 0x22

int U_PMR_SETRENDERINGORIGIN_get ( const char *  contents,
U_PMF_CMN_HDR Header,
int32_t *  X,
int32_t *  Y 
)

Get data from a U_PMR_SETRENDERINGORIGIN record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header.
XX coordinate of rendering origin.
YY coordinate of rendering origin.

EMF+ manual 2.3.6.6, Microsoft name: EmfPlusSetRenderingOrigin Record, Index 0x1D

U_PSEUDO_OBJ* U_PMR_SETRENDERINGORIGIN_set ( int32_t  X,
int32_t  Y 
)

Create and set a U_PMR_SETRENDERINGORIGIN PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
XX coordinate of rendering origin.
YY coordinate of rendering origin.

EMF+ manual 2.3.6.6, Microsoft name: EmfPlusSetRenderingOrigin Record, Index 0x1D

int U_PMR_SETTEXTCONTRAST_get ( const char *  contents,
U_PMF_CMN_HDR Header,
int *  TGC 
)

Get data from a U_PMR_SETTEXTCONTRAST record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header.
TGCText Gamma correction value (x 1000).

EMF+ manual 2.3.6.7, Microsoft name: EmfPlusSetTextContrast Record, Index 0x20

U_PSEUDO_OBJ* U_PMR_SETTEXTCONTRAST_set ( int  TGC)

Create and set a U_PMR_SETTEXTCONTRAST PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
TGCText Gamma correction value (x 1000).

EMF+ manual 2.3.6.7, Microsoft name: EmfPlusSetTextContrast Record, Index 0x20

int U_PMR_SETTEXTRENDERINGHINT_get ( const char *  contents,
U_PMF_CMN_HDR Header,
int *  TRHenum 
)

Get data from a U_PMR_SETTEXTRENDERINGHINT record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header.
TRHenumTextRenderingHint enumeration

EMF+ manual 2.3.6.8, Microsoft name: EmfPlusSetTextRenderingHint Record, Index 0x1F

U_PSEUDO_OBJ* U_PMR_SETTEXTRENDERINGHINT_set ( int  TRHenum)

Create and set a U_PMR_SETTEXTRENDERINGHINT PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
TRHenumTextRenderingHint enumeration

EMF+ manual 2.3.6.8, Microsoft name: EmfPlusSetTextRenderingHint Record, Index 0x1F

int U_PMR_SETTSCLIP_get ( const char *  contents,
U_PMF_CMN_HDR Header,
int *  ctype,
uint32_t *  Elements,
U_PMF_RECTF **  Rects 
)

Get data from a U_PMR_SETTSCLIP record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header
ctypeSet: int16_t coordinates; Clear: U_FLOAT coordinates
ElementsNumber of members in Data.
RectsCaller must free. Array of rectangles to draw. Coordinate type set by ctype.

EMF+ manual 2.3.8.1, Microsoft name: EmfPlusSetTSClip Record, Index 0x3A

U_PSEUDO_OBJ* U_PMR_SETTSCLIP_set ( U_PSEUDO_OBJ Rects)

Create and set a U_PMR_SETTSCLIP PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
Rectsa U_PSEUDO_OBJ containing an array of U_PMF_RECT or U_PMF_RECTF objects.

EMF+ manual 2.3.8.1, Microsoft name: EmfPlusSetTSClip Record, Index 0x3A

int U_PMR_SETTSGRAPHICS_get ( const char *  contents,
U_PMF_CMN_HDR Header,
int *  vgatype,
int *  pptype,
uint8_t *  AntiAliasMode,
uint8_t *  TextRenderHint,
uint8_t *  CompositingMode,
uint8_t *  CompositingQuality,
int16_t *  RenderOriginX,
int16_t *  RenderOriginY,
uint16_t *  TextContrast,
uint8_t *  FilterType,
uint8_t *  PixelOffset,
U_PMF_TRANSFORMMATRIX WorldToDevice,
const char **  Data 
)

Get data from a U_PMR_SETTSGRAPHICS record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header
vgatypeSet: Palette is VGA basic colors; Clear: Palette is ???
pptypeSet: Palette is present; Clear: Palette is absent.
AntiAliasModeSmoothingMode enumeration
TextRenderHintTextRenderingHint enumeration
CompositingModeCompositingMode enumeration
CompositingQualityCompositingQuality enumeration
RenderOriginXOrigin X for halftoning and dithering
RenderOriginYOrigin Y for halftoning and dithering
TextContrastGamma correction, range 0 to 12
FilterTypeFilterType enumeraton
PixelOffsetPixelOffsetMode enumeration
WorldToDeviceworld to device transform
DataPalette (optional)

EMF+ manual 2.3.8.2, Microsoft name: EmfPlusSetTSGraphics Record, Index 0x39

U_PSEUDO_OBJ* U_PMR_SETTSGRAPHICS_set ( int  vgatype,
U_PMF_SETTSGRAPHICS Tsg,
U_PSEUDO_OBJ Palette 
)

Create and set a U_PMR_SETTSGRAPHICS PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
vgatypeSet: Palette is VGA basic colors; Clear: Palette is ???
TsgA U_PMF_SETTSGRAPHICS object
Palette(optional) a U_PSEUDO_OBJ containing a U_PMF_PALETTE object.

EMF+ manual 2.3.8.2, Microsoft name: EmfPlusSetTSGraphics Record, Index 0x39

int U_PMR_SETWORLDTRANSFORM_get ( const char *  contents,
U_PMF_CMN_HDR Header,
U_PMF_TRANSFORMMATRIX Matrix 
)

Get data from a U_PMR_SETWORLDTRANSFORM record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header
MatrixTransformation matrix

EMF+ manual 2.3.9.6, Microsoft name: EmfPlusSetWorldTransform Record, Index 0x2A

U_PSEUDO_OBJ* U_PMR_SETWORLDTRANSFORM_set ( U_PSEUDO_OBJ Tm)

Create and set a U_PMR_SETWORLDTRANSFORM PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
Tma U_PSEUDO_OBJ containing a U_PMF_TRANSFORMMATRIX. (Transformation matrix)

EMF+ manual 2.3.9.6, Microsoft name: EmfPlusSetWorldTransform Record, Index 0x2A

Defines World Space -> Page Space transformation

int U_PMR_STROKEFILLPATH_get ( const char *  contents,
U_PMF_CMN_HDR Header 
)

Get data from a U_PMR_STROKEFILLPATH record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header (ignore flags)

EMF+ manual mentioned in 2.1.1.1, not otherwise documented, Microsoft name: EmfPlusStrokeFillPath Record, Index 0x37

"This record closes any open figures in a path, strokes the outline of the path by using the current pen, and fills its interior by using the current brush."

U_PSEUDO_OBJ* U_PMR_STROKEFILLPATH_set ( void  )

Create and set a U_PMR_STROKEFILLPATH PseudoObject.

Returns
Pointer to PseudoObject, NULL on error

EMF+ manual mentioned in 2.1.1.1, not otherwise documented, Microsoft name: EmfPlusStrokeFillPath Record, Index 0x37

"This record closes any open figures in a path, strokes the outline of the path by using the current pen, and fills its interior by using the current brush."

int U_PMR_TRANSLATEWORLDTRANSFORM_get ( const char *  contents,
U_PMF_CMN_HDR Header,
int *  xmtype,
U_FLOAT Dx,
U_FLOAT Dy 
)

Get data from a U_PMR_TRANSLATEWORLDTRANSFORM record.

Returns
1 on success, 0 on error
Parameters
contentsRecord from which to extract data
HeaderCommon header
xmtypeSet: Post multiply; Clear: Pre multiply
DxX offset
DyY offset

EMF+ manual 2.3.9.7, Microsoft name: EmfPlusTranslateWorldTransform Record, Index 0x2D

U_PSEUDO_OBJ* U_PMR_TRANSLATEWORLDTRANSFORM_set ( int  xmtype,
U_FLOAT  Dx,
U_FLOAT  Dy 
)

Create and set a U_PMR_TRANSLATEWORLDTRANSFORM PseudoObject.

Returns
Pointer to PseudoObject, NULL on error
Parameters
xmtypeSet: Post multiply; Clear: Pre multiply
DxX offset
DyY offset

EMF+ manual 2.3.9.7, Microsoft name: EmfPlusTranslateWorldTransform Record, Index 0x2D

void U_PMR_write ( U_PSEUDO_OBJ po,
U_PSEUDO_OBJ sum,
EMFTRACK et 
)

Utility function for writing one or more EMF+ records in a PseudoObject to the EMF output file.

Parameters
poU_PSEUDO_OBJ to write
sumU_PSEUDO_OBJ to use for scratch space
etEMFTRACK used to write records to EMF file
U_PSEUDO_OBJ* U_PO_append ( U_PSEUDO_OBJ po,
const char *  Data,
size_t  Size 
)

Append data to a U_PSEUDO_OBJ object and return it.

Returns
pointer to the U_PSEUDO_OBJ object, NULL on error
Parameters
poPseudoObject to append to. Cannot be NULL.
DataData to copy into the PseudoObject's data. If NULL, space is allocated (if necessary) and cleared instead of filled.
SizeNumber of data bytes in Data
U_PSEUDO_OBJ* U_PO_create ( char *  Data,
size_t  Size,
size_t  Use,
uint32_t  Type 
)

Create and set an U_PSEUDO_OBJ.

Returns
pointer to the U_PSEUDO_OBJ, NULL on error
Parameters
DataData to copy into the PseudoObject's data. If NULL, space is allocated, but is cleared instead of filled.
SizeNumber of bytes to allocate for Data (may be >Use if padding is present)
UseNumber of data bytes in Data (whether or not Data is actually copied)
TypeType numbers are from manual section: 1.2.3.47 -> 0x01020347

If Data is NULL and Size is 0 an empty PseudoObject is created. One byte of storage is allocated for Data, Size is set to 1, and Used to 0.

If Data is NULL and Size is !0 a zero filled PseudoObject is created.

If Data is !Null and Size is !0 a data filled PseudoObject is created.

int U_PO_free ( U_PSEUDO_OBJ **  po)

Free an U_PSEUDO_OBJ structure. All associated memory is released.

Parameters
poAddress of a pointer to the U_PSEUDO_OBJ structure, Pointer is set to NULL.
Returns
1 on success, 0 on error.
U_PSEUDO_OBJ* U_PO_po_append ( U_PSEUDO_OBJ po,
U_PSEUDO_OBJ Src,
int  StripE 
)

Append data to a U_PSEUDO_OBJ object and return it.

Returns
pointer to the U_PSEUDO_OBJ object, NULL on error
Parameters
poPseudoObject to append to. May be NULL.
SrcPseudoObject to append.
StripESet: leading Elements in Src->Data is not copied, Clear: it is copied.