diff options
author | Campbell Barton <ideasman42@gmail.com> | 2020-11-09 09:03:28 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2020-11-09 09:03:28 +0300 |
commit | af4c389f9955c5975058733858017da68792f509 (patch) | |
tree | 2b2f4751ad632ca7aeb292ae7065a1f1ea9475d4 /source | |
parent | e118426e4695a97d67e65d69677f3c4e2db50a56 (diff) |
Cleanup: imbuf callback naming
Use `is_a` & `is_a_filepath` in callback names.
Diffstat (limited to 'source')
-rw-r--r-- | source/blender/imbuf/intern/IMB_filetype.h | 4 | ||||
-rw-r--r-- | source/blender/imbuf/intern/cineon/cineon_dpx.c | 8 | ||||
-rw-r--r-- | source/blender/imbuf/intern/filetype.c | 6 | ||||
-rw-r--r-- | source/blender/imbuf/intern/oiio/openimageio_api.cpp | 4 | ||||
-rw-r--r-- | source/blender/imbuf/intern/oiio/openimageio_api.h | 2 |
5 files changed, 12 insertions, 12 deletions
diff --git a/source/blender/imbuf/intern/IMB_filetype.h b/source/blender/imbuf/intern/IMB_filetype.h index 93a3a98c3d1..53d9a1a2919 100644 --- a/source/blender/imbuf/intern/IMB_filetype.h +++ b/source/blender/imbuf/intern/IMB_filetype.h @@ -119,7 +119,7 @@ struct ImBuf *imb_bmp_decode(const unsigned char *mem, int imb_savebmp(struct ImBuf *ibuf, const char *filepath, int flags); /* cineon */ -int imb_is_cineon(const unsigned char *buf); +int imb_is_a_cineon(const unsigned char *buf); int imb_save_cineon(struct ImBuf *buf, const char *filepath, int flags); struct ImBuf *imb_load_cineon(const unsigned char *mem, size_t size, @@ -127,7 +127,7 @@ struct ImBuf *imb_load_cineon(const unsigned char *mem, char colorspace[IM_MAX_SPACE]); /* dpx */ -int imb_is_dpx(const unsigned char *buf); +int imb_is_a_dpx(const unsigned char *buf); int imb_save_dpx(struct ImBuf *buf, const char *filepath, int flags); struct ImBuf *imb_load_dpx(const unsigned char *mem, size_t size, diff --git a/source/blender/imbuf/intern/cineon/cineon_dpx.c b/source/blender/imbuf/intern/cineon/cineon_dpx.c index eeccadf56c1..98082a97e0f 100644 --- a/source/blender/imbuf/intern/cineon/cineon_dpx.c +++ b/source/blender/imbuf/intern/cineon/cineon_dpx.c @@ -188,7 +188,7 @@ int imb_save_cineon(struct ImBuf *buf, const char *filepath, int flags) return imb_save_dpx_cineon(buf, filepath, 1, flags); } -int imb_is_cineon(const unsigned char *buf) +int imb_is_a_cineon(const unsigned char *buf) { return logImageIsCineon(buf); } @@ -198,7 +198,7 @@ ImBuf *imb_load_cineon(const unsigned char *mem, int flags, char colorspace[IM_MAX_SPACE]) { - if (imb_is_cineon(mem)) { + if (imb_is_a_cineon(mem)) { return imb_load_dpx_cineon(mem, size, 1, flags, colorspace); } return NULL; @@ -209,7 +209,7 @@ int imb_save_dpx(struct ImBuf *buf, const char *filepath, int flags) return imb_save_dpx_cineon(buf, filepath, 0, flags); } -int imb_is_dpx(const unsigned char *buf) +int imb_is_a_dpx(const unsigned char *buf) { return logImageIsDpx(buf); } @@ -219,7 +219,7 @@ ImBuf *imb_load_dpx(const unsigned char *mem, int flags, char colorspace[IM_MAX_SPACE]) { - if (imb_is_dpx(mem)) { + if (imb_is_a_dpx(mem)) { return imb_load_dpx_cineon(mem, size, 0, flags, colorspace); } return NULL; diff --git a/source/blender/imbuf/intern/filetype.c b/source/blender/imbuf/intern/filetype.c index 5aa588da36d..667027ebfeb 100644 --- a/source/blender/imbuf/intern/filetype.c +++ b/source/blender/imbuf/intern/filetype.c @@ -114,7 +114,7 @@ const ImFileType IMB_FILE_TYPES[] = { #ifdef WITH_CINEON {NULL, NULL, - imb_is_dpx, + imb_is_a_dpx, NULL, imb_ftype_default, imb_load_dpx, @@ -126,7 +126,7 @@ const ImFileType IMB_FILE_TYPES[] = { COLOR_ROLE_DEFAULT_FLOAT}, {NULL, NULL, - imb_is_cineon, + imb_is_a_cineon, NULL, imb_ftype_default, imb_load_cineon, @@ -211,7 +211,7 @@ const ImFileType IMB_FILE_TYPES[] = { {NULL, NULL, NULL, - imb_is_a_photoshop, + imb_is_a_filepath_photoshop, imb_ftype_default, NULL, imb_load_photoshop, diff --git a/source/blender/imbuf/intern/oiio/openimageio_api.cpp b/source/blender/imbuf/intern/oiio/openimageio_api.cpp index d62258fbd2f..9d8c5d50a89 100644 --- a/source/blender/imbuf/intern/oiio/openimageio_api.cpp +++ b/source/blender/imbuf/intern/oiio/openimageio_api.cpp @@ -163,7 +163,7 @@ static ImBuf *imb_oiio_load_image_float( extern "C" { -int imb_is_a_photoshop(const char *filename) +int imb_is_a_filepath_photoshop(const char *filename) { const char *photoshop_extension[] = { ".psd", @@ -198,7 +198,7 @@ struct ImBuf *imb_load_photoshop(const char *filename, int flags, char colorspac const bool is_colorspace_manually_set = (colorspace[0] != '\0'); /* load image from file through OIIO */ - if (imb_is_a_photoshop(filename) == 0) { + if (imb_is_a_filepath_photoshop(filename) == 0) { return nullptr; } diff --git a/source/blender/imbuf/intern/oiio/openimageio_api.h b/source/blender/imbuf/intern/oiio/openimageio_api.h index 3f5f234099c..135e3521f71 100644 --- a/source/blender/imbuf/intern/oiio/openimageio_api.h +++ b/source/blender/imbuf/intern/oiio/openimageio_api.h @@ -31,7 +31,7 @@ extern "C" { struct ImBuf; -int imb_is_a_photoshop(const char *name); +int imb_is_a_filepath_photoshop(const char *name); int imb_save_photoshop(struct ImBuf *ibuf, const char *name, int flags); |