diff --git a/openpype/plugins/publish/extract_colorspace_data.py b/openpype/plugins/publish/extract_colorspace_data.py index e38474914c..d569a43637 100644 --- a/openpype/plugins/publish/extract_colorspace_data.py +++ b/openpype/plugins/publish/extract_colorspace_data.py @@ -20,14 +20,15 @@ class ExtractColorspaceData(publish.Extractor): representation[data] = { "colorspaceData": { "colorspace": "linear", - "configPath": "/path/to/config.ocio" + "configPath": "{project[root]}/path/to/config.ocio" + "configPathFormated": "/abs/path/to/config.ocio" } } TODO: - - rootify config path so it can be single path for usecases - where windows submit to farm and farm on linux do - oiio conversions. + - Keep templated config path and format it just before the use with anatomy data and envs. + - also check if colorspaceData are already added from host exctractors + - colorspace data has to be added before Exctract review for OIIO conversion """ label = "Extract Colorspace data" order = pyblish.api.ExtractorOrder + 0.49 @@ -55,18 +56,25 @@ class ExtractColorspaceData(publish.Extractor): for representation in representations: # check extension ext = representation["ext"] + self.log.debug("__ ext: `{}`".format(ext)) if ext.lower() not in self.allowed_ext: continue + # get one filename filename = representation["files"] if isinstance(filename, list): filename = filename.pop() + self.log.debug("__ filename: `{}`".format( + filename)) + # get matching colorspace from rules colorspace = get_imagio_colorspace_from_filepath( filename, config_path=config_path, file_rules=file_rules ) + self.log.debug("__ colorspace: `{}`".format( + colorspace)) # infuse data to representation if colorspace: