projects
/
OpenColorIO-Configs.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
a2ddcb8
)
Added support for including the ACES transform ID in the colorspace description....
author
Haarm-Pieter Duiker
<hpd1@duikerresearch.com>
Thu, 25 Jun 2015 19:05:23 +0000
(12:05 -0700)
committer
Haarm-Pieter Duiker
<hpd1@duikerresearch.com>
Thu, 25 Jun 2015 19:05:23 +0000
(12:05 -0700)
aces_1.0.0/python/aces_ocio/aces_config.py
patch
|
blob
|
history
aces_1.0.0/python/aces_ocio/colorspaces/aces.py
patch
|
blob
|
history
aces_1.0.0/python/aces_ocio/utilities.py
patch
|
blob
|
history
diff --git
a/aces_1.0.0/python/aces_ocio/aces_config.py
b/aces_1.0.0/python/aces_ocio/aces_config.py
index
a7c4c34
..
9272908
100755
(executable)
--- a/
aces_1.0.0/python/aces_ocio/aces_config.py
+++ b/
aces_1.0.0/python/aces_ocio/aces_config.py
@@
-319,10
+319,14
@@
def add_colorspace_alias(config,
compact_family_name = 'Aliases'
compact_family_name = 'Aliases'
+ description = colorspace.description
+ if colorspace.aces_transform_id:
+ description += "\n\nACES Transform ID : %s" % colorspace.aces_transform_id
+
ocio_colorspace_alias = ocio.ColorSpace(
name=alias_name,
bitDepth=colorspace.bit_depth,
ocio_colorspace_alias = ocio.ColorSpace(
name=alias_name,
bitDepth=colorspace.bit_depth,
- description=
colorspace.
description,
+ description=description,
equalityGroup=colorspace.equality_group,
family=compact_family_name,
isData=colorspace.is_data,
equalityGroup=colorspace.equality_group,
family=compact_family_name,
isData=colorspace.is_data,
@@
-642,10
+646,14
@@
def create_config(config_data,
print('Creating new color space : %s' % colorspace.name)
print('Creating new color space : %s' % colorspace.name)
+ description = colorspace.description
+ if colorspace.aces_transform_id:
+ description += "\n\nACES Transform ID : %s" % colorspace.aces_transform_id
+
ocio_colorspace = ocio.ColorSpace(
name=colorspace.name,
bitDepth=colorspace.bit_depth,
ocio_colorspace = ocio.ColorSpace(
name=colorspace.name,
bitDepth=colorspace.bit_depth,
- description=
colorspace.
description,
+ description=description,
equalityGroup=colorspace.equality_group,
family=colorspace.family,
isData=colorspace.is_data,
equalityGroup=colorspace.equality_group,
family=colorspace.family,
isData=colorspace.is_data,
diff --git
a/aces_1.0.0/python/aces_ocio/colorspaces/aces.py
b/aces_1.0.0/python/aces_ocio/colorspaces/aces.py
index
e7b0452
..
174b96c
100644
(file)
--- a/
aces_1.0.0/python/aces_ocio/colorspaces/aces.py
+++ b/
aces_1.0.0/python/aces_ocio/colorspaces/aces.py
@@
-131,6
+131,7
@@
def create_ACEScc(aces_ctl_directory,
cs.is_data = False
cs.allocation_type = ocio.Constants.ALLOCATION_UNIFORM
cs.allocation_vars = [min_value, max_value]
cs.is_data = False
cs.allocation_type = ocio.Constants.ALLOCATION_UNIFORM
cs.allocation_vars = [min_value, max_value]
+ cs.aces_transform_id = "ACEScsc.ACEScc_to_ACES.a1.0.0"
ctls = [os.path.join(aces_ctl_directory,
'ACEScc',
ctls = [os.path.join(aces_ctl_directory,
'ACEScc',
@@
-196,6
+197,8
@@
def create_ACESproxy(aces_ctl_directory,
cs.family = 'ACES'
cs.is_data = False
cs.family = 'ACES'
cs.is_data = False
+ cs.aces_transform_id = "ACEScsc.ACESproxy10i_to_ACES.a1.0.0"
+
ctls = [os.path.join(aces_ctl_directory,
'ACESproxy',
'ACEScsc.ACESproxy10i_to_ACES.a1.0.0.ctl'),
ctls = [os.path.join(aces_ctl_directory,
'ACESproxy',
'ACEScsc.ACESproxy10i_to_ACES.a1.0.0.ctl'),
@@
-271,6
+274,8
@@
def create_ACEScg(aces_ctl_directory,
cs.allocation_type = ocio.Constants.ALLOCATION_LG2
cs.allocation_vars = [-8, 5, 0.00390625]
cs.allocation_type = ocio.Constants.ALLOCATION_LG2
cs.allocation_vars = [-8, 5, 0.00390625]
+ cs.aces_transform_id = "ACEScsc.ACEScg_to_ACES.a1.0.0"
+
cs.to_reference_transforms = []
# *AP1* primaries to *AP0* primaries.
cs.to_reference_transforms = []
# *AP1* primaries to *AP0* primaries.
@@
-280,6
+285,13
@@
def create_ACEScg(aces_ctl_directory,
'direction': 'forward'})
cs.from_reference_transforms = []
'direction': 'forward'})
cs.from_reference_transforms = []
+
+ # *AP1* primaries to *AP0* primaries.
+ cs.from_reference_transforms.append({
+ 'type': 'matrix',
+ 'matrix': mat44_from_mat33(ACES_AP0_TO_AP1),
+ 'direction': 'forward'})
+
return cs
return cs
@@
-313,6
+325,8
@@
def create_ADX(lut_directory,
cs.is_data = False
if bit_depth == 10:
cs.is_data = False
if bit_depth == 10:
+ cs.aces_transform_id = "ACEScsc.ADX10_to_ACES.a1.0.0"
+
cs.bit_depth = ocio.Constants.BIT_DEPTH_UINT10
ADX_to_CDD = [1023 / 500, 0, 0, 0,
0, 1023 / 500, 0, 0,
cs.bit_depth = ocio.Constants.BIT_DEPTH_UINT10
ADX_to_CDD = [1023 / 500, 0, 0, 0,
0, 1023 / 500, 0, 0,
@@
-320,6
+334,8
@@
def create_ADX(lut_directory,
0, 0, 0, 1]
offset = [-95 / 500, -95 / 500, -95 / 500, 0]
elif bit_depth == 16:
0, 0, 0, 1]
offset = [-95 / 500, -95 / 500, -95 / 500, 0]
elif bit_depth == 16:
+ cs.aces_transform_id = "ACEScsc.ADX16_to_ACES.a1.0.0"
+
cs.bit_depth = ocio.Constants.BIT_DEPTH_UINT16
ADX_to_CDD = [65535 / 8000, 0, 0, 0,
0, 65535 / 8000, 0, 0,
cs.bit_depth = ocio.Constants.BIT_DEPTH_UINT16
ADX_to_CDD = [65535 / 8000, 0, 0, 0,
0, 65535 / 8000, 0, 0,
@@
-859,6
+875,8
@@
def create_ACES_RRT_plus_ODT(odt_name,
cs.family = 'Output'
cs.is_data = False
cs.family = 'Output'
cs.is_data = False
+ cs.aces_transform_id = odt_values['transformID']
+
pprint.pprint(odt_values)
# Generating the *shaper* transform.
pprint.pprint(odt_values)
# Generating the *shaper* transform.
diff --git
a/aces_1.0.0/python/aces_ocio/utilities.py
b/aces_1.0.0/python/aces_ocio/utilities.py
index
56c9c9d
..
e598221
100644
(file)
--- a/
aces_1.0.0/python/aces_ocio/utilities.py
+++ b/
aces_1.0.0/python/aces_ocio/utilities.py
@@
-45,7
+45,8
@@
class ColorSpace(object):
to_reference_transforms=[],
from_reference_transforms=[],
allocation_type=ocio.Constants.ALLOCATION_UNIFORM,
to_reference_transforms=[],
from_reference_transforms=[],
allocation_type=ocio.Constants.ALLOCATION_UNIFORM,
- allocation_vars=[0, 1]):
+ allocation_vars=[0, 1],
+ aces_transform_id=None):
"""
Object description.
"""
Object description.
@@
-71,7
+72,7
@@
class ColorSpace(object):
self.from_reference_transforms = from_reference_transforms
self.allocation_type = allocation_type
self.allocation_vars = allocation_vars
self.from_reference_transforms = from_reference_transforms
self.allocation_type = allocation_type
self.allocation_vars = allocation_vars
-
+ self.aces_transform_id = aces_transform_id
def mat44_from_mat33(mat33):
"""
def mat44_from_mat33(mat33):
"""