HDK
|
#include <IMG_FormatPassThru.h>
Public Member Functions | |
IMG_FormatPassThru (const IMG_File *parent_file) | |
const char * | getFormatName () const override |
const char * | getFormatLabel () const override |
const char * | getFormatDescription () const override |
const char * | getDefaultExtension () const override |
const char * | getFormatLocation () const override |
Describes how the format was loaded (i.e. DSO or internal formats) More... | |
int | checkExtension (const char *filename) const override |
int | checkMagic (unsigned int magic) const override |
int | checkMagicSeekable (UT_IStream &is) const override |
bool | isPassThrough () const override |
int | checkDevice (const char *filename) const override |
IMG_DataType | getSupportedTypes () const override |
Returns a bitfield of data types supported by this format. More... | |
IMG_ColorModel | getSupportedColorModels () const override |
void | getMaxResolution (unsigned &x, unsigned &y) const override |
int | isReadRandomAccess () const override |
int | isWriteRandomAccess () const override |
int | isTopFirst () const override |
int | isLeftFirst () const override |
bool | isDataWindowSupported () const override |
does this format support a data window or sub-area. More... | |
bool | isDataWindowStreakSupported () const override |
bool | isDeepRasterSupported () const override |
bool | isDataInterleaved () const override |
bool | canPlaneTypesDiffer () const override |
const IMG_FileOptionList * | getOptions () const override |
const IMG_MetadataOptions & | formatMetadata () const override |
Returns list of well known metadata for the format. More... | |
PXL_ColorSpace | formatColorSpace () const override |
fpreal | formatColorSpaceGamma () const override |
bool | formatStoresColorSpace () const override |
Return true if the image format can store the colorspace. More... | |
Public Member Functions inherited from IMG_Format | |
IMG_Format () | |
IMG_Format (bool addtolist) | |
virtual | ~IMG_Format () |
IMG_File * | allocValidFile () const |
virtual IMG_ImageType | getSupportedImageTypes () const |
virtual const IMG_Format * | resolvePriority (const IMG_Format *format) const |
virtual const char * | getMetadataKey () const |
fpreal | adjustGammaForFormat (PXL_ColorSpace src_color_space, fpreal src_color_space_gamma, bool src_data_is_8bit, bool *dest_data_is_8bit=NULL) const |
fpreal | adjustGammaForFormat (PXL_ColorSpace *src_color_space, fpreal src_color_space_gamma, bool src_data_is_8bit, bool *dest_data_is_8bit) const |
virtual bool | isReadable () const |
virtual bool | isWritable () const |
virtual bool | isDataWindowCropOnly () const |
virtual IMG_DeepRasterColor | getDeepRasterRGBASupport () const |
Protected Member Functions | |
IMG_File * | createFile () const override |
int | isFormatOk (const IMG_Stat &) const override |
const IMG_Format * | getParent () const |
Protected Member Functions inherited from IMG_Format | |
void | removeFormatFromList () |
const IMG_Metadata * | getGlobalTags () |
Protected Attributes | |
const IMG_File * | myParent |
Additional Inherited Members | |
Public Types inherited from IMG_Format | |
enum | AccessType { READ_ACCESS, WRITE_ACCESS } |
Static Public Member Functions inherited from IMG_Format | |
static const IMG_Format * | findFormatByName (const char *format_name) |
static const IMG_Format * | findFormatByLabel (const char *format_label) |
static const IMG_Format * | findFormatSeekable (UT_IStream &is) |
static const IMG_Format * | findFormatNonSeekable (UT_IStream &is) |
static const IMG_Format * | findFormatByExtension (const char *filename) |
static const IMG_Format * | getStdoutFormat () |
static const IMG_Format * | metadataPrefix (const char *key) |
static void | setGlobalOption (const char *name, const char *value) |
Set an option globally for all formats. Use with extreme care. More... | |
static void | getGlobalOption (const char *name, UT_String &value) |
Read the value of a global option. May return a NULL string. More... | |
static bool | setFormatOptionDefault (const char *format_name, const char *format_option, const char *defvalue) |
static bool | getFormatOptionDefault (const char *format_name, const char *format_option, UT_String &defvalue) |
static int | matchExtension (const char *filename, const char *ext) |
Matches a filename against a single extension. More... | |
static int | matchExtensions (const char *filename, const char *ext[]) |
static int | getNFormats () |
static const IMG_Format * | getFormat (int idx) |
Access to the list of currently installed image formats. More... | |
static const IMG_Format * | findFormatReadable (const char *filename, const IMG_Stat *stat=0) |
static const IMG_Format * | findFormatWritable (const char *filename, const IMG_Stat *stat=0) |
static void | findFormatReadable (UT_Array< const IMG_Format * > &formats, const char *filename, const IMG_Stat *stat=nullptr, const UT_Array< const IMG_Format * > *image_formats=nullptr) |
static void | findFormatWritable (UT_Array< const IMG_Format * > &formats, const char *filename, const IMG_Stat *stat=nullptr, const UT_Array< const IMG_Format * > *image_formats=nullptr) |
static UT_StringHolder | artistDefault () |
static UT_StringHolder | hostnameDefault () |
Static Protected Member Functions inherited from IMG_Format | |
static const IMG_Format * | findFormat (const char *filename, const IMG_Stat *stat, AccessType access) |
static void | findFormat (UT_Array< const IMG_Format * > &list, const char *filename, const IMG_Stat *stat, AccessType access, const UT_Array< const IMG_Format * > *image_formats=nullptr) |
Definition at line 20 of file IMG_FormatPassThru.h.
|
inline |
Definition at line 27 of file IMG_FormatPassThru.h.
|
inlineoverridevirtual |
if true, planes can have different data formats & components. Otherwise, all planes must have the same data type and number of components.
Reimplemented from IMG_Format.
Definition at line 84 of file IMG_FormatPassThru.h.
|
inlineoverridevirtual |
The device method gives a higher priority to device checks. By default, this method returns 0 (no match). This is used to allow things like a60:3.pic (which uses the abekas device).
Reimplemented from IMG_Format.
Definition at line 52 of file IMG_FormatPassThru.h.
|
inlineoverridevirtual |
Methods to determine if this is one of our recognized files. The extension is the first try. If there are multiple matches, then we resort to the magic number (when reading)
Implements IMG_Format.
Definition at line 43 of file IMG_FormatPassThru.h.
If possible, this magic numver checker will be called. This is used if the file is "seekable" (i.e. that we can rewind after checking)
Reimplemented from IMG_Format.
Definition at line 45 of file IMG_FormatPassThru.h.
|
inlineoverridevirtual |
If possible, this second magic number checker will be called. This is used if the file is "seekable" (i.e. that we can rewind after checking)
Reimplemented from IMG_Format.
Definition at line 47 of file IMG_FormatPassThru.h.
|
inlineoverrideprotectedvirtual |
Implements IMG_Format.
Definition at line 101 of file IMG_FormatPassThru.h.
|
inlineoverridevirtual |
Some image formats have fixed color spaces, like JPEG (sRGB). The default is PXL_CS_UNKNOWN. For formats that can have colorspaces per plane, return PXL_CS_UNKNOWN and query the colorspace from IMG_Plane. formatColorSpaceGamma() is ignored unless the color space is PXL_CS_CUSTOM_GAMMA.
Reimplemented from IMG_Format.
Definition at line 92 of file IMG_FormatPassThru.h.
|
inlineoverridevirtual |
Some image formats have fixed color spaces, like JPEG (sRGB). The default is PXL_CS_UNKNOWN. For formats that can have colorspaces per plane, return PXL_CS_UNKNOWN and query the colorspace from IMG_Plane. formatColorSpaceGamma() is ignored unless the color space is PXL_CS_CUSTOM_GAMMA.
Reimplemented from IMG_Format.
Definition at line 94 of file IMG_FormatPassThru.h.
|
inlineoverridevirtual |
Returns list of well known metadata for the format.
Reimplemented from IMG_Format.
Definition at line 89 of file IMG_FormatPassThru.h.
|
inlineoverridevirtual |
Return true if the image format can store the colorspace.
Reimplemented from IMG_Format.
Definition at line 96 of file IMG_FormatPassThru.h.
|
inlineoverridevirtual |
The default extension is used to determine whether the format should appear in the device/format menus. It should not contain the '.' (i.e. "tif" not ".tif")
Reimplemented from IMG_Format.
Definition at line 38 of file IMG_FormatPassThru.h.
|
inlineoverridevirtual |
This can be optionally overridden to return a short description of the format. By default, no description is given.
Reimplemented from IMG_Format.
Definition at line 36 of file IMG_FormatPassThru.h.
|
inlineoverridevirtual |
If getFormatLabel() is not overridden, the label will be the same as the name.
Reimplemented from IMG_Format.
Definition at line 34 of file IMG_FormatPassThru.h.
|
inlineoverridevirtual |
Describes how the format was loaded (i.e. DSO or internal formats)
Reimplemented from IMG_Format.
Definition at line 40 of file IMG_FormatPassThru.h.
|
inlineoverridevirtual |
All formats must have a unique name (like "JPEG").
Implements IMG_Format.
Definition at line 32 of file IMG_FormatPassThru.h.
|
inlineoverridevirtual |
Maximum allowable resolution for the file. If a user attempts to write an image larger than this, the image will be scaled to this resolution.
Implements IMG_Format.
Definition at line 59 of file IMG_FormatPassThru.h.
|
inlineoverridevirtual |
Returns a list of options that can be set on the format when reading or writing (like 'compression' or 'comment').
Reimplemented from IMG_Format.
Definition at line 87 of file IMG_FormatPassThru.h.
|
inlineprotected |
Definition at line 106 of file IMG_FormatPassThru.h.
|
inlineoverridevirtual |
Returns a bitfield of supported color models. If IMG_CM_REVERSED is set, this format stores data in BGR/ABGR format.
Implements IMG_Format.
Definition at line 57 of file IMG_FormatPassThru.h.
|
inlineoverridevirtual |
Returns a bitfield of data types supported by this format.
Implements IMG_Format.
Definition at line 55 of file IMG_FormatPassThru.h.
|
inlineoverridevirtual |
Specifies whether this format stores its data interleaved (RGBRGBRGB) or non-interleaved (RRRGGGBBB). If your format supports both, pick one.
Reimplemented from IMG_Format.
Definition at line 81 of file IMG_FormatPassThru.h.
|
inlineoverridevirtual |
does this format support saving whether the data outside the window is streaked from the window edges?
Reimplemented from IMG_Format.
Definition at line 75 of file IMG_FormatPassThru.h.
|
inlineoverridevirtual |
does this format support a data window or sub-area.
Reimplemented from IMG_Format.
Definition at line 73 of file IMG_FormatPassThru.h.
|
inlineoverridevirtual |
does this format support deep rasters or multiple images? If not, only one plane of the color models that this format supports is allowed.
Reimplemented from IMG_Format.
Definition at line 78 of file IMG_FormatPassThru.h.
Reimplemented from IMG_Format.
Definition at line 103 of file IMG_FormatPassThru.h.
|
inlineoverridevirtual |
horizontal data orientation. Where (0,0) lies in the image (top-left by default).
Reimplemented from IMG_Format.
Definition at line 70 of file IMG_FormatPassThru.h.
|
inlineoverridevirtual |
Flags whether the format is a pass through format like Flip or Scale. Specific image formats (like JPEG) are never pass-through.
Reimplemented from IMG_Format.
Definition at line 50 of file IMG_FormatPassThru.h.
|
inlineoverridevirtual |
Some formats can be read and written in random order. Others require strict sequential order. If these methods return false, you should read and write scanlines in ascending order. When writing, they will be cached until they can be written sequentially.
Reimplemented from IMG_Format.
Definition at line 64 of file IMG_FormatPassThru.h.
|
inlineoverridevirtual |
vertical data orientation. Where (0,0) lies in the image (top-left by default).
Reimplemented from IMG_Format.
Definition at line 68 of file IMG_FormatPassThru.h.
|
inlineoverridevirtual |
If 0 is returned, the scanlines must be written in sequential order or they will be cached until all scanlines can be written sequentially.
Reimplemented from IMG_Format.
Definition at line 66 of file IMG_FormatPassThru.h.
|
protected |
Definition at line 109 of file IMG_FormatPassThru.h.