class
ImageFileImporterRead image data stored in various file formats.
Contents
- Reference
This importer will look at the file extension and determine which image importer should be used to read the file.
- .jpg, .jpeg, .png, .bmp, .gif -> ImageImporter
- .dcm (or no extension) -> DICOMFileImporter
- .mhd -> MetaImageImporter
Output ports
0: Image
Base classes
- class FileImporter
- Abstract base class for importers which import a file with a filename.
Public functions
- auto create(std::string filename, bool grayscale) -> std::shared_ptr<ImageFileImporter>
- Create an instance.
- void setGrayscale(bool grayscale)
- Convert images to grayscale if the source image is in color.
- void loadAttributes() override
Private functions
- void execute() override
Function documentation
std::shared_ptr<ImageFileImporter> fast:: ImageFileImporter:: create(std::string filename,
bool grayscale)
Create an instance.
Parameters | |
---|---|
filename | Path to image file to load |
grayscale | Convert images to grayscale if the source image is in color |
Returns | instance |
void fast:: ImageFileImporter:: setGrayscale(bool grayscale)
Convert images to grayscale if the source image is in color.
Parameters | |
---|---|
grayscale | Convert or not |