Skip to content

Commit 04a36e3

Browse files
committed
chore: upgrade to NDI 6.2
1 parent d141556 commit 04a36e3

19 files changed

+526
-238
lines changed

ndi/Processing.NDI.DynamicLoad.h

Lines changed: 242 additions & 213 deletions
Large diffs are not rendered by default.

ndi/Processing.NDI.Find.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
//
99
//***********************************************************************************************************
1010
//
11-
// Copyright (C) 2023-2024 Vizrt NDI AB. All rights reserved.
11+
// Copyright (C) 2023-2025 Vizrt NDI AB. All rights reserved.
1212
//
1313
// Permission is hereby granted, free of charge, to any person obtaining a copy of this software and
1414
// associated documentation files(the "Software"), to deal in the Software without restriction, including

ndi/Processing.NDI.FrameSync.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
//
99
//***********************************************************************************************************
1010
//
11-
// Copyright (C) 2023-2024 Vizrt NDI AB. All rights reserved.
11+
// Copyright (C) 2023-2025 Vizrt NDI AB. All rights reserved.
1212
//
1313
// Permission is hereby granted, free of charge, to any person obtaining a copy of this software and
1414
// associated documentation files(the "Software"), to deal in the Software without restriction, including

ndi/Processing.NDI.Lib.cplusplus.h

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
//
99
//***********************************************************************************************************
1010
//
11-
// Copyright (C) 2023-2024 Vizrt NDI AB. All rights reserved.
11+
// Copyright (C) 2023-2025 Vizrt NDI AB. All rights reserved.
1212
//
1313
// Permission is hereby granted, free of charge, to any person obtaining a copy of this software and
1414
// associated documentation files(the "Software"), to deal in the Software without restriction, including
@@ -114,6 +114,16 @@ inline NDIlib_audio_frame_interleaved_32s_t::NDIlib_audio_frame_interleaved_32s_
114114
inline NDIlib_audio_frame_interleaved_32f_t::NDIlib_audio_frame_interleaved_32f_t(int sample_rate_, int no_channels_, int no_samples_, int64_t timecode_, float* p_data_)
115115
: sample_rate(sample_rate_), no_channels(no_channels_), no_samples(no_samples_), timecode(timecode_), p_data(p_data_) {}
116116

117+
inline NDIlib_recv_advertiser_create_t::NDIlib_recv_advertiser_create_t(const char* p_url_address)
118+
: p_url_address(p_url_address) {}
119+
120+
inline NDIlib_recv_listener_create_t::NDIlib_recv_listener_create_t(const char* p_url_address)
121+
: p_url_address(p_url_address) {}
122+
123+
inline NDIlib_receiver_t::NDIlib_receiver_t(void)
124+
: p_uuid(NULL), p_name(NULL), p_input_uuid(NULL), p_input_name(NULL), p_address(NULL),
125+
p_streams(NULL), num_streams(0), p_commands(NULL), num_commands(0), events_subscribed(false) {}
126+
117127
#ifdef __clang__
118128
#pragma clang diagnostic pop
119129
#endif

ndi/Processing.NDI.Lib.h

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
//
99
//***********************************************************************************************************
1010
//
11-
// Copyright (C) 2023-2024 Vizrt NDI AB. All rights reserved.
11+
// Copyright (C) 2023-2025 Vizrt NDI AB. All rights reserved.
1212
//
1313
// Permission is hereby granted, free of charge, to any person obtaining a copy of this software and
1414
// associated documentation files(the "Software"), to deal in the Software without restriction, including
@@ -135,6 +135,12 @@ bool NDIlib_is_supported_CPU(void);
135135
// Extensions to support PTZ control, etc...
136136
#include "Processing.NDI.Recv.ex.h"
137137

138+
// The receiver advertiser API.
139+
#include "Processing.NDI.RecvAdvertiser.h"
140+
141+
// The receiver listener API.
142+
#include "Processing.NDI.RecvListener.h"
143+
138144
// The sending video API.
139145
#include "Processing.NDI.Send.h"
140146

ndi/Processing.NDI.Recv.ex.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
//
99
//***********************************************************************************************************
1010
//
11-
// Copyright (C) 2023-2024 Vizrt NDI AB. All rights reserved.
11+
// Copyright (C) 2023-2025 Vizrt NDI AB. All rights reserved.
1212
//
1313
// Permission is hereby granted, free of charge, to any person obtaining a copy of this software and
1414
// associated documentation files(the "Software"), to deal in the Software without restriction, including

