OpenColorIO icon indicating copy to clipboard operation
OpenColorIO copied to clipboard

displayCache removes displays not in active_displays

Open rodbogart opened this issue 11 years ago • 0 comments

Previously, it was reasonable to have displays which were not in the active list. However, in 1.0.9, the displayCache culls the list of displays, even when writing out a config.

So, given this config: ocio_profile_version: 1

search_path: luts strictparsing: true luma: [0.2126, 0.7152, 0.0722]

description: Check for active displays bug

displays: AAA: - !<View> {name: Film, colorspace: lnf} BBB: - !<View> {name: Film, colorspace: lnf} CCC: - !<View> {name: Film, colorspace: lnf}

active_displays: [AAA, BBB] active_views: [Film]

colorspaces:

  • !<ColorSpace> name: lnf family: "" equalitygroup: "" bitdepth: 32f description: | Linear colorspace

    isdata: false allocation: lg2 allocationvars: [-15, 6]

We can then run this python script to try to read it and write it. The result is that the getNumDisplays call only finds two displays, when there are three. The expectation would be for all three to be written to the new output config. config = OCIO.GetCurrentConfig()

print(config.getNumDisplays())

fileHandle = open( "bugout.ocio", mode='w' ) fileHandle.write( config.serialize() ) fileHandle.close()

The resulting config looks like this: ocio_profile_version: 1

search_path: luts strictparsing: true luma: [0.2126, 0.7152, 0.0722]

description: Check for active displays bug

roles: {}

displays: AAA: - !<View> {name: Film, colorspace: lnf} BBB: - !<View> {name: Film, colorspace: lnf}

active_displays: [AAA, BBB] active_views: [Film]

colorspaces:

  • !<ColorSpace> name: lnf family: "" equalitygroup: "" bitdepth: 32f description: | Linear colorspace

    isdata: false allocation: lg2 allocationvars: [-15, 6]

rodbogart avatar Apr 30 '14 17:04 rodbogart