Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
55 commits
Select commit Hold shift + click to select a range
0b74c34
Remove unused include <pystring.h>
KevinJW Jan 13, 2026
6591c7f
Clean up SectionMerger.cpp includes
KevinJW Jan 13, 2026
b9e5262
Tidy up placement of <limits> header inclusion
KevinJW Jan 13, 2026
2adcf86
fstream include tidy up
KevinJW Jan 13, 2026
9d6b293
Minimise <iostream> inclusions
KevinJW Jan 13, 2026
ae9f1b5
Remove unused PrivateTypes includes
KevinJW Jan 13, 2026
78c8b02
Tidy up <sstream> usage
KevinJW Jan 14, 2026
b013031
Reduce usage of "OCIOZArchive.h"
KevinJW Jan 14, 2026
9f2fb0c
Tidy "XMLReaderUtils.h"
KevinJW Jan 14, 2026
e56bbd3
Clean up MatrixOp.h usage
KevinJW Jan 14, 2026
4eda3b3
Tidy up <string.h>/<cstring>
KevinJW Jan 14, 2026
b5e9765
claen up includes for apps
KevinJW Jan 15, 2026
7bda27d
Tidy system headers for bindings and app helpers
KevinJW Jan 15, 2026
4c59f5d
Add a number of system includes
KevinJW Jan 15, 2026
1888788
Start unpicking by removing unneeded OCIO internal includes
KevinJW Jan 15, 2026
dc884f9
More missing includes
KevinJW Jan 15, 2026
a4843af
Reduce dependency on BitDepthUtils.h , prefer cmath over math.h
KevinJW Jan 15, 2026
240e042
Fix Imath include for case sensitive OS's
KevinJW Jan 15, 2026
d10f4c9
Switch some std::endl -> "\n" (reduces need for <iostream>)
KevinJW Jan 15, 2026
02c3bd3
Further removal or std::endl
KevinJW Jan 16, 2026
eeabcc0
remove unneccessary continuation characters
KevinJW Jan 16, 2026
51f3709
More std::endl removal
KevinJW Jan 16, 2026
da3ed46
More continuation character removal
KevinJW Jan 16, 2026
ca23e5b
std::endl removal
KevinJW Jan 16, 2026
53d5f9a
Minimise StringUtils.h usage
KevinJW Jan 16, 2026
58190ca
Avoid poluting namespace with "naked" OCIO
KevinJW Jan 20, 2026
158d8fd
Unneeded GpuShaderUtils include
KevinJW Jan 20, 2026
2493849
Add some additional system includes
KevinJW Jan 20, 2026
cf6f303
Add some further direct includes to python bindings
KevinJW Jan 21, 2026
320d495
Avoid including Python binding headers when not needed
KevinJW Jan 21, 2026
0e3e94b
Reduce dependencies on PyUtils.h
KevinJW Jan 21, 2026
1dddbd0
Defend docstrings.h against multiple inclusion
KevinJW Jan 21, 2026
992f68b
Ensure we get correct visibility definition for pybind11 namespace
KevinJW Jan 21, 2026
e9e3648
Include docstrings directly in cpp files
KevinJW Jan 21, 2026
e2d7e15
move pybind11 numpy and functional includes from generic header
KevinJW Jan 21, 2026
8ed508b
Add pybind11 includes to python binding .cpp files
KevinJW Jan 22, 2026
f6e19d8
include cstddef to define ptrdiff_t
KevinJW Jan 22, 2026
b18bc41
Avoid bringing in py:: and pybind11::literals into scope via header i…
KevinJW Jan 23, 2026
4f98c64
Remove namespace alias
KevinJW Jan 23, 2026
20e0d1f
Add missing pybind11/stl.h includes
KevinJW Jan 23, 2026
f97d43c
Remove pybind11/stl.h from generic header
KevinJW Jan 23, 2026
3420f03
Directly include "PyOpenColorIO.h" for polymorphic_type_hook
KevinJW Jan 23, 2026
a571754
Split PyUtils into separate Utils and bufferUtils header to reduce ex…
KevinJW Jan 23, 2026
4df353d
Attemp to reduce dependencies on half.h
KevinJW Jan 26, 2026
00b1c31
Some include what you use header suggestions arround the ACES code
KevinJW Jan 26, 2026
a210e4a
ACES Transform: Ensure we use the mathematical functions from the std…
KevinJW Jan 28, 2026
d6c02d7
Tidy Usage of Mutex and CPUInfo
KevinJW Jan 28, 2026
01560e1
Add include for snprintf
KevinJW Jan 28, 2026
a1c0eb3
Remove some unneeded string->char*->string conversions
KevinJW Jan 29, 2026
cef41be
Reduce scope of includes
KevinJW Jan 29, 2026
fdfeae3
Remove duplicate access specifier
KevinJW Jan 29, 2026
15883dd
remove unneeded use of std::endl
KevinJW Apr 28, 2026
290628c
Removed unused namespace aliasing
KevinJW Apr 28, 2026
56a05c1
Add missing BitDepthUtils.h include
KevinJW Apr 28, 2026
f0a26fc
Try speed up Unit tests
KevinJW Apr 28, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
2 changes: 1 addition & 1 deletion docs/concepts/overview/internal_architecture.rst
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,7 @@ Example:
}
catch(OCIO::Exception & exception)
{
std::cerr << "OpenColorIO Error: " << exception.what() << std::endl;
std::cerr << "OpenColorIO Error: " << exception.what() << "\n";
}


