summaryrefslogtreecommitdiff
path: root/include/vcl
diff options
context:
space:
mode:
Diffstat (limited to 'include/vcl')
-rw-r--r--include/vcl/gfxlink.hxx5
-rw-r--r--include/vcl/graphicfilter.hxx6
-rw-r--r--include/vcl/salctype.hxx3
3 files changed, 11 insertions, 3 deletions
diff --git a/include/vcl/gfxlink.hxx b/include/vcl/gfxlink.hxx
index ad4caebc7b86..30228f339cd7 100644
--- a/include/vcl/gfxlink.hxx
+++ b/include/vcl/gfxlink.hxx
@@ -47,12 +47,13 @@ enum class GfxLinkType
NativeSvg = 9,
NativeMov = 10,
NativeBmp = 11,
- NativePdf = 12, // If a new type is added, make sure to change NativeLast too
+ NativePdf = 12,
+ NativeWebp = 13, // If a new type is added, make sure to change NativeLast too
// Alias for when the first native type starts and last native
// type ends.
NativeFirst = NativeGif,
- NativeLast = NativePdf,
+ NativeLast = NativeWebp,
};
class Graphic;
diff --git a/include/vcl/graphicfilter.hxx b/include/vcl/graphicfilter.hxx
index b1eba2b141ed..2d2f071e7d71 100644
--- a/include/vcl/graphicfilter.hxx
+++ b/include/vcl/graphicfilter.hxx
@@ -89,6 +89,7 @@ namespace o3tl
#define IMP_PCD "SVPCD"
#define IMP_PBM "SVPBM"
#define IMP_DXF "SVDXF"
+#define IMP_WEBP "SVIWEBP"
#define EXP_BMP "SVBMP"
#define EXP_SVMETAFILE "SVMETAFILE"
@@ -101,6 +102,7 @@ namespace o3tl
#define EXP_TIFF "SVTIFF"
#define EXP_EPS "SVEEPS"
#define EXP_GIF "SVEGIF"
+#define EXP_WEBP "SVEWEBP"
inline constexpr OUStringLiteral BMP_SHORTNAME = u"BMP";
@@ -115,6 +117,7 @@ inline constexpr OUStringLiteral WMF_SHORTNAME = u"WMF";
inline constexpr OUStringLiteral EMF_SHORTNAME = u"EMF";
inline constexpr OUStringLiteral SVG_SHORTNAME = u"SVG";
inline constexpr OUStringLiteral PDF_SHORTNAME = u"PDF";
+inline constexpr OUStringLiteral WEBP_SHORTNAME = u"WEBP";
// Info class for all supported file formats
@@ -137,6 +140,7 @@ enum class GraphicFileFormat
TGA = 0x000e,
PSD = 0x000f,
EPS = 0x0010,
+ WEBP = 0x0011,
DXF = 0x00f1,
MET = 0x00f2,
PCT = 0x00f3,
@@ -184,6 +188,7 @@ class VCL_DLLPUBLIC GraphicDescriptor final
bool ImpDetectTGA( SvStream& rStm, bool bExtendedInfo );
bool ImpDetectPSD( SvStream& rStm, bool bExtendedInfo );
bool ImpDetectEPS( SvStream& rStm, bool bExtendedInfo );
+ bool ImpDetectWEBP( SvStream& rStm, bool bExtendedInfo );
bool ImpDetectDXF( SvStream& rStm, bool bExtendedInfo );
bool ImpDetectMET( SvStream& rStm, bool bExtendedInfo );
bool ImpDetectPCT( SvStream& rStm, bool bExtendedInfo );
@@ -374,6 +379,7 @@ public:
static ErrCode readPCD(SvStream & rStream, Graphic & rGraphic);
static ErrCode readPBM(SvStream & rStream, Graphic & rGraphic);
static ErrCode readDXF(SvStream & rStream, Graphic & rGraphic);
+ static ErrCode readWEBP(SvStream & rStream, Graphic & rGraphic, GfxLinkType & rLinkType);
private:
OUString aFilterPath;
diff --git a/include/vcl/salctype.hxx b/include/vcl/salctype.hxx
index 409fc5a79993..71f256b1986e 100644
--- a/include/vcl/salctype.hxx
+++ b/include/vcl/salctype.hxx
@@ -37,7 +37,8 @@ enum class ConvertDataFormat
TIF,
WMF,
EMF,
- SVG
+ SVG,
+ WEBP
};
class SvStream;