Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorColin Basnett <cmbasnett@gmail.com>2022-06-02 12:33:16 +0300
committerColin Basnett <cmbasnett@gmail.com>2022-06-02 12:33:16 +0300
commita9077cefd4482fb84093fc447f06ccbd2b0ec842 (patch)
treefc53c70343dc98c188850f99c8b9d36fc1af2f70 /source/blender/windowmanager/WM_types.h
parent40ecf9d606358d773bfe977e6bc85580e5818cc6 (diff)
Initial commit for imformat branch
Diffstat (limited to 'source/blender/windowmanager/WM_types.h')
-rw-r--r--source/blender/windowmanager/WM_types.h22
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