Skip to content

Conversation

@antond-weta
Copy link
Contributor

This removes the libraw data structure being passed to the core library and replaces it with a dedicated structure rta::core::Metadata.

This changes the public interface, so is not backward compatible with v1.x, has to be a major update.

mir - ccttoMired( XYZToColorTemperature( mulVector(
invertV( XYZtoCameraWeightedMatrix( mir, mir1, mir2 ) ),
_neutralRGBDNG ) ) );
_metadata.neutralRGB ) ) );
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should this be coming from argument? so neutralRGB


#if LIBRAW_VERSION >= LIBRAW_MAKE_VERSION( 0, 20, 0 )
metadata.baselineExposure =
static_cast<double>( color.dng_levels.baseline_exposure );
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should it be unsigned short ?

std::filesystem::path pathToRaw = std::filesystem::absolute(
"../../unittest/materials/blackmagic_cinema_camera_cinemadng.dng" );
int ret = rawProcessor.open_file( ( pathToRaw.string() ).c_str() );
ret = rawProcessor.unpack();
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

do you want to put BOOST_REQUIRE_EQUAL( ret, LIBRAW_SUCCESS ); after each line where ret = is assigned? (so it would be open_file and upack. For early clear failure.

#include <unordered_map>
#include <libraw/libraw.h>

using namespace rta;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

suggestion is to remove this namespace and replace those instances of core::Idt with rta::core::Idt here and in .cpp file

to avoid polluting consumers’ namespaces from a public header. Public headers should not inject namespaces.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, but this is unrelated to the change. Trying to keep the scope of each PR limited.
I generally dislike the using namespace thing, we should get rid of those in a separate PR, at least in the public headers.

static AcesRender &getPrivateInstance();

const AcesRender &operator=( const AcesRender &acesrender );

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggestion is to move impl. bit of LibRawAces into .cpp
so lines 17-24 replace with class LibRawAces; and move all this into .cpp instead

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is there a need for #include <libraw/libraw.h> in here as well? to

avoids those ODR/incomplete-type issues and matches how the types are actually defined by LibRaw.

@antond-weta antond-weta force-pushed the remove_libraw_from_core branch from 743547a to f00d813 Compare August 19, 2025 00:13
@antond-weta antond-weta merged commit 64d85ea into AcademySoftwareFoundation:master Aug 19, 2025
13 checks passed
@antond-weta antond-weta deleted the remove_libraw_from_core branch August 30, 2025 05:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants