Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@ endif()

target_sources(${PROJECT_NAME} PRIVATE ${source_list})
target_compile_features(${PROJECT_NAME} PUBLIC cxx_std_20)
add_compile_definitions(OPENTRACKIO_BUILD)

# Handle debug vs release builds and their separate libs

Expand Down
14 changes: 12 additions & 2 deletions include/opentrackio-cpp/OpenTrackIOProperties.h
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,16 @@
#define OPEN_TRACK_IO_PROTOCOL_MINOR_VERSION 0
#define OPEN_TRACK_IO_PROTOCOL_PATCH 1

#ifdef _MSC_VER
#ifdef OPENTRACKIO_BUILD
#define EXPORT __declspec(dllexport)
#else
#define EXPORT __declspec(dllimport)
#endif
#else // Support for GCC and Clang.
#define EXPORT __attribute__((visibility("default")))
#endif

namespace opentrackio::opentrackioproperties
{
/** Duration of the clip.
Expand Down Expand Up @@ -305,8 +315,8 @@ namespace opentrackio::opentrackioproperties
struct SourceNumber
{
/**
* Number that identifies the index of the stream from a source from which data is being transported.
* This is most important in the case where a source is producing multiple streams of samples. */
* Number that identifies the index of the stream from a source from which data is being transported.
* This is most important in the case where a source is producing multiple streams of samples. */
uint32_t value;

static std::optional<SourceNumber> parse(nlohmann::json& json, std::vector<std::string>& errors);
Expand Down
2 changes: 1 addition & 1 deletion include/opentrackio-cpp/OpenTrackIOSample.h
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@

namespace opentrackio
{
struct OpenTrackIOSample
struct EXPORT OpenTrackIOSample
{
std::optional<opentrackioproperties::Camera> camera = std::nullopt;
std::optional<opentrackioproperties::Duration> duration = std::nullopt;
Expand Down