47 #ifndef _MIRA_PNGCODEC_H_ 48 #define _MIRA_PNGCODEC_H_ 53 namespace mira {
namespace codec {
66 (
"Description",
"Lossless PNG image compression")
67 (
"Category" ,
"Image"))
75 PngCodec(
int compression = 3) : mCompression(compression) {}
80 r.
property(
"Compression", mCompression,
81 "Compression (0: lowest but fastest, 9: best but slowest)",
85 template <
typename Reflector>
86 void reflect(Reflector &r)
88 r.property(
"Compression", mCompression,
89 "Compression (0: lowest but fastest, 9: best but slowest)",
virtual Buffer< uint8 > encodeBuffer(TypedVoidConstPtr objectPtr)
Implementation of BinarySerializerCodec.
#define MIRA_REFLECT_BASE(reflector, BaseClass)
PNG Codec class that can be used together with a BinarySerializer to encode images as PNG...
Definition: PngCodec.h:61
virtual TypeId getSupportedTypeId() const
Implementation of BinarySerializerCodec.
virtual void decodeBuffer(const Buffer< uint8 > &data, TypedVoidPtr ioObjectPtr)
Implementation of BinarySerializerCodec.
void property(const char *name, T &member, const char *comment, PropertyHint &&hint=PropertyHint(), ReflectCtrlFlags flags=REFLECT_CTRLFLAG_NONE)