Knowledge base
1000 FAQs, 500 tutorials and explanatory videos. Here, there are only solutions!
Multi-bitrate or transcoding enables the broadcast of a stream in the best quality possible, depending on your viewers' internet connection. Without this feature, your stream is only broadcast in a single quality and viewers who do not have a good internet connection may not be able to read it.
There are two ways to offer this feature to your users: local transcoding or cloud transcoding.
Local transcoding vs. cloud transcoding: pros ad cons
- Let Infomaniak manage your transcoding
The entire process is automatic: Infomaniak configures ands transcods the different qualities necessary and your viewers are guaranteed to be able to follow your broadcasts under the best possible conditions, regardless of the speed of their internet connection.
- A single, maximum-quality stream will be sent on your part.
- A software encoder is sufficient, although we recommend a hardware encoder for greater reliability and performance.
- Locally manage manual transcoding
The entire process is manual: you must configure the qualities and their number and possess the necessary hardware and network configuration to ensure transcoding and sending data
- An encoder is required for transcoding (Infomaniak sells them, if necesary).
- The encoder (or the server dedicated to this task) must be sufficiently powerful to simultaneously transcode your streams in different qualities. If not, the stream will be interrupted and unstable for your viewers.
- A good internet connection is required to simultaneously send the stream in different qualities.
Infomaniak's video streaming platform offers two possibilities to recover video streams for broadcasting:
- PUSH mode: you push the streams towards the Infomaniak platform.
- PULL mode: you enter a source URL address from which Infomaniak will retrieve the stream. This method enables the broadcast of an existing stream via Infomaniak.
IP camera (PUSH mode)
The most common use concerns IP cameras, which are accessible from a URL or IP address.
For optimal operation:
- Your equipment must support the RTSP protocol and the H264 video codec (do not rely on MPEG4)
- Your equipment must be publicly accessible via the internet on port 554 (any other port will be refused)
- The RTSP address must function in a video player (VLC, mplayer, etc.)
- The RTSP address must be retrievable via the administration interface of your equipment
External source (PULL mode)
It is also possible to retrieve the stream of an external source, which, for example, enables the retreatment of an existing stream by adding a watermark and using Infomaniak's broadcasting servers to reach a wide audience.
The following streaming protocols are currently supported:
- RTP
- RTSP
- RTMP
This guide explains how to live stream a list of videos from the VOD service using the Video Streaming product.
What's the purpose?
This feature allows using the VOD service to create a video playlist and then using the Video Streaming service to broadcast it live, for example in the context of a music video channel, teleshopping, documentaries, etc. It's possible to insert advertisements between each video, manually or using VAST tag. The playlist will be looped infinitely until the user stops it.
Some usage examples
Streaming a playlist can serve as a fallback solution as soon as a live stream cuts off (voluntarily or involuntarily) and in this case, take over the air. As soon as the live encoder pushes a stream again, it takes control of the playlist. This allows broadcasting alternative content if there's an issue with the live stream or if the user only streams live content in the evening, for example, they can automate playlist content broadcasting for the rest of the day.
It's also possible to schedule playlist broadcasting from the Video Streaming scheduling tool. Thus, you can choose single or different playlist broadcasting time slots in advance, or recurrently. The live streaming encoder will be automatically disconnected during the entire playlist broadcasting period; once the time slot ends, the encoder will reconnect, and its content will be streamed.
A VOD playlist can be created and edited manually (by selecting the video to add to the list) or be dynamic if automatically composed by a batch of videos located in a specific folder and added as needed. In both cases, stop and restart the live streaming to take into account any new video added to the playlist - note that this will no longer be necessary in a future tool update.
Prerequisites
- Own a VOD service (at least the free VOD space with the Video Streaming service)
- Own a Video Streaming service in the same organization and managed by the same account
Live Streaming a VOD Playlist
Building the playlist from a few imported videos
Import the videos to the VOD space:
- Log in to the Infomaniak Manager (manager.infomaniak.com) from a web browser like Brave or Edge
- Click on the icon at the top right of the interface (or navigate through the left side menu, for example)
- Choose VOD/AOD (Streaming universe)
- Click on the name of the relevant object in the displayed table
- Click the Select button (in the Quick Import section)
Once the videos are imported:
- Click on Media in the left side menu
- Click on Playlists / WebTV in the left side menu
- Click the button to add a new playlist
- Name the playlist and determine if it should be automatic (linked to a folder) or manual
- Choose the folder or specific videos to use for building the playlist
- Click the Create live button
- Choose the Video Streaming stream that should broadcast the playlist and adjust your preferences:
This guide provides instructions for securing a video streaming with a unique key (hash).
This method offers the highest level of protection and allows, for example, restricting your broadcasts to a member area requiring authentication. Since the way to generate this code is specific to each site, it will be necessary to implement the required PHP functions and adapt your player integration code accordingly.
Restriction by Unique Key (Hash)
For this:
- Log in to the Infomaniak Manager (manager.infomaniak.com) from a web browser like Brave or Edge
- Click on the icon in the top right corner of the interface (or navigate through the left side menu, for example)
- Choose Video Streaming (Streaming universe)
- Click on the name of the relevant object in the displayed table
- Click on Settings in the left side menu
- Click on Restrictions in the left side menu
- In the Restriction by Unique Hash tab
Operation of Restrictions
This method requires retrieving information related to the configuration of your stream and the connecting user.
Firstly, it is necessary to define a password (a key) at the administrative console level. As soon as this key is added, connected viewers and those attempting to view your stream will be instantly blocked.
Here is the principle to follow to authorize access to your stream:
- Design your own authentication system (for example, a member area)
- Take the password configured above in our console
- Retrieve the IP addresses of users via
$_SERVER["REMOTE_ADDR"]
for example - Take the identifier of the stream to target
- Retrieve the current date and time (without minutes and seconds)
These elements will then be hashed by the code provided in the Manager to generate a unique token specific to each user, which will be transmitted to the stream at the time of loading. The streaming platform will then check the validity of the hash to authorize or reject the connection.
Important Remarks
- To ensure the security of access to the stream, the validity of each token is limited in time
- It is important to disable the cache on the pages that allow access to the stream; indeed, if the token generation is cached, other users will attempt to authenticate with someone else's hash, causing their rejection even if they have permission to consume the stream
Under construction
This guide explains how to record or archive all your broadcasts, which can be useful for creating TV replays or to view videos recorded by surveillance cameras, for example.
Enabling or disabling automatic live recording
To activate this option:
- Open the Manager (manager.infomaniak.com)
- Go to Video streaming
- Click the stream concerned
- Enable live recording via the stream dashboard
Once this feature has been enabled, the stream will be automatically and perpetually recorded from the time that it is sent to (or pulled by) the Infomaniak platform. Therefore, we recommend you remain vigilant over your FTP space, which could quickly become saturated. If necessary, you can also manually schedule recordings via the scheduling tool.
How automatic recording works
Once this option has been enabled, an mp4 file will be automatically generated after each broadcast, which will be transferred to the VOD or FTP space you have configured.
Important information:
- A broadcast is defined as the time between the connection and disconnection to the video encoder.
- Recording quality: in the case of a multi-bitrate stream, the maximum source quality will be maintained.
- Limitation of file size: in the case of continuous broadcast, you can define the maximum duration of each mp4 file. This option allows you to avoid generating files that are too big and to ensure that your archives are saved in the FTP or VOD space of your choice. Once the duration is reached, the recording is automatically stopped and then sent by FTP and a new recording is started.
Customizing the names of recordings
To enable you to easily identify and classify your archives, the name of the recordings is dynamically customizable using parameters specified between curly brackets.
E.g.: template_{stream_id}_{date|format:YYYY-MM-dd_hh:mm:ss}_{fragment_id|from:1|prefix:fragment_(|suffix:)}.{extension}
- stream_id // represents the stream identifier in the form of a chain of characters.
- date | format: ISO 8601 // date of the recording.
- time | format: ISO 8601 // time of the recording.
- datetime | format: ISO 8601 // date and time of the recording.
- fragment_id | from: number | prefix: string | suffix: string // number of the fragment in case the recording is fragmented with the possibility of providing a prefix and/or suffix. Each fragment will be incremented, "from" indicating the first reference fragment.
- extension // final extension of the file.
These settings are optional and their order is totally free. They can be used as many times as you wish. If you provide the same option several times, only the last will be taken into account. Any non-recognized option will simply be ignored.
Example 1
Situation: we have two daily programmes, the first starts at 10:00 and the second at 20:05. By configuring file naming in this way: template_{date|format:hh:mm:ss}, we obtain the following file names:
For 5 December 2019:
- The first recording at 10:00 will be called: template-10:00:00.mp4
- The second recording at 20:05 will be called: template-20:05:00.mp4
For 6 December 2019:
- The first recording at 10:00 will be called: template-10:00:00.mp4
The recording of the previous day will be overwritten and replaced by this one. - The second recording at 20:05 will be called: template-20:05:00.mp4
The recording of the previous day will be overwritten and replaced by this one. - Etc.
This logic can be particularly useful for a looped recording system, e.g. for a surveillance video. The user will only retrieve the video in case of need, avoiding the necessity to archive a potentially infinite number of videos that could saturate the FTP space.
Exemple 2
Situation: this time we have a perpetual recording, 24/7, with a file duration limited to 360 minutes. By configuring file naming in this way: template_{date|format:YYYY-MM-dd}_{fragment_id|from:1|prefix:fragment_(|suffix:)}.{extension}, we obtain the following file names:
- The first file of the day at 0:00 will be named: template_2019-02-05.mp4
- The second file of the day at 6:00 will be named: template_2019-02-05_fragment(1).mp4
- The third file of the day at 12:00 will be named: template_2019-02-05_fragment(2).mp4
- The fourth file of the day at 18:00 will be named: template_2019-02-05_fragment(3).mp4
By configuring file naming in this way: template_{date|format:YYYY-MM-dd}_{fragment_id|from:0|prefix:fragment_(|suffix:)}.{extension}, we obtain the following file names:
- The first file of the day at 0:00 will be named: template_2019-02-05_fragment(0).mp4
- The second file of the day at 6:00 will be named: template_2019-02-05_fragment(1).mp4
- The third file of the day at 12:00 will be named: template_2019-02-05_fragment(2).mp4
- The fourth file of the day at 18:00 will be named: template_2019-02-05_fragment(3).mp4
If you wish to avoid finding your TV or video stream on other websites that you do not own, you can restrict the broadcast to your own website and prohibit any integration elsewhere.
Important: this protection does not prevent the integration of a stream via an HTML iframe tag. We recommend you protect it with a unique hash code for a better level of security.
Restriction by domain
- Open the Manager (manager.infomaniak.com)
- Go to Video streaming
- Go to the Settings of the stream concerned
- Go to Restrictions and then to the Restriction by domain tab
- Add the restriction by domain with your own internet site as well as the sites authorized to download the stream
Restriction by token (recommended)
Please follow this guide.
This guide explains how to customise a player with the image of your choice if you have added restrictions to your themes or in the following cases:
- Scheduled interruption of the broadcast (possibility to display a countdown before resuming the broadcast)
- Geographical restrictions
- Other restrictions (blocking via IP, domain(s), token, etc.)
Customising the thumbnails of a player
- open the Manager (manager.infomaniak.com)
- go to Video streaming
- click on the stream concerned
- click on Integration then on Players in the menu to the left
- click on the player to be customised
- go to the Thumbnails tab
- customise the thumbnails of your choice
This guide explains how to configure the Infomaniak encoder.
1. Default access and password configuration
Once you have connected the encoder, it will be accessible on your network at the following address: 192.168.1.168
Configuration is made via an Internet browser at this address: http://192.168.1.168
- User name: admin
- Password: admin
First, we ask you to define a strong password:
2. Network configuration
If access at the 192.168.1.168 address suits you, you can go directly to step 3.
Otherwise, if your network is configured in DHCP or if you wish to define a different IP address, the System > Network page enables you to define the access settings. It may be necessary to contact your network administrator to carry out the various settings and authorize this new device for your firewall.
3. Configuring the main stream
3.1 In case a single stream is sent:
This is a case of:
- Transcoding in the Cloud => see point (1) and (1.3) in this guide
- or Mono-bitrate => see point (3) in this guide
Please adjust the following settings:
- The bitrate (kbit) and resolution (encoded size) must be adjusted according to your needs.
- RTMP PUBLISH URL corresponds to the publication URL indicated in your Manager in the stream configuration:
The encoder does not enable you to enter a stream key. It is thus necessary to concatenate this latter with the URL.
Example: rtmp://stream.vprimary.infomaniak.com/livecast?key=XXXXXX/stream
The “stream” values and the password (key=XXXXXX) must be replaced by your personal data.
3.2 In case several streams are sent:
To find out more about this case, please refer to point (2) and (2.2) of this guide.
In case several streams are sent, you will be in multi-bitrate mode with n streams encoded on the encoder.
The Substream1, Substream2 and Substream3 sub-menus enable you to configure the encoding of up to 3 additional streams:
3.3 Audio configuration:
Audio input will need to be adjusted once the connections are made. The bitrate can also be adjusted according to the type of content. We recommend you use the following codec: 128 Kbps AAC, at 44100 Hz.
It correlates with the feed cuts if you establish one (or several in a row, by managing the overlap), since this timer indicates the end of the scheduled outage.
Note: it takes 2 minutes for a scheduled outage to be reflected in the countdown.