ndi/Processing.NDI.Recv.h

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
//
99
//***********************************************************************************************************
1010
//
11-
// Copyright (C) 2023-2024 Vizrt NDI AB. All rights reserved.
11+
// Copyright (C) 2023-2025 Vizrt NDI AB. All rights reserved.
1212
//
1313
// Permission is hereby granted, free of charge, to any person obtaining a copy of this software and
1414
// associated documentation files(the "Software"), to deal in the Software without restriction, including
@@ -285,3 +285,13 @@ int NDIlib_recv_get_no_connections(NDIlib_recv_instance_t p_instance);
285285
// when the NDILib_recv_capture* call would return NDIlib_frame_type_status_change.
286286
PROCESSINGNDILIB_API
287287
const char* NDIlib_recv_get_web_control(NDIlib_recv_instance_t p_instance);
288+
289+
// Retrieve the name of the current NDI source that the NDI receiver is connected to. This will return false
290+
// if there has been no change in the source information since the last call. If p_source_name is NULL, then
291+
// the name of the current NDI source will not be returned. If p_source_name is not NULL, then the name of
292+
// the current source will be returned, however, the returned value can be NULL if the NDI receiver is
293+
// currently not connected to a source. If the returned pointer is not NULL, then you should call
294+
// NDIlib_recv_free_string to free the string that is returned by this function. A timeout value can be given
295+
// to wait until a change occurs. If waiting is not desired, then use a timeout of 0.
296+
PROCESSINGNDILIB_API
297+
bool NDIlib_recv_get_source_name(NDIlib_recv_instance_t p_instance, const char** p_source_name, uint32_t timeout_in_ms NDILIB_CPP_DEFAULT_VALUE(0));
Lines changed: 79 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,79 @@
1+
#pragma once
2+
3+
// NOTE : The following MIT license applies to this file ONLY and not to the SDK as a whole. Please review
4+
// the SDK documentation for the description of the full license terms, which are also provided in the file
5+
// "NDI License Agreement.pdf" within the SDK or online at http://ndi.link/ndisdk_license. Your use of any
6+
// part of this SDK is acknowledgment that you agree to the SDK license terms. The full NDI SDK may be
7+
// downloaded at http://ndi.video/
8+
//
9+
//***********************************************************************************************************
10+
//
11+
// Copyright (C) 2023-2024 Vizrt NDI AB. All rights reserved.
12+
//
13+
// Permission is hereby granted, free of charge, to any person obtaining a copy of this software and
14+
// associated documentation files(the "Software"), to deal in the Software without restriction, including
15+
// without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and / or sell
16+
// copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the
17+
// following conditions :
18+
//
19+
// The above copyright notice and this permission notice shall be included in all copies or substantial
20+
// portions of the Software.
21+
//
22+
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT
23+
// LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO
24+
// EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
25+
// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR
26+
// THE USE OR OTHER DEALINGS IN THE SOFTWARE.
27+
//
28+
//***********************************************************************************************************
29+
30+
// The type instance for a receiver advertiser.
31+
struct NDIlib_recv_advertiser_instance_type;
32+
typedef struct NDIlib_recv_advertiser_instance_type* NDIlib_recv_advertiser_instance_t;
33+
34+
typedef struct NDIlib_recv_advertiser_create_t {
35+
// The URL address of the NDI Discovery Server to connect to. If NULL, then the default NDI discovery
36+
// server will be used. If there is no discovery server available, then the receiver advertiser will not
37+
// be able to be instantiated and the create function will return NULL. The format of this field is
38+
// expected to be the hostname or IP address, optionally followed by a colon and a port number. If the
39+
// port number is not specified, then port 5959 will be used. For example,
40+
// 127.0.0.1:5959
41+
// or
42+
// 127.0.0.1
43+
// or
44+
// hostname:5959
45+
// This field can also specify multiple addresses separated by commas for redundancy support.
46+
const char* p_url_address;
47+
48+
#if NDILIB_CPP_DEFAULT_CONSTRUCTORS
49+
NDIlib_recv_advertiser_create_t(
50+
const char* p_url_address = NULL
51+
);
52+
#endif // NDILIB_CPP_DEFAULT_CONSTRUCTORS
53+
} NDIlib_recv_advertiser_create_t;
54+
55+
// Create an instance of the receiver advertiser. This will return NULL if it fails to create the advertiser.
56+
PROCESSINGNDILIB_API
57+
NDIlib_recv_advertiser_instance_t NDIlib_recv_advertiser_create(const NDIlib_recv_advertiser_create_t* p_create_settings NDILIB_CPP_DEFAULT_VALUE(NULL));
58+
59+
// Destroy an instance of the receiver advertiser.
60+
PROCESSINGNDILIB_API
61+
void NDIlib_recv_advertiser_destroy(NDIlib_recv_advertiser_instance_t p_instance);
62+
63+
// Add the receiver to the list of receivers that are being advertised. Returns false if the receiver has
64+
// been previously registered.
65+
PROCESSINGNDILIB_API
66+
bool NDIlib_recv_advertiser_add_receiver(
67+
NDIlib_recv_advertiser_instance_t p_instance,
68+
NDIlib_recv_instance_t p_receiver,
69+
bool allow_controlling, bool allow_monitoring,
70+
const char* p_input_group_name NDILIB_CPP_DEFAULT_VALUE(NULL)
71+
);
72+
73+
// Remove the receiver from the list of receivers that are being advertised. Returns false if the receiver
74+
// was not previously registered.
75+
PROCESSINGNDILIB_API
76+
bool NDIlib_recv_advertiser_del_receiver(
77+
NDIlib_recv_advertiser_instance_t p_instance,
78+
NDIlib_recv_instance_t p_receiver
79+
);