Expand Down
4 changes: 2 additions & 2 deletions docs/guides/developing/usage_examples.rst
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ C++
}
catch(OCIO::Exception & exception)
{
std::cerr << "OpenColorIO Error: " << exception.what() << std::endl;
std::cerr << "OpenColorIO Error: " << exception.what() << "\n";
}

.. _usage_applybasic_python:
Expand Down Expand Up @@ -149,7 +149,7 @@ C++
}
catch(OCIO::Exception & exception)
{
std::cerr << "OpenColorIO Error: " << exception.what() << std::endl;
std::cerr << "OpenColorIO Error: " << exception.what() << "\n";
}

Python
Expand Down
4 changes: 2 additions & 2 deletions include/OpenColorIO/OpenColorIO.h
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,10 @@
#include <limits>
#include <stdexcept>
#include <string>
#include <fstream>
#include <vector>
#include <cstdint>
#include <map>
#include <functional>

#include "OpenColorABI.h"
#include "OpenColorTypes.h"
Expand Down Expand Up @@ -53,7 +53,7 @@ C++ API
}
catch(OCIO::Exception & exception)
{
std::cerr << "OpenColorIO Error: " << exception.what() << std::endl;
std::cerr << "OpenColorIO Error: " << exception.what() << "\n";
}

*/
Expand Down
1 change: 0 additions & 1 deletion include/OpenColorIO/OpenColorTransforms.h
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@
#define INCLUDED_OCIO_OPENCOLORTRANSFORMS_H

#include <initializer_list>
#include <limits>

#include "OpenColorTypes.h"

Expand Down
1 change: 0 additions & 1 deletion include/OpenColorIO/OpenColorTypes.h
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@
#endif

#include <array>
#include <limits>
#include <string>
#include <functional>

Expand Down
4 changes: 4 additions & 0 deletions share/docs/docstrings.h
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,8 @@

-----------------------------------------------------------------------------
*/
#ifndef INCLUDED_OCIO_DOCSTRINGS_H
#define INCLUDED_OCIO_DOCSTRINGS_H

#define DOC(...) __doc_none

Expand All @@ -51,3 +53,5 @@ static const char *__doc_none = R"doc()doc";
#if defined(__GNUG__)
#pragma GCC diagnostic pop
#endif

#endif
3 changes: 3 additions & 0 deletions share/docs/extract_docstrings.py
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,8 @@
This file contains docstrings for use in the Python bindings.
Do not edit! They were automatically extracted by OpenColorIO/share/docs/extract_docstrings.py.
*/
#ifndef INCLUDED_OCIO_DOCSTRINGS_H
#define INCLUDED_OCIO_DOCSTRINGS_H

