diff options
author | Colin Basnett <cmbasnett@gmail.com> | 2022-06-02 12:33:16 +0300 |
---|---|---|
committer | Colin Basnett <cmbasnett@gmail.com> | 2022-06-02 12:33:16 +0300 |
commit | a9077cefd4482fb84093fc447f06ccbd2b0ec842 (patch) | |
tree | fc53c70343dc98c188850f99c8b9d36fc1af2f70 /source/blender/windowmanager/WM_types.h | |
parent | 40ecf9d606358d773bfe977e6bc85580e5818cc6 (diff) |
Initial commit for imformat branch
Diffstat (limited to 'source/blender/windowmanager/WM_types.h')
-rw-r--r-- | source/blender/windowmanager/WM_types.h | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/source/blender/windowmanager/WM_types.h b/source/blender/windowmanager/WM_types.h index 9e9f195c430..163b1fc6c06 100644 --- a/source/blender/windowmanager/WM_types.h +++ b/source/blender/windowmanager/WM_types.h @@ -1278,6 +1278,28 @@ extern struct CLG_LogRef *WM_LOG_TOOLS; extern struct CLG_LogRef *WM_LOG_MSGBUS_PUB; extern struct CLG_LogRef *WM_LOG_MSGBUS_SUB; +/* imageformat stuff (move elsewhere) */ +typedef struct imfImageFormatType { + const char *name; + const char *idname; + const char *extensions; + const char *translation_context; + const char *description; + + /* Returns if a */ + bool (*is_a_bytes)( + struct imfImageFormatType *, + const char *buf); // TODO: have a filepointer instead (how does python handle this?) + struct Image *(*load)(struct imfImageFormatType *, const char *buf); + int (*save)(struct imfImageFormatType *, struct ImBuf *, const char *path); + + /** rna for properties */ + struct StructRNA *srna; + + /** RNA integration */ + ExtensionRNA rna_ext; +} imfImageFormatType; + #ifdef __cplusplus } #endif |