ndi/Processing.NDI.RecvListener.h

Lines changed: 141 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,141 @@
1+
#pragma once
2+
3+
// NOTE : The following MIT license applies to this file ONLY and not to the SDK as a whole. Please review
4+
// the SDK documentation for the description of the full license terms, which are also provided in the file
5+
// "NDI License Agreement.pdf" within the SDK or online at http://ndi.link/ndisdk_license. Your use of any
6+
// part of this SDK is acknowledgment that you agree to the SDK license terms. The full NDI SDK may be
7+
// downloaded at http://ndi.video/
8+
//
9+
//***********************************************************************************************************
10+
//
11+
// Copyright (C) 2023-2024 Vizrt NDI AB. All rights reserved.
12+
//
13+
// Permission is hereby granted, free of charge, to any person obtaining a copy of this software and
14+
// associated documentation files(the "Software"), to deal in the Software without restriction, including
15+
// without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and / or sell
16+
// copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the
17+
// following conditions :
18+
//
19+
// The above copyright notice and this permission notice shall be included in all copies or substantial
20+
// portions of the Software.
21+
//
22+
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT
23+
// LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO
24+
// EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
25+
// IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR
26+
// THE USE OR OTHER DEALINGS IN THE SOFTWARE.
27+
//
28+
//***********************************************************************************************************
29+
30+
// The type instance for a receiver listener.
31+
struct NDIlib_recv_listener_instance_type;
32+
typedef struct NDIlib_recv_listener_instance_type* NDIlib_recv_listener_instance_t;
33+
34+
typedef struct NDIlib_recv_listener_create_t {
35+
// The URL address of the NDI Discovery Server to connect to. If NULL, then the default NDI discovery
36+
// server will be used. If there is no discovery server available, then the receiver listener will not
37+
// be able to be instantiated and the create function will return NULL. The format of this field is
38+
// expected to be the hostname or IP address, optionally followed by a colon and a port number. If the
39+
// port number is not specified, then port 5959 will be used. For example,
40+
// 127.0.0.1:5959
41+
// or
42+
// 127.0.0.1
43+
// or
44+
// hostname:5959
45+
// If this field is a comma-separated list, then only the first address will be used.
46+
const char* p_url_address;
47+
48+
#if NDILIB_CPP_DEFAULT_CONSTRUCTORS
49+
NDIlib_recv_listener_create_t(
50+
const char* p_url_address = NULL
51+
);
52+
#endif // NDILIB_CPP_DEFAULT_CONSTRUCTORS
53+
} NDIlib_recv_listener_create_t;
54+
55+
// Create an instance of the receiver listener. This will return NULL if it fails to create the listener.
56+
PROCESSINGNDILIB_API
57+
NDIlib_recv_listener_instance_t NDIlib_recv_listener_create(const NDIlib_recv_listener_create_t* p_create_settings NDILIB_CPP_DEFAULT_VALUE(NULL));
58+
59+
// Destroy an instance of the receiver listener.
60+
PROCESSINGNDILIB_API
61+
void NDIlib_recv_listener_destroy(NDIlib_recv_listener_instance_t p_instance);
62+
63+
// Returns true if the receiver listener is actively connected to the configured NDI Discovery Server.
64+
PROCESSINGNDILIB_API
65+
bool NDIlib_recv_listener_is_connected(NDIlib_recv_listener_instance_t p_instance);
66+
67+
// Retrieve the URL address of the NDI Discovery Server that the receiver listener is connected to. This can
68+
// return NULL if the instance pointer is invalid.
69+
PROCESSINGNDILIB_API
70+
const char* NDIlib_recv_listener_get_server_url(NDIlib_recv_listener_instance_t p_instance);
71+
72+
// The types of streams that a receiver can receive from the source it's connected to.
73+
typedef enum NDIlib_receiver_type_e {
74+
NDIlib_receiver_type_none = 0,
75+
NDIlib_receiver_type_metadata = 1,
76+
NDIlib_receiver_type_video = 2,
77+
NDIlib_receiver_type_audio = 3,
78+
79+
// Make sure this is a 32-bit enumeration.
80+
NDIlib_receiver_type_max = 0x7fffffff
81+
} NDIlib_receiver_type_e;
82+
83+
// The types of commands that a receiver can process.
84+
typedef enum NDIlib_receiver_command_e {
85+
NDIlib_receiver_command_none = 0,
86+
87+
// A receiver can be told to connect to a specific source.
88+
NDIlib_receiver_command_connect = 1,
89+
90+
// Make sure this is a 32-bit enumeration.
91+
NDIlib_receiver_command_max = 0x7fffffff
92+
} NDIlib_receiver_command_e;
93+
94+
// Describes a receiver that has been discovered.
95+
typedef struct NDIlib_receiver_t {
96+
// The unique identifier for the receiver on the network.
97+
const char* p_uuid;
98+
99+
// The human-readable name of the receiver.
100+
const char* p_name;
101+
102+
// The unique identifier for the input group that the receiver belongs to.
103+
const char* p_input_uuid;
104+
105+
// The human-readable name of the input group that the receiver belongs to.
106+
const char* p_input_name;
107+
108+
// The known IP address of the receiver.
109+
const char* p_address;
110+
111+
// An array of streams that the receiver is set to receive. The last entry in this list will be
112+
// NDIlib_receiver_type_none.
113+
NDIlib_receiver_type_e* p_streams;
114+
115+
// How many elements are in the p_streams array, excluding the NDIlib_receiver_type_none entry.
116+
uint32_t num_streams;
117+
118+
// An array of commands that the receiver can process. The last entry in this list will be
119+
// NDIlib_receiver_command_none.
120+
NDIlib_receiver_command_e* p_commands;
121+
122+
// How many elements are in the p_commands array, excluding the NDIlib_receiver_command_none entry.
123+
uint32_t num_commands;
124+
125+
// Are we currently subscribed for receive events?
126+
bool events_subscribed;
127+
128+
#if NDILIB_CPP_DEFAULT_CONSTRUCTORS
129+
NDIlib_receiver_t(void);
130+
#endif // NDILIB_CPP_DEFAULT_CONSTRUCTORS
131+
} NDIlib_receiver_t;
132+
133+
// Retrieves the current list of advertised receivers. The memory for the returned structure is only valid
134+
// until the next call or when destroy is called. For a given NDIlib_recv_listener_instance_t, do not call
135+
// NDIlib_recv_listener_get_receivers asynchronously.
136+
PROCESSINGNDILIB_API
137+
const NDIlib_receiver_t* NDIlib_recv_listener_get_receivers(NDIlib_recv_listener_instance_t p_instance, uint32_t* p_num_receivers);
138+
139+
// This will allow you to wait until the number of online receivers has changed.
140+
PROCESSINGNDILIB_API
141+
bool NDIlib_recv_listener_wait_for_receivers(NDIlib_recv_listener_instance_t p_instance, uint32_t timeout_in_ms);

ndi/Processing.NDI.Routing.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
//
99
//***********************************************************************************************************
1010
//
11-
// Copyright (C) 2023-2024 Vizrt NDI AB. All rights reserved.
11+
// Copyright (C) 2023-2025 Vizrt NDI AB. All rights reserved.
1212
//
1313
// Permission is hereby granted, free of charge, to any person obtaining a copy of this software and
1414
// associated documentation files(the "Software"), to deal in the Software without restriction, including

0 commit comments

Comments
 (0)