Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

REST-methods and response statuses

REST-method

Example of REST query

Example of response

Response statuses

Description

/mixer/startup

Code Block
languagejs
themeRDark
{
  "uri": "mixer://mixer1",
  "localStreamName": "stream3",
  "hasVideo": "false"
}

200 - OK

409 - Conflict

500 - Internal error

Creates a mixer the provided stream is published for

/mixer/add

Code Block
languagejs
themeRDark
{
  "uri": "mixer://mixer1",
  "remoteStreamName": "stream1"
}

200 - OK

404 - Mixer not found

404 - Stream not found

500 - Internal error

Add the RTMP stream to the mixer

/mixer/remove

Code Block
languagejs
themeRDark
{
  "uri": "mixer://mixer1",
  "remoteStreamName": "stream1"
}

200 - OK

404 - Mixer not found

404 - Stream not found

500 - Internal error

Remove the RTMP stream from the mixer

/mixer/find_all


Code Block
languagejs
themeRDark
{
"localMediaSessionId": "ce92b134-2468-4460-8d06-1ea3c5aabace",
"remoteMediaSessionId": null,
"localStreamName": "mixer1",
"remoteStreamName": null,
"uri": "mixer://mixer1",
"status": "PROCESSED_LOCAL",
"mediaSessions": [
  "95bf2be8-f459-4f62-9a7f-c588f33e0ad3",
  "693781de-cada-4589-abe1-c3ee55c66901"
],
}

200 - OK

404 - Not found

500 - Internal error

Find all mixers

/mixer/terminate

Code Block
languagejs
themeRDark
{
  "uri": "mixer://mixer1"
}

200 - OK

404 - Not found

500 - Internal error

Terminate operation of the mixer

/stream/startRecording

Code Block
languagejs
themeRDark
{
  "mediaSessionId": "23d07fa1-3c74-4d6f-a0de-9b4bf83ce665"
}

200 - OK

404 - Not found

500 - Internal error

Start recording of the stream in the given media session

/stream/stopRecording

Code Block
languagejs
themeRDark
{
  "mediaSessionId": "23d07fa1-3c74-4d6f-a0de-9b4bf83ce665"
}

200 - OK

404 - Not found

500 - Internal error

Stop recording the stream in the given media session

Parameters

Parameter name

Description

Example

uri

Unique identifier of the mixer

mixer://mixer1

localStreamName

Name of the output stream of the mixer

stream3

hasVideoMix video (true) or audio only (false)false

remoteStreamName

Name of the stream added to the mixer

stream1

rtmp://rtmp.flashphoner.com:1935/live/rtmp_stream1

mediaSessionId

Media session identifier

ce92b134-2468-4460-8d06-1ea3c5aabace

status

Stream status

PROCESSED_LOCAL

Sending the REST query to the WCS server

...

Mixing can be configured using the following parameters in the flashphoner.properties settings file

Parameter

Default value

Description

mixer_video_desktop_layout_inline_padding

10

Distance (padding) between windows of video streams in the lower line (below the screen sharing window)

mixer_video_desktop_layout_padding

30

Distance (padding) between the screen sharing window and the lower line (the rest streams)

mixer_video_enabled

true

Enables (by default) or disables video mixing

mixer_video_grid_layout_middle_padding

10

Distance between windows of video streams in one line (without screen sharing window)

mixer_video_grid_layout_padding

30

Distance between lines of windows (without screen sharing window)

mixer_video_height

720

The image height of the mixer output stream

mixer_video_layout_desktop_key_word

desktop

Keyword for the screen sharing stream

mixer_video_width

1280

The image width of the mixer output stream

record_mixer_streams

false

Turns on or off (default) recording of all mixer output streams

Automatic mixer creation configuration

...

In this case for three input streams stream1, stream2, stream3 the following output streams will be generated in mixer mixer1:

Output stream namestream1 stream2stream3
audiovideoaudiovideoaudiovideo
mixer1++++++
mixer1-stream1--+-+-
mixer1-stream2+---+-
mixer1-stream3+-+---

Thus, each of the additional streams contains audio of all streams in the mixer, except for one. This allows for example to eliminate echo for conference participants.

...

In this case for three input streams stream1, stream2, stream3 the following output streams will be generated in mixer mixer1:

Output stream namestream1 stream2stream3
audiovideoaudiovideoaudiovideo
mixer1++++++
mixer1-stream1--++++
mixer1-stream2++--++
mixer1-stream3++++--

Thus, each of the additional streams contains audio and video of all streams in the mixer, except for one. This allows to arrange a full-fledged chat room based on mixer.

...

the main mixer output stream will be only recorded (mixer1 in the example above).

If video MCU support is enables, channel lossses can affect mixer output stream quality. Custom lossless videoprocessor can be used to improve quality, that can make an additional latency.

Quick manual on testing

1. For this test we use:

...