78bool OleRenderWmf(
const std::vector<uint8_t>& aWmf,
int aMaxWidth,
int aMaxHeight, wxImage& aImage,
79 double aTargetAspect = 0.0 );
83 wxImage& aImage,
double aTargetAspect = 0.0,
84 bool* aUsedEmbeddedEmf =
nullptr );
86bool OleRenderEmf(
const std::vector<uint8_t>& aEmf,
int aMaxWidth,
int aMaxHeight, wxImage& aImage,
87 double aTargetAspect = 0.0 );
90 double aTargetAspect );
bool OleRenderWmf(const std::vector< uint8_t > &aWmf, int aMaxWidth, int aMaxHeight, wxImage &aImage, double aTargetAspect=0.0)
std::vector< uint8_t > OleExtractCiImage(const std::vector< uint8_t > &aPayload)
The CI marker follows the preview DIB; the raster has a counted decimal length.
VECTOR2I OleWmfRenderSize(int aNaturalWidth, int aNaturalHeight, int aMaxWidth, int aMaxHeight, double aTargetAspect)
OLE_IMAGE_PAYLOAD ExtractOleImageFromPayload(const std::vector< uint8_t > &aPayload)
Read the picture out of an OLE object payload that carries the 26-byte prologue.
bool OleRenderEmf(const std::vector< uint8_t > &aEmf, int aMaxWidth, int aMaxHeight, wxImage &aImage, double aTargetAspect=0.0)
std::vector< uint8_t > OleExtractEmbeddedEmf(const std::vector< uint8_t > &aWmf)
Reassemble an EMF carried by WMF META_ESCAPE_ENHANCED_METAFILE records.
bool OleMakeBmpFromDib(const std::vector< uint8_t > &aDib, wxMemoryBuffer &aOut)
wxString OleDescribeImagePayload(const std::vector< uint8_t > &aPayload)
Include leading bytes when the payload format is unknown.
OLE_IMAGE_PAYLOAD ExtractOleImage(const uint8_t *aCfb, size_t aSize)
Prefer CONTENTS, then OlePres000, then the native stream.
bool OleRenderMetafilePreview(const std::vector< uint8_t > &aWmf, int aMaxWidth, int aMaxHeight, wxImage &aImage, double aTargetAspect=0.0, bool *aUsedEmbeddedEmf=nullptr)
Render a metafile preview, preferring an EMF the WMF carries over the WMF itself.
std::optional< std::pair< size_t, size_t > > OleEmbeddedCompoundFile(const std::vector< uint8_t > &aPayload)
The 26-byte prologue stores length at offset 22 and length plus 22 at offset 0.
std::vector< uint8_t > data
VECTOR2< int32_t > VECTOR2I