Changeset View
Changeset View
Standalone View
Standalone View
source/blender/imbuf/intern/colormanagement.c
| Context not available. | |||||
| static void colormanage_load_config(OCIO_ConstConfigRcPtr *config) | static void colormanage_load_config(OCIO_ConstConfigRcPtr *config) | ||||
| { | { | ||||
| int tot_colorspace, tot_display, tot_display_view, tot_looks; | int tot_colorspace, tot_display, tot_display_view, tot_looks; | ||||
| int index, viewindex, viewindex2; | int index, viewindex; | ||||
| const char *name; | const char *name; | ||||
| /* get roles */ | /* get roles */ | ||||
| Context not available. | |||||
| } | } | ||||
| /* load displays */ | /* load displays */ | ||||
| viewindex2 = 0; | |||||
| tot_display = OCIO_configGetNumDisplays(config); | tot_display = OCIO_configGetNumDisplays(config); | ||||
| for (index = 0; index < tot_display; index++) { | for (index = 0; index < tot_display; index++) { | ||||
| Context not available. | |||||
| /* load views */ | /* load views */ | ||||
| tot_display_view = OCIO_configGetNumViews(config, displayname); | tot_display_view = OCIO_configGetNumViews(config, displayname); | ||||
| for (viewindex = 0; viewindex < tot_display_view; viewindex++, viewindex2++) { | for (viewindex = 0; viewindex < tot_display_view; viewindex++) { | ||||
| const char *viewname; | const char *viewname; | ||||
| ColorManagedView *view; | ColorManagedView *view; | ||||
| LinkData *display_view; | LinkData *display_view; | ||||
| Context not available. | |||||
| /* load looks */ | /* load looks */ | ||||
| tot_looks = OCIO_configGetNumLooks(config); | tot_looks = OCIO_configGetNumLooks(config); | ||||
| colormanage_look_add("None", "", true); | |||||
| for (index = 0; index < tot_looks; index++) { | for (index = 0; index < tot_looks; index++) { | ||||
| OCIO_ConstLookRcPtr *ocio_look; | const char *lookname; | ||||
| const char *process_space; | ColorManagedLook *look; | ||||
| /* Fits nice in menu, between high and low contrast. */ | |||||
Gvgeo: Hit a wall here.
There is already an empty function
```
OCIO_ConstLookRcPtr *FallbackImpl… | |||||
| if (index == 3) { | |||||
brechtUnsubmitted Not Done Inline ActionsThis only really makes sense for the builtin OCIO config, not the other ones. Even then I'm not sure it's needed. brecht: This only really makes sense for the builtin OCIO config, not the other ones. Even then I'm not… | |||||
| colormanage_look_add("None (Medium Contrast)", "", true); | |||||
| } | |||||
| else { | |||||
| OCIO_ConstLookRcPtr *ocio_look; | |||||
| const char *process_space; | |||||
| name = OCIO_configGetLookNameByIndex(config, index); | name = OCIO_configGetLookNameByIndex(config, index); | ||||
| ocio_look = OCIO_configGetLook(config, name); | ocio_look = OCIO_configGetLook(config, name); | ||||
| process_space = OCIO_lookGetProcessSpace(ocio_look); | process_space = OCIO_lookGetProcessSpace(ocio_look); | ||||
| OCIO_lookRelease(ocio_look); | OCIO_lookRelease(ocio_look); | ||||
| colormanage_look_add(name, process_space, false); | colormanage_look_add(name, process_space, false); | ||||
| } | |||||
| } | } | ||||
| /* Load luminance coefficients. */ | /* Load luminance coefficients. */ | ||||
| Context not available. | |||||
Hit a wall here.
There is already an empty function
OCIO_ConstLookRcPtr *FallbackImpl::configGetLook(OCIO_ConstConfigRcPtr * /*config*/, const char * /*name*/) { return NULL; }but returns an empty struct (only an unused int inside).
Unlike the View Transform options.
const char *FallbackImpl::configGetView ( OCIO_ConstConfigRcPtr * /*config*/, const char * /*display*/, int index)) { if (index == 0) { return "Standard"; } return NULL; }Not sure what the best option is, opted for a simple solution