#define __EXPAND(x) x
#define __COUNT(_1, _2, _3, _4, _5, _6, _7, COUNT, ...) COUNT
Expand All @@ -93,6 +95,7 @@
#if defined(__GNUG__)
#pragma GCC diagnostic pop
#endif
#endif
"""

CPP_OPERATORS = {
Expand Down
7 changes: 6 additions & 1 deletion src/OpenColorIO/AVX.h
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,16 @@
#define INCLUDED_OCIO_AVX_H

#include "CPUInfo.h"

#if OCIO_USE_AVX

#include <immintrin.h>

#include <OpenColorIO/OpenColorIO.h>
#if OCIO_USE_F16C
#include <Imath/half.h>
#endif

#include "OpenColorABI.h"
#include "BitDepthUtils.h"

// Macros for alignment declarations
Expand Down
6 changes: 5 additions & 1 deletion src/OpenColorIO/AVX2.h
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,11 @@

#include <immintrin.h>

#include <OpenColorIO/OpenColorIO.h>
#if OCIO_USE_F16C
#include <Imath/half.h>
#endif

#include "OpenColorABI.h"
#include "BitDepthUtils.h"

// Macros for alignment declarations
Expand Down
4 changes: 3 additions & 1 deletion src/OpenColorIO/AVX512.h
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,9 @@

#include <immintrin.h>

#include <OpenColorIO/OpenColorIO.h>
#include <Imath/half.h>

#include "OpenColorABI.h"
#include "BitDepthUtils.h"

// Macros for alignment declarations
Expand Down
6 changes: 4 additions & 2 deletions src/OpenColorIO/Baker.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,15 @@
// Copyright Contributors to the OpenColorIO Project.


#include <iostream>
#include <ostream>
#include <sstream>
#include <string>
#include <exception>

#include <OpenColorIO/OpenColorIO.h>

#include "transforms/FileTransform.h"
#include "BakingUtils.h"
#include "MathUtils.h"


namespace OCIO_NAMESPACE
Expand Down
3 changes: 3 additions & 0 deletions src/OpenColorIO/BakingUtils.cpp
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
// SPDX-License-Identifier: BSD-3-Clause
// Copyright Contributors to the OpenColorIO Project.

#include <string>
#include <algorithm>

#include "BakingUtils.h"

namespace OCIO_NAMESPACE
Expand Down
2 changes: 2 additions & 0 deletions src/OpenColorIO/BitDepthUtils.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@
// Copyright Contributors to the OpenColorIO Project.


#include <string>

#include <OpenColorIO/OpenColorIO.h>

#include "BitDepthUtils.h"
Expand Down
8 changes: 6 additions & 2 deletions src/OpenColorIO/CPUInfo.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,19 @@


#include "CPUInfo.h"
#include <string.h>
#include <cstring>

#if defined(__aarch64__) || defined(_M_ARM64) // ARM 64-bit processor (multiple platforms)
#include <stdio.h>
#endif

#if _WIN32
#include <limits.h>
#include <intrin.h>
typedef unsigned __int32 uint32_t;
typedef __int64 int64_t;
#else
#include <stdint.h>
#include <cstdint>
#endif

namespace OCIO_NAMESPACE
Expand Down
3 changes: 2 additions & 1 deletion src/OpenColorIO/CPUInfo.h
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,8 @@
#ifndef CPUInfo_H
#define CPUInfo_H

#include <OpenColorIO/OpenColorIO.h>
#include "OpenColorABI.h"

#include "CPUInfoConfig.h"

namespace OCIO_NAMESPACE
Expand Down
7 changes: 4 additions & 3 deletions src/OpenColorIO/CPUProcessor.cpp
Original file line number Diff line number Diff line change
@@ -1,17 +1,18 @@
// SPDX-License-Identifier: BSD-3-Clause
// Copyright Contributors to the OpenColorIO Project.

#include <string.h>
#include <cstring>
#include <sstream>
#include <memory>

#include <OpenColorIO/OpenColorIO.h>

#include "BitDepthUtils.h"
#include "CPUProcessor.h"
#include "ops/lut1d/Lut1DOpCPU.h"
#include "ops/lut3d/Lut3DOpCPU.h"
#include "ops/matrix/MatrixOp.h"
#include "ops/range/RangeOpCPU.h"
#include "ScanlineHelper.h"
#include "Mutex.h"


namespace OCIO_NAMESPACE
Expand Down
1 change: 1 addition & 0 deletions src/OpenColorIO/CPUProcessor.h
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
#include <OpenColorIO/OpenColorIO.h>

#include "Op.h"
#include "Mutex.h"


namespace OCIO_NAMESPACE
Expand Down
13 changes: 6 additions & 7 deletions src/OpenColorIO/ColorSpace.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,16 @@

#include <cstring>
#include <sstream>
#include <ostream>
#include <vector>
#include <array>
#include <map>
#include <algorithm>

#include <OpenColorIO/OpenColorIO.h>

#include "TokensManager.h"
#include "Platform.h"
#include "PrivateTypes.h"
#include "utils/StringUtils.h"


Expand Down Expand Up @@ -255,8 +257,7 @@ void ColorSpace::setInteropID(const char * interopID)
{
std::ostringstream oss;
oss << "InteropID '" << id << "' contains invalid characters. "
"Only lowercase a-z, 0-9 and . - _ ~ / * # % ^ + ( ) [ ] | are allowed." <<
std::endl;
"Only lowercase a-z, 0-9 and . - _ ~ / * # % ^ + ( ) [ ] | are allowed.\n";
throw Exception(oss.str().c_str());
}

Expand All @@ -273,8 +274,7 @@ void ColorSpace::setInteropID(const char * interopID)
{
std::ostringstream oss;
oss << "InteropID '" << id << "' is not valid. "
"If ':' is used, both the namespace and the color space parts must be non-empty." <<
std::endl;
"If ':' is used, both the namespace and the color space parts must be non-empty.\n";
throw Exception(oss.str().c_str());
}

Expand All @@ -283,8 +283,7 @@ void ColorSpace::setInteropID(const char * interopID)
{
std::ostringstream oss;
oss << "ERROR: InteropID '" << id << "' is not valid. "
"Only one ':' is allowed to separate the namespace and the color space." <<
std::endl;
"Only one ':' is allowed to separate the namespace and the color space.\n";
throw Exception(oss.str().c_str());
}
}
Expand Down
2 changes: 1 addition & 1 deletion src/OpenColorIO/ColorSpaceSet.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,10 @@

#include <sstream>
#include <string>
#include <vector>

#include <OpenColorIO/OpenColorIO.h>

#include "PrivateTypes.h"
#include "utils/StringUtils.h"


Expand Down
19 changes: 9 additions & 10 deletions src/OpenColorIO/Config.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,13 @@
#include <vector>
#include <regex>
#include <functional>
#include <algorithm>
#include <exception>

#include <pystring.h>

#include <OpenColorIO/OpenColorIO.h>

#include "builtinconfigs/BuiltinConfigRegistry.h"
#include "ConfigUtils.h"
#include "ContextVariableUtils.h"
#include "Display.h"
Expand All @@ -27,20 +28,18 @@
#include "LookParse.h"
#include "MathUtils.h"
#include "Mutex.h"
#include "NamedTransform.h"
#include "OCIOYaml.h"
#include "OCIOZArchive.h"
#include "OpBuilders.h"
#include "ParseUtils.h"
#include "PathUtils.h"
#include "Platform.h"
#include "PrivateTypes.h"
#include "Processor.h"
#include "transforms/FileTransform.h"
#include "utils/StringUtils.h"
#include "ViewingRules.h"
#include "SystemMonitor.h"


namespace OCIO_NAMESPACE
{

Expand Down Expand Up @@ -155,15 +154,15 @@ void GetFileReferences(std::set<std::string> & files, const ConstTransformRcPtr
{
if(!transform) return;

if(ConstGroupTransformRcPtr groupTransform = \
if(ConstGroupTransformRcPtr groupTransform =
DynamicPtrCast<const GroupTransform>(transform))
{
for(int i=0; i<groupTransform->getNumTransforms(); ++i)
{
GetFileReferences(files, groupTransform->getTransform(i));
}
}
else if(ConstFileTransformRcPtr fileTransform = \
else if(ConstFileTransformRcPtr fileTransform =
DynamicPtrCast<const FileTransform>(transform))
{
files.insert(fileTransform->getSrc());
Expand All @@ -179,26 +178,26 @@ void GetColorSpaceReferences(std::set<std::string> & colorSpaceNames,
{
if(!transform) return;

if(ConstGroupTransformRcPtr groupTransform = \
if(ConstGroupTransformRcPtr groupTransform =
DynamicPtrCast<const GroupTransform>(transform))
{
for(int i=0; i<groupTransform->getNumTransforms(); ++i)
{
GetColorSpaceReferences(colorSpaceNames, groupTransform->getTransform(i), context);
}
}
else if(ConstColorSpaceTransformRcPtr colorSpaceTransform = \
else if(ConstColorSpaceTransformRcPtr colorSpaceTransform =
DynamicPtrCast<const ColorSpaceTransform>(transform))
{
colorSpaceNames.insert(context->resolveStringVar(colorSpaceTransform->getSrc()));
colorSpaceNames.insert(context->resolveStringVar(colorSpaceTransform->getDst()));
}
else if(ConstDisplayViewTransformRcPtr displayViewTransform = \
else if(ConstDisplayViewTransformRcPtr displayViewTransform =
DynamicPtrCast<const DisplayViewTransform>(transform))
{
colorSpaceNames.insert(displayViewTransform->getSrc());
}
else if(ConstLookTransformRcPtr lookTransform = \
else if(ConstLookTransformRcPtr lookTransform =
DynamicPtrCast<const LookTransform>(transform))
{
colorSpaceNames.insert(lookTransform->getSrc());
Expand Down
Loading