Support Garage

Documentation, APIs & Tutorials

Getting Started With HDFVR

1. Installing HDFVR

Download from your client/trial area the HDFVR archive (hdfvr.zip) and extract it somewhere on your computer.

1.1 Installing the hdfvr app on the media server:

On Red5 On AMS On Wowza Streaming Engine

1) Copy the Red5/hdfvr folder (from the hdfvr.zip archive) to your Red5/webapps folder, provide 777 permissions.

2) Restart Red5.

Copy the AMS/hdfvr folder (from the hdfvr.zip archive) to your AMS/applications folder.

If you're using AMS hosting create a new application/folder named hdfvr and in it upload the contents of the AMS/hdfvr folder (from the hdfvr.zip archive).

 

1) Copy the applications, conf and lib folders (you will find them in the Wowza folder from the hdfvr.zip archive) inside the Wowza Streaming Engine installation folder.

2) Restart Wowza.

3) Wowza Streaming Engine 4 only: Starting with Wowza Media Server version: Wowza Streaming Engine 4.0, a new GUI has been added that allows you to control the server and individual applications. This can be accessed via browser at the following link http://WOWZA_SERVER_ADDRESS:8088/enginemanager/. You also don't need to restart the server each time you update your application's files. You can restart the application only.

By default this version of Wowza Media Server comes with the default stream prefix mp4. This needs to be changed to flv. Here's how:

  1. Go to http://WOWZA_SERVER_ADDRESS:8088/enginemanager/
  2. From the top menu click the [Server] page
  3. In Server Setup click Edit
  4. Change Default Stream Prefix from mp4 to flv
  5. Save

 

1.2 Installing HDFVR on your web site:

  1. Copy the contents of Files to upload to your web site from the received archive in a folder on your web site
  2. Edit avc_settings.php (or avc_settings.asp) with a text editor and set the value of $config['connectionstring'] to the correct connection string for your new media server app, here is how it should look:
    • $config['connectionstring']='rtmp://mymediaserver.com/hdfvr/_definst_';
    • $config['connectionstring']='rtmp://my.media.server.ip/hdfvr/_definst_';
    • $config['connectionstring']='rtmp://localhost/hdfvr/_definst_';
  3. Go to http://www.yoursite.com/your_new_video_recorder/videorecorder.html , you will be asked for your license key which you can obtain from the customer area on nusofthq.com! (Use videorecorder-hd.html to record a HD video!

 

1.3. What we need if you want us to perform the installation

We offer a free installation with every purchase and an Additional Installation Service.

Here's what we need to install HDFVR for you:

  1. FTP access to the web site (or folder) where HDFVR will be installed
  2. If you've use a HDFVR integration kit (like the Video Profiles For Social Engine 4 Module ) we will need admin acess to the admin area of your CMS (SocialEngine, etc.).
  3. root ssh access to the vps/dedicated server where the media server (Red5, AMS or Wowza Streaming Engine) is installed (on Windows servers Remote Desktop access will do)

Please send the data to support@nusofthq.com.

HDFVR installations generally take 6-24 hours if all the data above is sent correct and complete.

 

1.4. What we need if you want us to install Red5, AMS or Wowza Streaming Engine for you

You can opt for our VPS Media Server Hosting Plans (starting from $14.99/mo) or, if you want us to handle the installation of the media server on your own server, you can order the Media Sever installation service for $99/one time fee.

Here's what we need to install the media server for you:

  1. root ssh access to the vps/dedicated server where you want the media server (Red5, AMS or Wowza) to be installed if have a Linux Server, or Remote Desktop if you have a Windows server.
  2. If you want AMS or Wowza installed, we will also need the licence key you received after purchasing them.

Please send the data to support@nusofthq.com.

Media server installations generally take 6-24 hours if all the data above is sent correct and complete.

1.5. Requirements

1.5.1. A website.

Any shared hosting account or vps/dedicated server will do as long as it supports php, asp or .NET(aspx).

