Artec 3D Scanning SDK  2.0
ImageIO.h
Go to the documentation of this file.
1 /********************************************************************
2 *
3 * Project Artec 3D Scanning SDK
4 *
5 * Purpose: Image I/O routines
6 *
7 * Copyright: Artec Group
8 *
9 ********************************************************************/
10 
11 #ifndef _IMAGEIO_H_
12 #define _IMAGEIO_H_
13 
15 #include <artec/sdk/base/Errors.h>
16 #include <artec/sdk/base/IImage.h>
17 
18 namespace artec { namespace sdk { namespace base { namespace io
19 {
20 
21 extern "C"
22 {
23 /** Load float-value image from file
24 */
26  loadImage32fFromFile(IImage** image, const wchar_t* path);
27 
28 /** Save float-value image to file
29 */
31  saveImage32fToFile(const wchar_t* path, const IImage* image);
32 
33 /** Load image from file having automatically detected its type based on its extension.
34 * @note currently BMP, JPG, PNG
35 */
37  loadImageFromFile(IImage** image, const wchar_t* path);
38 
39 /** Load image from data in the memory buffer having automatically detected its type based on its extension.
40 * @note currently BMP, JPG, PNG
41 * @param formatExt
42 * ".bmp" for BMP
43 * ".jpg" or ".jpeg" or ".jpe" for JPG
44 * ".png" for PNG
45 */
47  loadImageFromBlob(IImage** image, const IBlob* data, const wchar_t* formatExt);
48 
49 /** Save image to file having automatically detected its type based on its extension.
50 * @note currently BMP, JPG, PNG
51 */
53  saveImageToFile(const wchar_t* path, const IImage* image);
54 
55 /** Save image to memory buffer having automatically detected its type based on its extension.
56 * @note currently BMP, JPG, PNG
57 * @param $formatExt
58 * ".bmp" for BMP
59 * ".jpg" or ".jpeg" or ".jpe" for JPG
60 * ".png" for PNG
61 */
63  saveImageToBlob(IBlob** data, const IImage* image, const wchar_t* formatExt);
64 }
65 
66 } } } } // namespace artec::sdk::base::io
67 
68 #endif //_IMAGEIO_H_
ErrorCode ABASESDK_LINK_SPEC loadImageFromFile(IImage **image, const wchar_t *path)
Load image from file having automatically detected its type based on its extension.
ErrorCode ABASESDK_LINK_SPEC loadImageFromBlob(IImage **image, const IBlob *data, const wchar_t *formatExt)
Load image from data in the memory buffer having automatically detected its type based on its extensi...
ErrorCode ABASESDK_LINK_SPEC loadImage32fFromFile(IImage **image, const wchar_t *path)
Load float-value image from file.
ErrorCode ABASESDK_LINK_SPEC saveImage32fToFile(const wchar_t *path, const IImage *image)
Save float-value image to file.
ErrorCode ABASESDK_LINK_SPEC saveImageToFile(const wchar_t *path, const IImage *image)
Save image to file having automatically detected its type based on its extension. ...
#define ABASESDK_LINK_SPEC
ErrorCode ABASESDK_LINK_SPEC saveImageToBlob(IBlob **data, const IImage *image, const wchar_t *formatExt)
Save image to memory buffer having automatically detected its type based on its extension.