Loading and saving of the ImFusion image format.
|
|
| ImFusionImage () |
| | Constructor with filename to load or save.
|
| |
|
| ~ImFusionImage () override |
| | Deletes all auxiliary storage however not any loaded data.
|
| |
|
void | setCompressionOptions (int mode, int passes, int dx, int dy) |
| | Set options for image compression.
|
| |
| Data * | loadInstance (unsigned int type, unsigned int headerSize) override |
| | Create specialized instance for a given data type or return null if not supported.
|
| |
| unsigned int | saveType (const Data *data) override |
| | Return type for saving a given data instance or null if not supported.
|
| |
| bool | load (unsigned int type, Data *data, std::istream &file, Progress *p=0) override |
| | Load specified data type into given class instance from file, return true upon success.
|
| |
| bool | save (Data *data, std::ostream &file, Progress *p=0) override |
| | Save a data instance to file, return true if successful.
|
| |
| bool | startSaveAsync (SharedImageSet *is, std::ostream &file, Progress *p=0) |
| | Prepares the asynchronous saving of images.
|
| |
|
bool | addFrameAsync (TypedImage< unsigned char > *memImg, std::ostream &file) |
| | After calling startSaveAsync(), call this method to save an image. Blocking.
|
| |
| bool | closeAsync (SharedImageSet *is, std::ostream &file, bool saveTimestamps=false) |
| | After calling startSaveAsync() and addFrameAsync() for each image, finalize the operation with this method.
|
| |
| bool | loadFromAsyncFormat (SharedImageSet *is, std::istream &file, Progress *p=0) |
| | Reads a SharedImageSet that was saved with startSaveAsync/addFrameAsync/closeAsync.
|
| |
|
void | setCurrentFilePath (const std::string &path) |
| | Sets the path of the current IMF file being loaded/saved.
|
| |
|
const std::string & | currentFilePath () const |
| | Returns the path of the current IMF file being loaded/saved.
|
| |
|
virtual | ~ImFusionFilePlugin ()=default |
| | Destructor.
|
| |
| virtual std::unique_ptr< Properties > | customPropertiesToSave (Data *) |
| | Lets plugin save custom properties as part of the global file metadata.
|
| |
| virtual bool | loadCustomProperties (Data *, Properties *) |
| | Load custom properties as returned previously by customPropertiesToSave()
|
| |
| virtual void | applyFlipToEnsureConsistency (Data *) |
| | Is called after the image content had to be flipped to ensure a consistent coordinate system.
|
| |
| virtual bool | beginBlockRead (std::iostream &, unsigned long long) |
| | Initialize plugin with current file pointer.
|
| |
| virtual bool | endBlockRead () |
| | Indicate to plugin that it will lose read access to the file pointer after this call.
|
| |
| virtual void | setBlockType (unsigned int type) |
| | Set the type of current data block which is being loaded/saved.
|
| |
|
|
virtual bool | loadHeader (std::istream &file) |
| | Load the file header, return true upon success.
|
| |
|
virtual unsigned char | saveHeader (std::ostream &file, SharedImageSet *is, ImageCompression *c, int nf) |
| | Save the file header, return the data format.
|
| |
|
bool | loadFrame (std::istream &file, const ImageDescriptor &d, const mat4 &m, const double t, unsigned int blockType, SharedImageSet *is) |
| | Loads an image data frame, returns true if successful.
|
| |
|
ImageDescriptor | loadDescriptor (std::istream &file) |
| | Load an image descriptor.
|
| |
|
void | saveDescriptor (std::ostream &file, const ImageDescriptor &d, int reverseScaling=1) |
| | Save an image descriptor.
|
| |
|
mat4 | loadMatrix (std::istream &file) |
| | Load a transformation matrix.
|
| |
|
void | saveMatrix (std::ostream &file, const mat4 &m) |
| | Save a matrix.
|
| |
|
void | saveImage (std::ostream &file, const MemImage *img, unsigned char format) const |
| | Save a single image given compression format.
|
| |
|
template<typename T> |
| void | loadImage (std::istream &file, TypedImage< T > *img) const |
| | Template method to load a compressed image.
|
| |
|
template<typename T> |
| void | saveImage (std::ostream &file, const TypedImage< T > *img, unsigned char format) const |
| | Template method to actually save an image with compression.
|
| |
|
Data::Modality | computeModality (unsigned int blockType) const |
| | Assemble image modality from block type and data format.
|
| |
|
std::string | currentFileDirectory () const |
| | Returns the directory of the ImFusion file currently being loaded/saved.
|
| |