1.5.2. A media server, you have 2 options:

  • OPTION1: Your Own Media Server: a dedicated or VPS server with one of these media servers installed:

    We can install and configure Red5, AMS or Wowza Streaming Engine for you, just purchase the Pro Media Server Installation Service together with HDFVR from the purchase page.

  • OPTION2: Media Server Hosted By Us: We're offering VPS servers with root SSH access and Red5 1.0.7 preinstalled starting at $14.99/mo. More details on the media server hosting page.

What is a media server?

Just as web servers (Apache is a web server) serve static HTML pages and images, media servers (like AMS, Red5 and Wowza) can record and deliver video/audio content to Flash Player applications (like HDFVR).

About AMS

The first media server was done by Adobe and it was called Flash Communication Server. It is now called Flash Media Interactive Server and it costs around $4500 to buy in the US (we know! It's a lot!). It has good documentation and there are a lot of articles and books explaining all things AMS.

About Red5

Red5 is a free and open source alternative to AMS. Red5 is developed in Java.

About Wowza Streaming Engine

Wowza is a great commercial alternative to AMS and Red5.

1.5.3 Your website users will need a modern browser with Flash Player 11.1 or later.

Build 496 of HDFVR introduced H.264 video encoding which means that your users will need Flash Player 11.1 or above to run HDFVR.

(Modern) Browser Requirements

  • Windows: Internet Explorer 7.0 and later, Mozilla Firefox 4.0 and later, Google Chrome, Safari 5.0 and later, Opera 11
  • macOS: Safari 5.0 and later, Mozilla Firefox 4.0 and later, Google Chrome, Opera 11
  • Linux: Mozilla Firefox 4.0 and later, Google Chrome

2. Where can I find the resulting .flv/.mp4/.mov files?

When recording from desktop

  • on Red5 in Red5/webapps/hdfvr/streams/_definst_
  • on AMS in AMS/applications/hdfvr/streams/_definst_
  • on Wowza Streaming Engine in Wowza/content

By default all the recordings will be saved on the media server even tough the user has not pressed [SAVE]! To keep only the recordings for which the user has pressed the [Save] button edit avc_settings.xxx and change the deleteUnsavedFlv var to true.

When recording from mobile devices

The resulting .mp4/.mov files are saved by default on the webserver in the HDFVR installation directory inside the mobileRecordings folder.

3. How can I play back the resulting FLV files?

There are multiple ways in which you can playback the recordings:

Both JW FLV Media Player and Flowplayer support both streaming and progressive download!

Important to note!

The hdfvr app on the media server will have domain limitations, so if you are trying to stream using one of the players above from an unlicensed domain it will not work. The one exception to this rule is the Wowza Media Server which can stream with no domain limit using the hdfvr_play app. In any other case the the player will have to be hosted on the HDFVR licensed domains and should connect to the hdfvr app

4. Where can I find the snapshots?

After recording your first movie look for a new folder called snapshots on your web server in the folder where you installed HDFVR. The .jpg filename corresponds to the .flv filename on the media server.

By default a snapshot of the recording is taken at second 5 and it is saved/uploaded to the web server when you press the [Save] button (or when the video finishes streaming/uploading to the media server if hideSaveButton=1 in avc_settings.xxx)!

You can modify the second at which the snapshot is taken by editing avc_settings.xxx and changing the value of the snapshotSec variable!

You can stop HDFVR from taking snapshots by editing avc_settings.xxx and changing the value of the snapshotEnable variable!

5. Switching between php, asp and .NET

By default HDFVR attempts to use the php files (avc_settings.php, save_video_to_db.php, jpg_encoder_download.php).

To force HDFVR to use the .asp or .aspx ones you need to:

  1. Edit VideoRecorder.html (or VideoRecorder-hd.html) with a text editor.
  2. Find the following line of code sscode: "php"
  3. Replace "php" with "aspx" or "asp"
  4. Save and exit

hdfvr sscode

Important note: Build 505 of HDFVR ships only with php and asp files. For the .NET(aspx) ones download them from this blog post: HDFVR and .NET .

6. Using the same media server for multiple installations

Here's how to use the same media server for 2 or more HDFVR installations.

The need might arise if:

  • you want to differentiate between your production, development and localhost installations.
  • you bought 2 licenses of HDFVR and you have 2 different license keys but just one media server

You can connect 2 ore more HDFVR installations to the same hdfvr app on the media server.

To do it just change the last part of the $config['connectionstring'] value in avc_settings.xxx like this:

  • for the 1st HDFVR copy leave the default:
    rtmp://mymediaserver.com/hdfvr/_definst_
  • for the 2nd and next HDFVR copies change the last part, for example:
    rtmp://mymediaserver.com/hdfvr/siteb

Both HDFVR copies will ask for the license key when recording the 1st video

On Red5 and AMS each site will record to a different folder:

  • the video files for the 1st copy will be in streams/_definst_
  • the video files for the 2nd copy will be in streams/siteb

But on Wowza they'll be grouped together:

  • the video files for both sites will be in Wowza/content

7. How to change where the media server saves the video files

Wowza:

  1. edit conf\hdfvr\Application.xml
  2. change the value of the <StorageDir> tag:
    <StorageDir>${com.wowza.wms.AppHome}/content</StorageDir> (this is the default)
  3. save and restart Wowza (you can restart just the application if you are using Wowza Streaming Engine 4)

For example you could change the path to a folder inside your public Apache web server folder like this:

<StorageDir>/usr/sites/site.com/public_html/recorded_videos/</StorageDir>

AMS:

  1. copy Application.xml from Adobe Media Server\conf\_defaultRoot_\_defaultVHost_\ to Adobe Media Server\applications\hdfvr\
  2. edit hdfvr\Application.xml and change the value of the <StorageDir> tag: <StorageDir></StorageDir> (by default it's empty)
  3. save and
    1. restart AMS or
    2. reload the hdfvr app using the AMS Management Console.

For example you could change the path to a folder inside your public Apache web server folder like this :

<StorageDir>/usr/sites/site.com/public_html/recorded_videos/</StorageDir>

Red5:

There's no way right now.

8. How to change/reset the license key

You will have to reset the license key (delete the old one) if you want to:

  1. upgrade from the SD to the HD version (a new key is issued)
  2. change the domain name which you want to us the HDFVR (a new key is issued)
  3. any license key error

Here's how to do it:

On AMS:

  1. delete this file:Adobe Media Server\applications\hdfvr\sharedobjects\_definst_\licensekey.fso
  2. restart AMS or reload the hdfvr app using the AMS Management Console .
  3. when trying to record you will be asked for the license key again

On Red5:

  1. delete this file:Red5\webapps\hdfvr\persistence\SharedObject\_definst_\licensekey.red5
  2. restart Red5
  3. when trying to record you will be asked for the license key again

On Wowza Streaming Engine:

  1. delete this file:Wowza Media Server 2\applications\hdfvr\sharedobjects\_definst_\licensekey.rso
  2. restart Wowza
  3. when trying to record you will be asked for the license key again

9. How to translate HDFVR

HDFVR holds all the texts used in the UI in an external text xml file: translations/en.xml

To change a word/phrase or translate the entire HDFVR user interface just edit that file with a text editor, search for the text you want to translate it and change it!

Now save the new .xml file and upload it to your hdfvr installation folder on your web server!

If the old translation shows up clear your browser cache!

10. HDFVR Design & Size

Design

Starting with HDFVR 2.0 there are 5 variables in avc_settings that control the looks of HDFVR: backgroundColor, menuColor, radiusCorner and the newly added options normalColor, overColor.

Here are the variables and explanations from avc_settings.php:

Here's an image explaining what controls what:

hdfvr design options

Starting with HDFVR 2.0 the radiusCorner setting will also affect the button tooltips.

Size

The video recorder is actually a swf file: VideoRecorder.swf embedded in a html file: VideoRecorder.html .

To change the size of HDFVR you need to edit the html file and look for the width and height values of the embed and object tags. You can use fixed values like this: 300px or relative values like this: 100% .

The width and height is specified in 2 places in the HTML file (once for IE, the second time for Firefox, Chrome, etc...) so make sure you change in both.

11. Recording high quality video over slow connections with Red5

Flash Player prioritizes the audio packets when streaming audio/video data to a media server over slow connections or at a data rate more than ~1Mbit/s which is the max supported by Flash Player when broadcasting (Flash Player 11.3 -released on the 8th of June 2012- removes the internal streaming/uploading limit of FP.)

The media server needs to account for this by waiting more for the video packets and sort them together with the audio packets before writing the data to disk (.flv file). Wowza and AMS both wait longer for the video data and rearrange the packets.

Red5 0.8 had no such mechanism thus recording high quality video over slow connections resulted in low quality/scrambled video files (just audio, all video at the end).

Red5 0.9 had audio video recording totally broken.

Red5 1.0 RC1 had a new delayed write mechanism - controlled by <property name="queueThreshold" value="33"/> in Red5/conf/red5-common.xml - that waits for the audio and video data and rearranges the packets before writing them to disk. The queueThreshold value measures rtmp messages/packets.

On our tests the structural and video quality of the resulting .flv files was much more better than with Red5 0.8, but final results have been mixed. It seemed bigger values worked better for recording huge ammounts of video+audio data (like a HD video recording) but didn't work as well for smaller videos like a 320x240 recording.

Red5 1.0 final, 1.0.1 and 1.0.2 had the delayed write mechanism totally broken. With it turned on, over slow connections, Red5 was producing .flv files with only 1 or 2 video keyframes. When playing back such .flv files the video would get stuck from the 1st second and playback would continue only with audio. Using yamdi to extract the keyframe data confirmed that the .flv files were lacking video keyframes.

Finally a Red5 version with recording fixed:
red5-server-1.0.3-SNAPSHOT_with_recording_fixed.zip (Download)

This is a special build compiled by us. It contains an important patch for the recording process and a queue treshold of 120 (you can change it from red5.properties, it's called fileconsumer.queue.size). Our own HDFVR demo is using this build of Red5.

For this version of Red5 you will need HDFVR 1.1 (build 609 ) or newer. Older versions do not include the hdfvr folder app for Red5 1.0.2 or newer

After Red5 1.0.2 was released, seeing that the delayed write mechanism was still not fixed, we spent several days identifying the bug in Red5's Java code, creating and testing a patch. We sent our patch to the Red5 team and the patch was commited to the Red5 source code on GitHub and will also be part of the next version of Red5. Until then you can download our own Red5 build with the patch applied from the link above.

fileconsumer.queue.size in red5.properties (queueThreshold)
By solving the delayed write bug in Red5 we've understood better how the fileconsumer.queue.size (queueThreshold) setting is used.

When the delayed write mechanism is turned on (it is by default) Red5 writes the queued audio and video data to disk in .flv files in 2 cases:

  • when a video packet kicks in (it writes it together with all the audio packets up to that point)
  • when the queueThreshold limit is reached with unwritten audio packets

We've seen audio packets build up at the rate of about 60/minute when recording HD video (1280x720) so as a general rule fileconsumer.queue.size setting in red5.properties should be 60 times the max number of minutes your recordings will be. The number should be lower if you're recording lower resolution video. Our build ships with 120 as the default value which should be enough for recording 2 minutes of HD video.

13. On video & audio quality:

Available video & audio codecs

Flash applications (including HDFVR) can currently encode sound with these 2 codecs:

  • NellyMoser's ASAO (older, used by default by HDFVR because it is easily converted by ffmpeg to mp3)
  • open source Speex (newer, speech oriented, uses less bandwidth, but its not decoded by default by ffmpeg)

and they can encode video with:

  • H.264
  • Sorenson's Spark H.263

HDFVR quality profile files

In the installation folder of HDFVR you will find a folder named audio_video_quality_profiles. It contains several .xml files, we call these .xml files audio video quality profiles.

Each such quality profile file contains the settings (resolution, frames per second, picture and sound quality, audio codec) used to encode the video/audio data that's coming from your computer's webcam and microphone.

HDFVR ships with several such profile files that you can use out of the box, they are divided in two:

  • a set with 4:3 resolutions
  • a set with 16:9 (wide) resolutions, they're in the wide folder

How to tell HDFVR what quality profile file to use

There are 2 ways you can tell HDFVR to use a certain quality profile file:

  • (default) Through the qualityurl flash var variable. You will find it in the HTML:
    quality url flash var
  • Through the qualityurl variable inside avc_settings.php (or avc_settings.asp). Has higher priority than the qualityurl flash var. If this one is set the qualityurl flash var is ignored.
    qualityurl var in avc_settings.php

You can also make your own quality profiles or edit the existing ones.

How to edit existing quality profile files

Each of the quality profile files has the exact same XML structure:

To edit a quality profile file open it in Notepad (or any other text editor), change the variable/value that you want to change and save the file back to the web server. Now reload HDFVR in the browser and you should see the changes in effect.

Each node/value pair in the quality profile files explained:

  • Video settings
    • <bytes> This is the maximum amount of bytes that the video (not audio) can consume per second. If it is set to 0, the video stream from the user to the media server will consume as much bandwidth as possible to maintain the picture quality. Multiply by 8 to get the value in bits.
    • <q> This is the picture quality. If set to 0 it will use as much quality as possible, without exceeding the <bytes> value. Maximum is 100 but that will consume EXCESSIVE bandwidth. A value between 85-95 will produce really good picture quality!
    • <fps> This defines the video frame rate. 10, 15, 30 fps, etc... . Some old web cams can only capture up to 15fps.
    • <kfps> Key frames. This tells HDFVR that every <kfps> frames a full frame will be sent to the media server . The rest of the frames contain just the changes from the previous frame. This settings is not used by HDFRV as it creates enough keyframes by default.
    • <w> The desired width of the captured video in pixels
    • <h> The desired height of the captured video in pixels
    • <vcodec> The desired codec used to encode the video

      Flash Player 6 (released in 2002) and above supports encodingf video with the Sorenson Spark codec.
      Flash Player 11 (released in 2011) and above supports encoding video with the H.264 codec. This is the same codec used for BluRay movies.

      Posible values:
      sorenson : use this value to encode video using the Sorenson Spark video codec regardless of the media server used
      h264_f : use this value to encode video with H.264 codec when using Adobe Media Server
      h264_w : use this value to encode video with H.264 codec when using Wowza Streaming Engine
      h264_w_t : when using Wowza Streaming Engine + Wowza Transcoder addon, see this blog post.
      h264_r : use this value to encode video with H.264 codec when using Red5

  • Audio settings:
    • <snd>The snd tag controls the quality/bandwidth of audio.
      Higher quality sound will use more bandwidth. Flash Player supports encoding sount in 2 codecs: Nellymoser's Asao and Speex.
      Speex is newer, better and open source. That's why it is used by default. Speex has been introduced in Flash Player 10.

      Possible values:
      44 : NellyMoser, highest quality
      22 : NellyMoser, medium high quality
      11 : NellyMoser, medium low quality
      8 : NellyMoser, low quality
      5 : NellyMoser, lowest quality
      speex10 : Speex, highest quality, uses 42.2kbits/s of bandwidth
      speex9 : 34.2kbits/s
      speex8 : 27.8kbits/s
      speex7 : 23.8kbits/s
      speex6 : Speex, default value, uses 20.6kbits/s of bandwidth
      speex5 : 16.8kbits/s
      speex4 : 12.8kbits/s
      speex3 : Speex, low quality, lowest usable quality, uses 9.80kbits/s
      speex2 : 7.75kbits/s
      speex1 : 5.75kbits/s
      speex0 : Speex, lowest quality, not really usable, uses 3.95kbits/s
    • <sndSilencelevel> Takes values from 0 to 100. Flash Player will consider any sound that is lower than the value of this tag as "silence" and thus will not send any data to the media server. Use 100 if you want to never send audio to the media server. Use 0 if you always want to send to the media server whatever the mic captures (even noise). We recommend using 0 since if you use the default (10) Flash Player will stop broadcasting sound when you stop speaking. Even though this seems like a cool feature that cuts bandwidth usage in reality you'll get the feeling that you're bneeing cut off.
  • Misc settings:
    • <nm> This is the name of the connection type. The value of this tag is not used in HDFVR.
    • <df> If set to 1, this will be the connection type that will be used by default. The value of this tag is not used in HDFVR.

14. How to record MP4 files with AAC sound and h.264 video using HDFVR, Wowza Streaming Engine and the Wowza Transcoder Add on

Wowza Streaming Engine (Wowza 4.0) has streamlined the the process of recording MP4 files with H.264 video and AAC audio. Here are the steps needed to be done in order to achieve this:

  1. On the webserver in the HDFVR installation folder inside the video quality profile of your choice set: <vcodec> tag to h264_w_t and <snd> tag to speex10
  2. On the media server open up conf/hdfvr/Application.xml
  3. Set the <StreamType> tag to live-record
  4. Uncomment <LiveStreamPacketizers>
  5. Set the <LiveStreamTranscoder> tag to transcoder
  6. Save and exit
  7. Restart the HDFVR application from the Wowza Streaming Manager

Important! The final MP4 file will not be created when the user presses STOP in HDFVR. It will only be created when:

  • the client records another video (re-records)
  • OR
  • the client disconnects
  • If you are using an older version up to Wowza 3.6 follow the details in the blog post: http://nusofthq.com/blog/recording-mp4-filesh-264-and-aac-with-hdfvr-and-wowza/

    Known issue: The pause while recording functionality of HDFVR will not work in combination with the transcoder. Each time the recording is paused, the transcoder will interpret that a new video has been recorded and that chunk of the recording will be converted to MP4. So the final output will be a FLV file that contains the whole recording and 2 or more MP4 files depending on how many times the recording was paused which combined make up the full recording.

    15. Using JW Media Player 5.1 To Stream The Video Files

    You can use HDFVR to record video files on your media server, but the final purpose is to play them on your website. The following guide will show you how to play the video files from the media server, trough rtmp streaming. We will use JW Media Player 5.1 which is the last version as of today.

    1. First of all, you have to download JW Player.

    2. Then make sure you read the documentation on RTMP Streaming from the JW Player website.

    3. The next step will be to create a folder on your website where you will copy JW Player files. Make sure you're installing the player on your HDFVR licensed domain, otherwsie JW Media Player will not be able to connect to the hdfvr app on your media server.

    After all files have been uploaded, you have to include the JW Player.js script in the page you want to include the JW Player. To do that copy the following line to the top of the HTML page:

    4. Now let's embed the JW Player in the HTML page. Copy the code below and paste it in the HTML page:

    5. Replace the path to the player ( 'flashplayer': 'path_to_player.swf', )

    6. Repalce the path to the media server app with the path to the hdfvr app on your media server('streamer': 'rtmp://your_media_server_host/hdfvr/_definst_',)

    7. Replace the path to the video file to be played ('file': 'video.flv')

    You're done, load the HTML file in the browser and the video should start playing.

    Here's an online demo of JW Media Player playing a video recorded with HDFVR - RTMP Streaming with JW Player Demo

    Here's the configuration we used: jw media player rtmp configuration

    Build 508 Note: When using build 508 of HDFVR and Wowza Streaming Engine, make sure you play through the hdfvr_play app, not through the main hdfvr app.

    Your rtmp path should contain the hdfvr_play app like this rtmp://your_media_server_host/hdfvr_play/_definst_ .

    For JWPlayer 6, follow this forum thread.

    18. Importing the HDFVR source files to Flash Builder

    1. Download the hdfvr_sources.zip archive from your client area (once you purchase it)
    2. Start Flash Builder
    3. File - Import Flash Builder Project
    4. Browse - Select the hdfvr_sources.zip archive - Open
    5. Finish

    Make sure you have Flex 4.6.0 SDK installed.

    Also important to note, the sources are available only in Flash Builder Project (.project) format and not in Flash Professional .fla format.

    19. Converting recordings using integrated FFmpeg with Red5 or Wowza Streaming Engine

    Starting with HDFVR 1.3 (build 707) you can now convert FLV files to MP4 format using the integrated call to FFmpeg (Red5 and Wowza only).

    Setting it up

    Here is what you need to do in order to achieve this:

    1. Download the latest FFmpeg build for Linux or Windows depending on your operating system and Unarchive FFmpeg in:
      • On Wowza
        WOWZA_INSTALLATION_PATH/content
      • on Red5 RED_INSTALLATION_PATH/webapps/hdfvr/streams/_definst_
    2. Now on the client side, make sure that enableFFMPEGConverting is set to 1 in avc_settings.php

    Optimising the conversion

    By default HDFVR ships with Sorenson set as the video codec. We recommend changing to H.264 so that the video data does not get reconverted which will drastically lower the conversion time to just a couple of seconds. The ffmpeg command setting will have to be set like so:
    ffmpegCommand = "ffmpeg -i [THE_INPUT_FLV_FILE] -c:v copy [THE_OUTPUT_MP4_FILE]". This specifies to FFmpeg not to re-encode with H.264 but just to copy it, because we already have the video encoded with H.264, and to encode just the audio with AAC.

    Automatic API call

    After each recording has finished converting a new JS API onFFMPEGConversionFinished is called on the client side. However this is not very reliable because the client may close the browser page.

    20. Accessing the videos via http from the hdfvr/streams/_definst_ folder (Red5 only)

    When recording using the Red5 media server the video files are created in Red5/webapps/hdfvr/streams/_definst_. Starting with HDFVR 1.3 (build 707) the streams folder can be exposed - via Red5's Tomcat web server - to be accessible via http (from the browser) at http://RED5_SERVER_ADDRESS:5080/hdfvr/streams/

    This will help you greatly if you want to:

    • Play the files through HTML5 or progressive download
    • Download the files locally
    • Move the files to a different server

    You will need to do the following steps:

    1. Go to Red5/webapps/hdfvr/WEB-INF/ on your media server.
    2. Open web.xml with a text editor.
    3. Delete the active <security-constraint> tag along with it's contents.
    4. Uncomment the commented <security-constraint> tag.
    5. On Red5 1.0.6+ only: you'll have to add this code to the web.xml file to enable directory listings. Red5 1.0.6+ ships with Tomcat 8 and directory listings are not enabled by default.
    6. Save and exit.
    7. Restart Red5.

    With directory listing enabled, if you now go to http://RED5_SERVER_ADDRESS:5080/hdfvr/streams/ in your web browser, you will see a list of all the video files. Clicking them will download them or play them in the browser.
    Red5 listing HDFVR's streams folder contents

    This open directory listing can be a security issue (you don't want to expose all the recorded videos to anyone snooping around).

    To turn off the directory listing on Red5 1.0.3-1.0.5 do the following:

    1. Go to Red5/conf/ on your media server.
    2. Open web.xml with a text editor.
    3. Search for this code:
              <init-param>
                  <param-name>listings</param-name>
                  <param-value>true</param-value>
              </init-param>
    4. Set the listings value to false like this:
              <init-param>
                  <param-name>listings</param-name>
                  <param-value>false</param-value>
              </init-param>
    5. Save and exit.
    6. Restart Red5.

    Directory listing will now be turned off.
    Red5 not listing the contents of HDFVR's streams folder

    You will still be able to access the file and download it or play it if you know it's name (absolute http path).

    21. CSRF for Ruby on Rails

    Starting with HDFVR 2.0 we've implemented the variable authenticity_token that can be sent only via flash vars. It is used only for Ruby on Rails implementations where it is needed to validate POST requests for the CSRF mechanism. This variable is sent back to save_video_to_db and jpg_encoder_download files.

    22. Rotation metadata in mobile videos

    Video files produced on mobile devices carry with them a lot of metadata. One of such is the Rotation metadata whose value is represented in degrees such as 0, 90, 180 and 270.

    Here are the values for each device orientation for both iOS and Android:

    Browsers such as Chrome and Safari use this metadata to display the video with the correct orientation. Other browsers like Firefox don't interpret this metadata thus will play videos only in landscape mode, resulting in faulty orientation upon playback.

    There are a number of tools you can use to inspect the rotation metadata: fluent-ffmpeg, ExifTool and MediaInfo.

    Get personalized help

    Customers with an active Support & Updates Plan can submit support requests to our knowledgeable techs via the client area.

    Enter client area