Struct ndi::send::Send

source · []
pub struct Send { /* private fields */ }
Expand description

A sender struct for sending NDI

Implementations

Create a new instance with default parameters

It is recommended to use SendBuilder instead

Get the current tally

the return value is whether Tally was actually updated or not

This allows you to receive metadata from the other end of the connection

Retrieve the source information for the given sender instance.

This will add a metadata frame

This will add an audio frame

This will add a video frame

This will add a video frame and will return immediately, having scheduled the frame to be displayed.

All processing and sending of the video will occur asynchronously. The memory accessed by NDIlib_video_frame_t cannot be freed or re-used by the caller until a synchronizing event has occurred. In general the API is better able to take advantage of asynchronous processing than you might be able to by simple having a separate thread to submit frames.

This call is particularly beneficial when processing BGRA video since it allows any color conversion, compression and network sending to all be done on separate threads from your main rendering thread.

Synchronizing events are :

  • a call to send_video
  • a call to send_video_async with another frame to be sent
  • a call to send_video with p_video_data=NULL
  • Dropping a Send instance

Get the current number of receivers connected to this source.

This can be used to avoid even rendering when nothing is connected to the video source. which can significantly improve the efficiency if you want to make a lot of sources available on the network. If you specify a timeout that is not 0 then it will wait until there are connections for this amount of time.

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.