Date
1 - 3 of 3
no function in (Python) API to get colorspace of defined role?
Abraham Schneider <abraham....@...>
Just had a look in the Python API and wondered how I could get the referenced colorspace of a named role. Some of the roles are predfined as constants (OCIO.Constants.ROLE_...), but what's with user defined roles? So for example the compositing_linear one in the ACES config, or a self defined one? Shouldn't there be just an easy function like 'getRole(rolename)' that just gives back the name of the colorspace that the role is linking to!? Really confused at the moment on how to use roles via API. Thanks! |
|
Sean Cooper <se...@...>
Not at a computer to verify, but I believe you can just do a getColorspace() call using the user defined or default roles, the query the name of the returned object. Role names are equivalent to color space names. Its a bit obtuse I must admit. On Mon, 28 May 2018, 3:21 pm Abraham Schneider, <abraham....@...> wrote:
|
|
Abraham Schneider <abraham....@...>
Seems to work, thanks. Not quite obvious from the documentation, especially if you only look at the API docs and not the user guide first. Am Montag, 28. Mai 2018 16:39:02 UTC+2 schrieb Sean Cooper:
|
|