OSMP+ User Guide
OSMP+ User Guide
VisualOn, Inc.
June, 2016
20160630
VisualOn
Copyright/Confidentiality Notice
© 2016 VisualOn, Inc. All rights reserved.
VisualOn Trademarks
VisualOn® OnStream®
Information in this document is subject to change without notice and does not
represent a commitment on the part of VisualOn. Except as may be explicitly set
forth in an agreement between VisualOn and its customer, VisualOn does not: (a)
make, and expressly disclaims, any representations or warranties as to the
completeness, accuracy or usefulness of the information contained in this
document; (b) warrant that use of such information will not infringe any third party
rights; (c) assume any liability for damages or costs of any kind that may result from
use of such information.
Contents
Chapter 1 Introduction 11
1.1 OSMP+ overview.............................................................................................12
1.1.1 OSMP+ benefits ..................................................................................13
1.1.2 OSMP+ SDK ..............................................................................................13
1.2 Supported operating system and web browser ........................................14
1.3 Terminology .....................................................................................................15
1.4 Features and codecs.....................................................................................16
1.4.2 Streaming .................................................................................................16
1.4.2 Adaptive streaming ...............................................................................19
1.4.3 Local parsers ...........................................................................................24
1.4.4 Codec ......................................................................................................26
1.4.5 Hardware acceleration .........................................................................31
1.4.6 Multiple audio tracks ..............................................................................37
1.4.7 Closed Captions .....................................................................................37
1.4.8 Subtitles ....................................................................................................39
1.4.9 FCC compliance ....................................................................................41
1.4.10 Zoom modes .........................................................................................44
1.4.11 Download Manager ............................................................................48
1.4.12 DRM ........................................................................................................49
1.4.13 Output Control with VCAS...................................................................49
1.4.14 AirPlay on iOS ........................................................................................50
1.4.15 360 video decoding .............................................................................51
1.4.16 3D playback of 360 video decoding.................................................53
1.4.17 IPv6-only network support ...................................................................53
1.4.18 Render options on Android .................................................................54
Figures
Figure 1. Supported protocols, formats, CPUs, and platforms .................. 12
Figure 2. Progressive Download in OSMP+...................................................17
Figure 3. Progressive Download roles ...........................................................17
Figure 4. Example of white list ........................................................................33
Figure 5. Sample 1: letterbox .........................................................................44
Figure 6. Sample 2: Letterbox ........................................................................45
Figure 7. Sample 1: Pan & Scan ....................................................................45
Figure 8. Sample 2: Pan & Scan ....................................................................46
Figure 9. Example of Fit to Window ...............................................................46
Figure 10. Example of Original Size .................................................................47
Figure 11. Example of Zoom In.........................................................................48
Figure 12. DRM workflow ..................................................................................49
Figure 13. Eclipse IDE Import Dialog ................................................................57
Figure 14. Select the SamplePlayer project ...................................................58
Figure 15. Eclipse IDE Package Explorer.........................................................58
Figure 16. Context Menu for SamplePlayer Project in Eclipse IDE .............. 59
Figure 17. Select Video Render Type ..............................................................62
Figure 18. Set duration for push PD .................................................................62
Figure 19. Select an external subtitle ..............................................................64
Figure 20. Set maximum buffer time ...............................................................64
Figure 21. Available RTSP connection types ..................................................66
Figure 22. Define the port .................................................................................66
Figure 23. Set the entry level ............................................................................67
Figure 24. Set the retry times ............................................................................67
Figure 25. Enable HTTP Verification Information ............................................67
Figure 26. Set the user name and password .................................................68
Figure 27. Set retry times ...................................................................................68
Figure 28. Set the value of Initial Bitrate .........................................................71
Figure 29. Set the lower and upper bound value .........................................72
Figure 30. Enable or disable settings of audio and subtitle ......................... 72
Figure 31. Sample Player with Closed Captions ...........................................77
Tables
Table 1. Supported web browser .................................................................14
Table 2. Supported web browser version....................................................15
Table 3. Terminology ......................................................................................15
Table 4. Supported profiles ...........................................................................27
Table 5. MPEG4 audio object details ..........................................................28
Table 6. Supported MPEG audio layer ........................................................30
Table 7. Output control flags ........................................................................50
Table 8. Subtitle attributes and related APIs ...............................................69
Table 9. Subtitle attributes and related APIs ...............................................92
Table 10. Subtitle attributes and related APIs .............................................135
Table 11. Java libraries ..................................................................................141
Table 12. Header files dependency ............................................................148
Table 13. Header files dependency ............................................................160
Table 14. Bitrate Adaptation related logs ...................................................175
Table 15. Buffer related logs .........................................................................176
Table 16. Content related logs .....................................................................176
Table 17. Controller related logs ..................................................................176
Table 18. DRM related logs ...........................................................................177
Table 19. Hardware codec related logs .....................................................177
Table 20. License related logs ......................................................................178
Table 21. Local file related logs ....................................................................178
Table 22. KPI related logs ..............................................................................179
Table 23. OS source related logs..................................................................179
Table 24. Output control related logs .........................................................179
Chapter 1 Introduction
1.1.1 OSMP+ OSMP+ offers the following benefits when deploying a content delivery
benefits solution:
• Modular and flexible architecture enables easy integration into
content delivery applications and addition of new or custom
protocols.
• Enables development of multimedia players with no
device/OS/protocol dependencies
• Enables delivery of uniform and compelling viewer experiences
across multiple platforms
• Enables the efficient implementation, small memory footprint, and
runtime memory usage
• Enables scalable deployment and single software codebase
• Enables unprecedented performance and reliability across all
targeted devices
• Enables accelerated time to market and lower cost of deployment
and support
1.1.2 OSMP+ SDK The OSMP+ Software Development Kit (SDK) is a development kit to create
a media player on supported devices and supports the following functions:
• Playback of multiple video formats and audio formats to devices with
or without native support
• Playback of live or video on demand (VoD) streaming, progressive
download, and local media sources
• Easy integration with Digital Rights Management (DRM) decryption
engines
• Audio post-processing for third party audio effect plug-ins and
equalizers
• Video post-processing for Closed Captions and subtitles rendering
Browser
Platform OS FireFox IE1 Chrome
Safari 1 Edge
(NPAPI) (ActiveX) (PPAPI)
1 Safari 64-bit and IE 64-bit support 32-bit plug-ins, but Chrome 64-bit and FireFox
64-bit.
1.3 Terminology
Table 3 describes the terminology used in this guide.
Table 3. Terminology
Term Definition
Closed Caption CC is the processes of displaying text on a television, video screen, or other
(CC) visual display to provide additional or interpretive information.
API for accessing hardware decoders on Android devices. IOMX is for Android
IOMX
devices with version 4.0 and 4.1.
Progressive Progressive Download is the transfer of digital media files from a server to a
Term Definition
Download (PD) client, typically using the HTTP protocol when being initiated from a computer
or other mobile devices.
Real-time
RTP, sometime referred to as RTTP, defines a standardized packet format for
Transport
delivering audio and video over IP networks.
Protocol (RTP)
TCP is one of the core protocols of the Internet protocol (IP) suite. TCP
Transmission
provides reliable, ordered, and error-checked delivery of a stream of octets
Control
between programs running on computers connected to a local area
Protocol (TCP)
network, intranet, or the public Internet. TCP resides at the transport layer.
OSMP+ downloads the media data from http server to local buffer, like
local memory or files, manages the limited buffer efficiently, and then
offers the required data to file parser as needed, as shown in Figure 2.
The OSMP+ player supports the following audio and video codecs:
• Audio
MPEG4-GENERIC
MPEG4-LATM
AMR-WB+
AMR-WB
AMR-NB
QCELP
WMA
• Video
H.264
MPEG4
H.263
WMV
See [MS-WMSP]: Windows Media HTTP Streaming Protocol for the detailed
information about WMHTTP.
HLS works by breaking the overall stream into a sequence of small HTTP-
based file downloads. Each download loads one short chunk of an overall
potentially unbounded transport stream. As the stream is played, the client
may select from a number of different alternative streams containing the
same material encoded at a variety of data rates, allowing the streaming
session to adapt to the available data rate.
The following is the tags supported by the OSMP+ SDK. Refer to HTTP Live
Streaming for detailed definitions about HLS tags.
• EXT-X-TARGETDURATION
• EXT-X-MEDIA-SEQUENCE
• EXT-X-KEY(URI)
• EXT-X-ENDLIST
• EXT-X-STREAM-INF
• EXT-X-KEY(IV)
• EXT-X-DISCONTINUITY
• EXT-X-VERSION
• EXT-X-PLAYLIST-TYPE
• EXT-X-BYTERANGE
• EXT-X-MEDIA
• EXT-X-I-FRAME-STREAM-INF
• EXT-X-STREAM-INF(AUDIO/VIDEO)
• EXT-X-MEDIA(SUBTITLED/FORCED/CHARACTERISTICS)
• EXT-X-STREAM-INF(SUBTITLES)
• EXT-X-MAP
DASH uses the ISO, IEC, and 23009 tags. The Media Presentation
Description (MPD) document contains metadata required by a DASH
client to construct appropriate HTTP URLs to access segments and to
provide the streaming service to the user.
Note: If the first track defined in the DASH manifest file is pure audio, the
OSMP+ SDK will automatically select the first track with both video and
audio defined in the manifest file.
DTS-HD
MP4A
PCM
MULAW
ALAW
WMA
QCELP
• Video
H.264/AVC
H.263
MPEG4
H.265/HEVC
1.4.4.1.1 HEVC/H.265
The input format of this video codec is ISO/IEC23008-2 compliant raw video
data, and the output format is YUV420 planar. The maximum supported
video size for HEVC is 1080p.
HEVC/H.265 supports the following profiles:
• I,P,B frame
• CU size: 8x8 to 64x84
• PU partition: Symmetric
• TU partition: RQT
• TU size: DCT 4x4 to 32x32, DST 4x4
• Intra Prediction mode: all size of DC, Planner, 33 directions mode
• Quarter pixed motion compensation and weighted prediction
• Parallel processing tools deblocking, SAO
• Entropy coding: context-adaptive binary arithmetic coding (CABAC)
1.4.4.1.2 H.264
For H.264 codec, the output format is YUV420. The input formats include:
• 14496-10 AnnexB format
• 14496-15 AVC format
The maximum supported video size for H.264 codec is 1080p. Table 4 lists
the profiles supported by H.264 codec.
Table 4. Supported profiles
SI and SP
slices
No No Yes No No No No No
Flexible
macrobloc
No Yes Yes No No No No No
k ordering
(FMO)
Arbitrary
slice
No Yes Yes No No No No No
ordering
(ASO)
Redundant
No Yes Yes No No No No No
slices (RS)
Data
partitionin No No Yes No No No No No
g
Interlaced
coding
(PicAFF,
No No Yes Yes Yes Yes Yes Yes
MBAFF)
CABAC
entropy No No No Yes Yes Yes Yes Yes
coding
Quantizati
on scaling No No No No Yes Yes Yes Yes
matrices
Separate
Cb and Cr No No No No Yes Yes Yes Yes
QP control
Monochro
me (4:0:0)
No No No No Yes Yes Yes Yes
Sample
8 to
depths 8 8 8 8 8 8 to 10 8 to 14
(bits) 10
Separate
color
No No No No No No No Yes
plane
coding
Predictive
lossless No No No No No No No Yes
coding
For this audio codec, the bitrate mode includes variable bitrate (VBR) and
constant bitrate (CBR), and the output format is 16 bit PCM data. The input
formats include:
1.4.4.2.2 MP3
Table 6 lists the supported MPEG audio layer.
• MPEG1 Layer1
• MPEG1 Layer2
• MPEG1 Layer3
• MPEG2 Layer1
MPEG audio • MPEG2 Layer2
• MPEG2 Layer3
• MPEG2.5 Layer1
• MPEG2.5 Layer2
• MPEG2.5 Layer3
For AutoHW, OSMP+ selects the API based on the following default rules.
OSMP+ will automatically fall back on other options if the selected option is
not working.
• MediaCodec for Android devices with version 4.2 and later.
OSMP+ provides a white list file that overrides the decoder type selection
for specific devices when the IOMX, MediaCodec, or AutoHW types are
set. See 1.4.5.1.2 White List for more information.
Note: Use the Android adb command, adb shell getprop, to get the information
about Model, Release, and Platform.
OSMP+ SDK compares the values of the white list fields to the values of the
device on which it is running.
• If the running device values have a match in the white list, OSMP+
changes the hardware decoding settings according to the white list
settings.
• If the running device values do not match, OSMP+ uses the current
hardware decoding settings.
• The interpretation of the white list is affected by the values of
setDecoderType() and enableVOAdaptivePlayback(). For more
information about the white list mechanisms, refer to the comment
section of device.xml.
Sony Z Ultra/4.2.2/MSM8974
Sony Z1/4.4.4/MSM8974
Sony Z1 compact/4.4.2/MSM8974
Sony Tablet Z/4.4.2/APQ8064
• Teclast
Teclast Tpad/4.1.1/Rockchip
Note:
1. OSMP+ does not support PCM, as PCM is not supported in HLS native player.
2. OSMP+ supports the hardware acceleration via Video Toolbox mechanism on
iOS 8.0 and above. VisualOn recommends using AVPlayer for hardware
acceleration for iOS 6.0 to iOS 7.0.
3. Hardware acceleration via Toolbox mechanism supports H.264 video codec
only, while hardware acceleration using AVPlayer supports both H.264 and AAC.
Hardware acceleration using AVPlayer supports iOS 6.0 and later, and is
available on the following devices:
• iPhone 4, iPhone 4S, iPhone 5, and above
• iPad, iPad2, new iPad, iPad 4, and above
• iPod Touch 4th, iPod Touch 5th, and above
Hardware acceleration using video toolbox supports iOS 8.0 and later, and
is available on the following devices:
• iPhone 4S and above
• iPad 4 and above
• iPod Touch 5th and above
1.4.6 Multiple In adaptive streaming, if multiple audio tracks are advertised in the
audio tracks manifest file, OSMP+ extracts the information and provides a mechanism
to select a specific audio track to be played. OSMP+ also provides APIs to
query a number of properties related to audio, such as number of
alternative audio available, codec type, sample rate, number of
channels, language, and so on.
1.4.7 Closed OSMP+ supports the following Closed Caption formats (including two main
Captions styles: paint-on/roll up and pop-on/pop-up):
• CEA-608
• CEA-708
CEA608 was developed in the 1970s for carrying 960bps captioning data
and services in the VBI (Vertical Blanking Interval) of NTSC video, an
analogue composite video format. In latter day digital component version
of NTSC, this analogue waveform is digitally encoded and embedded in
Line 21 of the Video.
1.4.8 Subtitles Refer to Timed Text Markup Language 1 (TTML1) for a description of text-
based subtitles.
OSMP+ supports the following subtitle formats:
• TTML
• SAMI
• SMPTE
• SRT
• DVB (exclude teletext)
• WEBVTT
1.4.9 FCC FCC compliance supports Timed Text Markup Language (TTML) and
compliance WebVtt. Refer to Notice for the FCC requirements.
1.4.9.1 Presentation
All apparatus must implement captioning so that the caption text may
appear within one or separate caption windows, and supports the
following modes:
• Text that appears all at once (pop-up)
• Text that scrolls up as new text appears (rollup)
• Text where each new letter or word appears as it arrives (paint-on).
OSMP+ has no API to support the presentation mode; instead OSMP+ gets
this data from streaming based on specification CEA-608 and specification
CEA-708.
1.4.9.5 Fonts
All apparatus must implement captioning so that fonts are available to
implement the eight fonts required by CEA–708.
Users must be provided with the ability to assign the fonts included on their
apparatus as the default font for each of the following eight styles on
Android and iOS:
• Default (undefined)
• Monospaced with serifs (similar to Courier)
• Proportionally spaced with serifs (similar to Times New Roman)
• Monospaced without serifs (similar to Helvetica Monospaced)
• Proportionally spaced without serifs (similar to Arial and Swiss)
• Casual font type (similar to Dom and Impress)
• Cursive font type (similar to Coronet and Marigold)
• Small capitals (similar to Engravers Gothic)
Users must be provided with the ability to assign the fonts included on their
apparatus as the default font for each of the following seven styles on
NPAPI/PPAPI plug-ins:
• Courier
• Times New Roman
• Helvetica
• Arial
• Dom
• Coronet
• Gothic
To set the FCC font, use setSubtitleFontName API.
All apparatus must implement captioning so that users are provided with
the ability to vary the opacity of the caption background and select within
opaque, semitransparent, and transparent background opacities.
All apparatus must implement captioning so that users are provided with
the ability to vary the opacity of the caption window and select within
opaque, semi-transparent, and transparent background opacities.
1.4.9.9 Language
All apparatus must implement the ability to select between caption tracks
in additional languages when such tracks are presented and are provided
the ability for the user to select simplified or reduced captions when such
captions are available and identify such a caption track as ‘‘easy
reader.’’
1.4.10 Zoom OSMP+ supports the following zoom modes to control rendering of video:
modes
• Letterbox
• Pan & Scan
• Fit to Window
• Original Size
• Zoom In
Note: Pan & Scan mode is not supported on the Windows plug-in and Mac OS
plug-in.
Figure 8 shows and example of 4:3 video rendered in Pan & Scan mode in
a 16:9 display area of different orientation thus resulting in the height of the
video matching the height of the display area and video being cut on the
left and right sides.
Note: Fit to Window mode is not supported on the Windows plug-in and Mac OS
plug-in.
Note: Original Size mode is not supported on the Windows plug-in and Mac OS
plug-in.
Note: Zoom In mode is not supported on the Windows plug-in and Mac OS plug-
in.
1.4.11 Download Download Manager is an OSMP+ feature that is used to download content
Manager for offline playback.
1.4.12 DRM Digital Rights Management (DRM) is a class of technologies that are used
by hardware manufacturers, publishers, copyright holders, and individuals
with the intent to control the use of digital content (video, audio, and so
on) and devices after sale.
1.4.13 Output OSMP+ supports secure output playback based on the settings configured
Control with in Verimatrix Video Content Authority System (VCAS™) version 3.7.
VCAS
1.4.13.1 Supported features
Table 7 defines the VCAS server-based flags that are used for output
control.
HDCP Uses this option to enable or • On: Enable HDCP and make sure the
disable the highest HDCP highest HDCP version is available.
version. • Off: Disable HDCP.
1.4.13.2 Limitations
The following are the limitations of the output control feature:
• HDCP capability is disabled on the Android platform which version is
lower than version 4.2.
• HDCP capability depends on the Display.SECURE_FLAG flag on the
Android platform which version is version 4.2 or higher.
• HDCP capability is disabled on the iOS platform.
• HDCP capability is disabled on the Mac OS platform.
1.4.14 AirPlay on AirPlay is a proprietary protocol stack/suite that allows wireless streaming
iOS between devices of audio, video, device screens, and photos, together
with related metadata.
Note: AirPlay Streaming Export is only available when using AVPlayer hardware
engine.
1.4.15 360 video The playback support of video recorded by 360 degree cameras works on
decoding the following OS versions:
• Android 4.0 and later
• iOS 7.0 and later
The OSMP+ SDK enables the viewing/playback of the video recorded by
360 degree cameras through four steps.
• Decode rectangular YUV frame as a regular H.264/HEVC frame
• Reverse mapping from YUV frame to 360 sphere view: set viewing
parameters, including viewing scope and sphere size
• Select playback area from user viewing angles: detect user viewing
angle through device sensors, and then input the angle to device
OpenGL engine to select the corresponding viewing area.
• Start playback from different users’ angles
1.4.15.1 Android
VisualOn recommends calling setRenderType, enableSphericalVideo, and
setSphericalVideoView in turn on Android platform, to start playback of
the videos recorded by 360 degree cameras. The following is the detailed
introduction about these three functions and how they work inside the
OSMP+ SDK.
• setRenderType(VO_OSMP_RENDER_TYPE type): This function is used
to set the video render type.
Notes:
1. This API must be called before calling the start() method to set the video
render type.
2. To support the 360 video playback, make sure to set the video render type to
VO_OSMP_RENDER_TYPE_OPENGLES using the following sample code.
player.setRenderType(VO_OSMP_RENDER_TYPE_OPENGLES);
1.4.15.2 iOS
VisualOn recommends calling enableSphericalVideo and
setSphericalVideoView in turn on iOS platform, to start playback of the
videos recorded by 360 degree cameras. The following is the detailed
introduction about both functions and how they work inside the OSMP+
SDK.
Note: The setting of video render type is only available on Android platform.
1.4.16 3D The OSMP+ SDK introduces a new option called ‘CardBoard Video’ to
playback of 360 allow users looking around to view the video in 360 degrees. If this option is
video decoding enabled, the video screen splits into two smaller screens and users can
view the video in 360 degrees. This option only takes effect when both
enableSphericalVideo and enableCardBoardVideo are enabled.
1.4.17 IPv6-only The IPv6-only network support is available on iOS and Mac OS.
network support
In addition to IPv4 or dual stack (IPv4/IPv6) networks support, Apple
requests to support for IPv6-only networks for all applications submitted to
the App Store.
This new feature is available on the following platforms for both clear and
encrypted contents:
• iOS 9.0+/OS X 10.11.4+: both URL host address and IP literal address of
IPv4 content are supported
• Versions lower than iOS 9.0 or OS X 10.11.4: only URL host address of
IPv4 content is supported
The following is the example of log message that helps you to
identify/verify this DNS64/NAT64 transition.
• If the IPv4 content is a URL host address, you may get the log in the
format of ‘15:08:38.319 @@@VOLOG, Info, ModuleID[xxxxxxxx],
ThreadID[xxxxxxxx], vo_http_stream.cpp, send_request,
Line#1731, [SourceIO] address:64:ff9b::a02:4407,
url:example.visualon.com’
• If the IPv4 content is an IP address, you may get the log in the format
of ‘13:23:58.252 @@@VOLOG, Info, ModuleID[xxxxxxxx],
ThreadID[xxxxxxxx], vo_socket.cpp, VO_IOS_DNSResolve,
Line#626, IP item: i=0, host=10.2.68.7, port=8082, is_ipv6=1,
addr=64:ff9b::a02:4407, dataLen=28, sa_len=28, fam=30’.
1.4.18 Render The OSMP+ SDK supports the following four rendering options (also known
options on as render type) on Android to achieve better playback performance
Android when needed:
• Native C: this option will be phased out since Android N
• Native windows: OSMP+ uses this option by default
• Open GL: this option must be selected when enableCardBoardVideo
or enableSphericalVideo is enabled
• Share memory with hardware codec: Android devices render the
video frames directly. In this case, render settings will be ignored
whatever user selects Auto HW, MediaCodec, or IOMX as the
decoder type.
Notes:
1. If video post-processing or video watermark is enabled on the device
where MediaCodec or software decoder is selected as decoder type,
users can select the render type as needed. Do not use share memory with
hardware codec if MediaCodec is selected as decoder type in this case.
2. When Open GL is selected as the render type, the OSMP+ SDK will render
the video frame only when onDrawFrame callback is invoked. This
approach may result in the potential performance limitation, such as the
rendering or playback is not very smooth.
2.1 Android
2.1.1 Installation This section describes the installation of the Sample Player application
included with the SDK on Android.
We recommend that you install the Sample Player application with the
latest Eclipse, which has the ADT extension and JRE 1.6.0 or higher versions.
Refer to Installing the Eclipse Plugin for instructions about how to install ADT
extension in Eclipse. See 1.2 Supported operating system and web browser
for the Android versions supported by OSMP+.
Note: Refer to the Add the SDK Libraries section of the OnStream MediaPlayer+
SDK Project Setup for Android document for details about how to add the SDK
libraries to a project.
2.1.2 Sample This section describes the usage of the Sample Player application included
player usage with the SDK. The Sample Player application implements a fully integrated
media player with the following features:
• Select the media source
• Select the subtitle source
• Select the option for opening the media source, including
Synchronous and Asynchronous
• Set the preferred audio and subtitle languages
• Control the playback through buttons
• Control the sound volume and mute/unmute the sound
• Support the Closed Captions and subtitle rendering
• Configure the asset properties
Alternately, a list of media files and links can be supplied to the Sample
Player through a text file. The text list must be saved to /sdcard/url.txt, with
each link URL and file path separated by line. To select a media file or link
from url.txt:
1. In the initial view, tap the button next to the URL field to display the
media file list.
2. Select the required media source, and then tap OK.
3. Tap the play button.
Refer to 3.1.5 Starting playback for the sample code of starting playback.
For details about initializing the SDK player, opening the media source, and
starting playback, refer to section 3 (Basic Integration) in the OnStream
MediaPlayer+ Player SDK Integration Guide for Android Platforms.
2.1.2.2 Options
2.1.2.2.1 Selecting Video Render Type
Tap Video Render Type from Options, and then tap the required Video
Render Type for the Sample Player, as shown in Figure 17. Refer to
setRenderType(VO_OSMP_RENDER_TYPE type) for API related information.
To enable Push PD, tap the checkbox next to Enable Push PD from Options
to enable Push PD for the Sample Player.
Enabling deblock helps improve the playback quality, especially when the
video has mosaic. Tap Deblock from Options to enable the deblock
feature. Refer to enableDeblock(boolean enable) for API related
information.
3. Tap OK.
If Download Manager is turned on, the Select Asset dialog prompts when
starting the playback. Specify the Video, Audio, and Subtitle tracks to be
downloaded, and then tap OK to download the source to be played. If
you do not want to keep the downloaded files on your device, tap Delete
Downloader File from Options, tap Delete All to remove all downloaded
files, or select the file to be removed and then tap Delete.
Tap Options, and then tap Enable RTSP HTTP Port to enable RTSP HTTP port
function. Tap RTSP HTTP Port, and then type a value to define the Port to
access the RTSP media source, and then tap OK, as shown in Figure 22.
Tap Enable Low Latency Video to set a value as the acceptable level for
RTSP Camera video latency.
The player allows setting the maximum number of socket error. To set the
RTSP Max Socket Error Count:
1. Tap Enable RTSP Max Socket Error Count from Options to enable it.
2. Tap RTSP Max Socket Error Count.
3. Type a value to set the entry level for RTSP Socket error handling,
and then tap OK, as shown in Figure 23.
Tap Enable HTTP Gzip Request from Options to enable or disable the
support of the GZIP format.
Tap URL Query String from Options to enable or disable the token support
for HTTP requests. After enabling this option, tap Enable URL Query String,
and then type the Query String in the prompted dialog.
2.1.2.2.14Subtitle Settings
Tap Subtitle Settings from Options to enable or disable the Subtitle Settings.
For sample code of subtitle settings, refer to 3.1.9 Subtitle rendering
(Optional).
Table 8 lists the available subtitle attributes that can be set in the OSMP+
player and their related API s.
Table 8. Subtitle attributes and related APIs
Enable Subtitle
Bounding Box
• Set Top Percent Set the subtitle bounding box, setSubtitleBoundingBox(int topPercent, int
• Set Left Percent which will overwrite the subtitle leftPercent, int bottomPercent, int
settings from parser. rightPercent)
• Set Bottom
Percent
• Set Right Percent
Enable Font size Set subtitle font size scale. setSubtitleFontSizeScale(int scale)
Enable Font Color List Set subtitle font color. setSubtitleFontColor(int color)
Enable Edge Color Set subtitle font edge color setSubtitleFontEdgeOpacity(int alpha)
Opacity opacity rate.
Enable Edge Type List Set subtitle font edge type. setSubtitleFontEdgeType(int type)
Enable Italic Font Enable or disable the italic font setSubtitleFontItalic(Boolean enable)
for subtitle.
Tap Default Audio or Default Subtitle from Options to enable or disable the
Default Audio and Subtitle settings, as shown in Figure 30.
The Enter NTS feature requires the collaboration within the streaming server,
application, and OSMP+ SDK. Streaming server should create the NTS
stream once the user pause live stream playback, and notify the
application of the new URL of NTS stream.
The application should call OSMP+ SDK API to switch to NTS stream once
the user resumes playback (after perform the pause operation for a while).
Also the application should call OSMP+ SDK API to switch back to Live
stream once the user catches up with the Live content (typically after a
seek operation).
• The playlist of the live stream at the time of pause and the playlist of
the NTS stream at the time of resume should have the same #EXT-X-
PROGRAM-DATE-TIME HLS value
In other words, there are two streams, a live stream that is paused and a
NTS stream that is resumed. Both streams share the same content.
The Enter NTS feature enables playback of the NTS stream instead of the
live stream when resuming playback. To use this feature, enter the value of
the PROGRAM-DATE-TIME HLS tag (when the live stream was paused) in
the Min pos box. Min Pos needs to be converted into millisecond.
Note: To make the Enter NTS feature work, ensure that the value of
enableLiveStreamingDVRPosition() is set to false.
After clicking EnterNTS, the player starts playback at the HLS Live paused
position using the NTS stream. To verify that the resume operation is
successful, one can check that the UTC time display should not change
more than one second when playback resumes.
2.1.2.2.28 Version
The Sample Player version information appears in Version of the Options
menu.
Notes:
The API calling sequence should start with stop(), and then close(), open()
should be last called. The player can set other configurations before
open().
To switch properties:
1. Tap Asset on the bottom of the video screen to display the Asset
menu.
2. Tap the required Video, Audio, and/or Subtitle track.
3. Tap Commit to confirm your selection. Playback continues with your
selection, as shown in Figure 32.
To adjust the volume level, drag the playback volume bar and click Mute
to mute the volume. To restore the audio, click UnMute.
Note: The previous URL will be expired a few seconds after the new URL is
activated. Master manifest, sub-manifest, and TS chunks of new URL must be
exactly same with the previous media file.
1. Tap SpecialFeatures.
2. Type the required media URL address into the Update URL box, and
then tap Update, as shown in Figure 34.
Refer to 1.4.10 Zoom modes for more information about zoom modes.
3. Tap Done.
2.1.2.8.7 SEI
During playback, tap the checkbox next to SEI to enable the SEI setting to
collect the SEI data from the media source.
The player uses a timer to get the download status during playback. See
the following for the sample code of getting download status.
int validBufferDuation = m_sdkPlayer.getValidBufferDuration();
VO_OSMP_DOWNLOAD_STATUS audioDownloadStatus =
m_sdkPlayer.getDownloadStatus(VO_OSMP_SOURCE_STREAMTYPE.VO_OSMP_SS
_AUDIO);
VO_OSMP_DOWNLOAD_STATUS videoDownloadStatus =
m_sdkPlayer.getDownloadStatus(VO_OSMP_SOURCE_STREAMTYPE.VO_OSMP_SS
_VIDEO);
VO_OSMP_DOWNLOAD_STATUS subtitleDownloadStatus =
m_sdkPlayer.getDownloadStatus(VO_OSMP_SOURCE_STREAMTYPE.VO_OSMP_SS
_SUBTITLE);
2.2 iOS
2.2.1 Installation This section describes the installation of the Sample Player application
included with the SDK on iOS.
We recommend that you install the Sample Player application in the latest
Xcode version. See 1.2 Supported operating system and web browser for
the iOS versions supported by OSMP+.
Note:
Application Transport Security blocks the cleartext HTTP on iOS 9. To ensure that
the content can be played back on iOS 9 devices, upgrade Xcode to version 7
and add the following code in the plist.info file.
<key>NSAppTransportSecurity</key>
<dict>
<key>NSAllowsArbitraryLoads</key>
<true/></dict>
After importing the Sample Player project into Xcode, its files are visible in
the Navigator area. The SDK header and library files have been added to
the SamplePlayer project. You are ready to build the project and run the
application on an iOS device.
Note: You must ignore Xcode’s recommendation and select the target. Also,
change the default com.visualon.SamplePlayer to the name of your developer
certificate.
2.2.2 Sample This section describes the usage of the Sample Player application included
Player usage with the SDK. The Sample Player application implements a fully integrated
media player with the following features:
• Select the media source
• Select the subtitle source
• Select the option for opening the media source, including
Synchronous and Asynchronous
• Set the preferred audio and subtitle languages
• Control the playback through buttons
• Control the sound volume and mute/unmute the sound
• Support the Closed Captions and subtitle rendering
• Configure the asset properties
• Sync mode: Opening the media source in sync mode causes the
client application to block until the open method completes or
returns.
• Async mode: In Async mode, the API call returns immediately, and
the client application is not blocked waiting for the media source to
be opened. The client application can then wait for an event to
indicate that the media source was opened successfully before
starting the media playback.
the external device screen, tap the AirPlay button , and then tap the
name of the device to which you want to stream content.
2.2.2.3 Options
2.2.2.3.1 Engine type
The Sample Player application includes an option to initialize the SDK by
using the AVPlayer engine or VisualOn VOME2 software engine (default).
The OSMP+ SDK uses Video Toolbox to resolve the performance issue
caused by the AVPlayer decoder. To achieve the better rendering
performance, Video Toolbox decoder is recommended being selected on
iOS devices. Visit Apple Developer website for more information about
Video Toolbox.
the Sample Player through a text file. The text list must be saved to
/documents/subtitle.txt, with each link URL and file path separated by a
line. Refer to setSubtitlePath for API related information.
If Download Manager is turned on, the Select Asset dialog prompts when
starting the playback. Specify the Video, Audio, and Subtitle tracks to be
downloaded, and then tap OK to download the source to be played. If
you do not want to keep the downloaded files on your device, tap Delete
Downloader File from Options, tap Delete All to remove all downloaded
files, or select the file to be removed and then tap Delete.
To enable CPU Adaption, tap Option, and then tap CPU Adaption.
Tap Set to enable RTSP HTTP Port, and then type a value to define the Port
to access the RTSP media source, as shown in Figure 44. Refer to
setRTSPConnectionPort for API related information.
Tap Option, and then tap Enable Low Latency Video to enable RTSP
Camera video latency.
Tap Set RTSP max socket error count., and then type a value to set the
entry level for RTSP Socket error handling, as shown in Figure 45.
Tap Set RTSTP connection timeout., and then type a number to set a value
for the retry times when server has no response, as shown in Figure 46.
Tap Set the HTTP verification information., and then type the user name
and password to authorize the RTSP media source access, as shown in
Figure 47.
Tap Enable HTTP connection retry timeout., and then type a number to set
the player retry times when server has no response, as shown in Figure 48.
Tap Option, and then tap Enable HTTP Gzip Request to enable or disable
the support of the GZIP format.
Tap URL Query String from Options to enable or disable the token support
for HTTP requests. After enabling this option, tap Enable URL Query String,
and then type the Query String in the prompted dialog.
Tap Option, and then tap Playback Looping to enable or disable the
Playback looping.
Table 9 lists the available subtitle attributes that can be set in the OSMP+
player and their related API s.
Table 9. Subtitle attributes and related APIs
Enable Edge Type List Set subtitle font edge type. setSubtitleFontEdgeType()
Tap Set to enable initial bitrate, type a value for the Initial Bitrate, and then
Tap Done, as shown in Figure 49.
Tap Set bitrate range (kbps), type the number for lower and upper bound
bitrate range, and then tap Done, as shown in Figure 50.
The Enter NTS feature requires the collaboration within the streaming server,
application, and OSMP+ SDK. Streaming server should create the NTS
stream once the user pause live stream playback, and notify the
application of the new URL of NTS stream.
The application should call OSMP+ SDK API to switch to NTS stream once
the user resumes playback (after perform the pause operation for a while).
Also the application should call OSMP+ SDK API to switch back to Live
stream once the user catches up with the Live content (typically after a
seek operation).
• The playlist of the live stream at the time of pause and the playlist of
the NTS stream at the time of resume should have the same #EXT-X-
PROGRAM-DATE-TIME HLS value
In other words, there are two streams, a live stream that is paused and a
NTS stream that is resumed. Both streams share the same content.
The Enter NTS feature enables playback of the NTS stream instead of the
live stream when resuming playback. To use this feature, enter the value of
the PROGRAM-DATE-TIME HLS tag (when the live stream was paused) in
the Min pos box. Min Pos needs to be converted into millisecond.
After clicking EnterNTS, the player starts playback at the HLS Live paused
position using the NTS stream. To verify that the resume operation is
successful, one can check that the UTC time display should not change
more than one second when playback resumes.
2.2.2.3.24 Version
Tap Version from Option to shown the Sample Player version information.
Notes:
To switch properties:
1. Tap Asset on the bottom of the screen to display the Asset Selection
dialog.
2. Tap the required Video, Audio, and/or Subtitle track.
3. Tap Commit to confirm your selection. Playback continues with your
selection, as shown in Figure 55.
To adjust the volume level, drag the playback volume bar and click Mute
to mute the volume. To restore the audio, click UnMute. Refer to mute or
unmute for API related information.
Note: The previous URL will be expired a few seconds after the new URL is
activated. Master manifest, sub-manifest, and TS chunks of new URL must be
exactly same with the previous media file.
2.2.3.9.6 SEI
During playback, tap the checkbox next to SEI to collect the SEI data from
the media source. Refer to startSEINotification or enableSEI for API related
information.
2.3 Plug-ins
2.3.1 Installation This section describes how to install the player plug-ins and how to run the
and associated SDK Sample Player applications.
uninstallation
The operations for hosting the plug-ins, downloading the plug-ins, and
signing the plug-ins may vary depending on supported internet browser.
We recommend that you refer to the internet browser developer’s guide
or user manual or visit their official website for detailed information on
these operations. See 1.2 Supported operating system and web browser
for the Windows version and Mac OS version supported by OSMP+.
Note: Ensure that all web browsers are closed and are killed in Task Manager
before starting the installation.
Note: Ensure that all web browsers are closed and are killed in Activity Monitor
before starting the installation.
underneath the video screen. The video should be started after a few
seconds.
2.3.1.3.1 Windows
To specify the VCAS server information:
1. From the Windows desktop, press the Windows + R key to open the
Run dialog box.
2. Type regedit in the Open: field and click OK.
3. Select:
64-bit Windows:
HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\VisualOn\Br
owserPlugin\DRMVerification\Verimatrix.
32-bit Windows:
HKEY_LOCAL_MACHINE\SOFTWARE\VisualOn\BrowserPlugin\DRM
Verification\Verimatrix
4. Change the value of Server attribute to public-ott-
nodrm.verimatrix.com:80.
2.3.1.3.2 Mac OS
To specify the VCAS server information:
5. Click Go on the Finder menu bar.
6. Press Option on the keyboard to display the Library option.
7. Click Library to display the folders on your system.
8. Click Internet Plug-Ins.
9. Right click voBrowserPlugin.plugin, and then select Show Package
Contents.
10. Click Contents, and then open Info.plist.
11. Change the value of DRMVerificationInfoString in Info.plist to public-
ott-nodrm.verimatrix.com:80.
Or
1. Click Go on the Finder menu bar.
2. Select Terminal from Application > Utilities.
3. In Terminal, type the following command to install the plug-in.
open ~/Library/Internet\ Plug-
Ins/voBrowserPlugin.plugin/Contents/Info.plist
Note: Ensure that all web browsers are closed before starting the uninstallation.
2.3.2 Sample This section describes the use of the Sample Player application integrated
player usage with the SDK. The Sample Player application implements a fully integrated
(Windows) media player with the following features:
• Select the media source
• Support the configurable UI for Windows
• Select the subtitle source
• Select the option for opening the media source, including
Synchronous and Asynchronous
• Set the preferred audio and subtitle languages
• Control the playback through buttons
• Control the sound volume and mute/unmute the sound
• Support the Closed Captions and subtitle rendering
• Configure the asset properties
Note: For details about how to initialize the SDK, open the media source, and
start the playback, refer to section 4 and section 5 in the OnStream
MediaPlayer+ Player SDK Integration Guide for Windows.
2.3.2.2 Configurable UI
When the mouse is over the video screen, the configurable UI appears.
The configurable UI includes a shared Start/Pause button, a seek bar, the
volume adjustment, and a FullScreen icon, as shown in Figure 63.
Note: You might need to resize the window to expose the FullScreen button.
2. To quit the full-screen mode, press Esc on the keyboard or the Exit
full screen icon in the lower right corner.
2.3.2.5 Sound control
You have several options for controlling volume in the Sample Player,
including adjusting the volume level, muting, or unmuting.
To adjust the volume level, in Tab-1, type the percent number in the
Volume box, and then click Set. The value should be any number from 0 to
100.
In Tab-1, click Mute to mute the volume. To restore the audio, click Mute
again.
Note: Type the abbreviated language code that complies with the iso639-2
standard.
2. Click Set.
2. Click Commit.
The subtitle settings support the following attributes. Refer to Table 8 for the
attribute explanations and the corresponding API information.
Note: Type the abbreviated language code that complies with the iso639-2
standard.
2. Click Set.
2.3.2.7 Displaying Closed Captions
The Sample Player application demonstrates the built-in SDK handling of
Closed Captions and subtitles rendering. CC data appears on the video
screen if it exists, as shown in Figure 68.
Notes: The previous URL will be expired a few seconds after the new URL is
activated. Master manifest, sub-manifest, and TS chunks of new URL must be
exactly same with the previous media file.
2.3.2.13 Offset
The offset value defines the starting playback position for the next stream
playback. The OSMP+ player allows you to set the offset in milliseconds. For
example, if the offset is set to 10 seconds, the player plays the next stream
from the scene where the timestamp is 10 seconds.
Note: The offset feature only applies to the VoD links, other than the Live links.
The Enter NTS feature requires the collaboration within the streaming server,
application, and OSMP+ SDK. Streaming server should create the NTS
stream once the user pause live stream playback, and notify the
application of the new URL of NTS stream.
The application should call OSMP+ SDK API to switch to NTS stream once
the user resumes playback (after perform the pause operation for a while).
Also the application should call OSMP+ SDK API to switch back to Live
stream once the user catches up with the Live content (typically after a
seek operation).
• The playlist of the live stream at the time of pause and the playlist of
the NTS stream at the time of resume should have the same #EXT-X-
PROGRAM-DATE-TIME HLS value
In other words, there are two streams, a live stream that is paused and a
NTS stream that is resumed. Both streams share the same content.
The Enter NTS feature enables playback of the NTS stream instead of the
live stream when resuming playback. To use this feature, enter the value of
the PROGRAM-DATE-TIME HLS tag (when the live stream was paused) in
the Min pos box. Min Pos needs to be converted into millisecond.
Note: To make the Enter NTS feature work, ensure that the value of
enableLiveStreamingDVRPosition() is set to false.
After clicking EnterNTS, the player starts playback at the HLS Live paused
position using the NTS stream. To verify that the resume operation is
successful, one can check that the UTC time display should not change
more than one second when playback resumes.
4. Click EnterNTS.
Note: This feature only applies to the debug version, other than the release
version.
2.3.3 Sample This section describes the use of the Sample Player application integrated
player usage with the SDK. The Sample Player application implements a fully integrated
(Mac OS) media player with the following features:
• Select the media source
• Select the subtitle source
• Select the option of opening the media source, including
Synchronous and Asynchronous
• Set the preferred audio and subtitle languages
• Control the playback through buttons
Note: For details about how to initialize the SDK, open the media source, and
start the playback, refer to section 4 and section 5 in the OnStream
MediaPlayer+ Player SDK Integration Guide for iOS.
4. The new license file takes effect from the next playback.
3. Type the agent name in the Name box as needed. This value is set
to VisualOn OSMP+ Player(MacOS) by default.
4. Type the required agent value in the Value box.
5. Click Set. The new user agent takes effect from the next playback.
The Sample Player application allows you to set the aspect ratio as
needed.
To set the aspect ratio, in Tab-1, select the required ratio from the Aspect
ratio list menu.
To adjust the volume level, type the percent number in the Volume box,
and then click Set. The value should be any number from 0 to 100.
Note: Type the abbreviated language code that complies with the iso639-2
standard.
2. Click Set.
The subtitle settings include the following attributes. Refer to Table 8 for the
attribute explanations and the corresponding API information.
Note: Type the abbreviated language code that complies with the iso639-2
standard.
2. Click Set.
Note: The previous URL will be expired a few seconds after the new URL is
activated. Master manifest, sub-manifest, and TS chunks of new URL must be
exactly same with the previous media file.
2.3.3.12 Offset
The offset value defines the starting playback position for the next stream
playback. The OSMP+ player allows you to set the offset in milliseconds. For
example, if the offset is set to 10 seconds, the player plays the next stream
from the scene where the timestamp is 10 seconds.
Note: The offset feature only applies to the VoD links, other than the Live links.
The Enter NTS feature requires the collaboration within the streaming server,
application, and OSMP+ SDK. Streaming server should create the NTS
stream once the user pause live stream playback, and notify the
application of the new URL of NTS stream.
The application should call OSMP+ SDK API to switch to NTS stream once
the user resumes playback (after perform the pause operation for a while).
Also the application should call OSMP+ SDK API to switch back to Live
stream once the user catches up with the Live content (typically after a
seek operation).
In other words, there are two streams, a live stream that is paused and a
NTS stream that is resumed. Both streams share the same content.
The Enter NTS feature enables playback of the NTS stream instead of the
live stream when resuming playback. To use this feature, enter the value of
the PROGRAM-DATE-TIME HLS tag (when the live stream was paused) in
the Min pos box. Min Pos needs to be converted into millisecond.
Note: To make the Enter NTS feature work, ensure that the value of
enableLiveStreamingDVRPosition() is set to false.
After clicking EnterNTS, the player starts playback at the HLS Live paused
position using the NTS stream. To verify that the resume operation is
successful, one can check that the UTC time display should not change
more than one second when playback resumes.
4. Click EnterNTS.
Note: This feature only applies to the debug version, other than the release
version.
• VO_OSMP_PREF_CONNECTION_IPV6_PRIOR
2.3.2.19 Retry times
In Tab-1, input a number to set the player retries times when server has no
response, and then clicks Set.
2.4.1 Installation To install the Sample Player on a Windows phone, ensure that you have
and registered the Windows phone by using the Windows Phone Developer
uninstallation Registration Tool. To register your Windows phone:
1. Turn on your phone and unlock the phone screen.
Note: Ensure that the date and time on your phone are correct.
5. Click Register.
6. Type your Microsoft developer account and password in the Sign In
dialog, and then click Sign In.
After your phone is successfully registered, the Status message
displays Congratulations! You have successfully unlocked your
Windows Phone.
After registering the Windows phone, install the Sample Player on the
Windows phone:
Note: Ensure that you uninstall the Sample Player prior to the upgrade if you have
a sample player previously installed on your Windows phone.
To uninstall the Sample Player on a Windows phone, press and hold the
Sample Player application, and then select Uninstall from the context
menu.
2.4.2 Opening Media source can be opened in either Sync or Async mode. The Sample
media source Player uses Async mode by default. For sample code of opening media
source, refer to 3.4.3 Opening media source.
• Sync mode: Opening the media source in sync mode causes the
client application to block until the open method completes or
returns.
• Async mode: In Async mode, the API call returns immediately, and
the client application is not blocked waiting for the media source to
be opened. The client application can then wait for an event to
indicate that the media source was opened successfully before
starting the media playback.
2.4.3 The initial view allows you to select the media source for playback. You
Selecting/Playin can type the media source path manually or select from a list of media
g media source source listed in a text file.
Alternately, a list of media files and links can be supplied to the Sample
Player through a text file. The text list must be saved to /sdcard/url.txt, with
each link URL and file path separated by line. To supply the media text file
into a Windows phone:
1. Download and install IsoStoreSpy.
2. Open IsoStoreSpy, and then click WP Application.
3. In the Choose an application dialog, select Device from the <select
a device> list box.
Enabling deblock helps improve the playback quality, especially when the
video has mosaic. Tap Set to enable deblock function from Options to
enable the deblock feature. Refer to enableDeblock() for API related
information.
Table 10 lists the available subtitle attributes that can be set in the OSMP+
player and their related API s.
Table 10. Subtitle attributes and related APIs
Enable Edge Type List Set subtitle font edge type. setSubtitleFontEdgeType()
Tap Lower Bound Bitrate Range/Upper Bound Bitrate Range, type the
number for lower and upper bound bitrate range, and then tap OK.
Tap HTTP Retry Timeout, and then type a number to set the player retry
times when server has no response.
Tap Options, and then tap Enable or disable sending HTTP request with
gzip to enable or disable the support of the GZIP format.
2.4.5 Switching If the media source includes multiple video tracks (also known as bitrate),
Asset properties audio tracks, or subtitles, the Sample Player application supports switching
properties during the playback.
To switch properties:
1. Tap Asset on the bottom of the video screen to display the Asset
menu.
2. Tap the required video, audio, and/or subtitle track.
3. Tap Commit to confirm your selection. Playback continues with your
selection.
2.4.6 Capturing Follow the instructions to obtain your log file on Windows Phone 8.1:
log
Note: The logging system is only enabled in the debug version. The difference
between debug and release versions, is that the debug version can output the
log information in different levels with various detailed information.
1. Open IsoStoreSpy.
The integration Labs, which are compressed into the labs.zip file under Doc
of your installation package, provide working examples to accompany
the OSMP+ Player SDK Integration Guide for Android Platforms. The
integration Labs focus on individual integration topics and require
installation of the SDK and license file. Start with README.txt compressed in
the labs.zip file to learn how to use Labs.
3.1.1 Preparing Decompress the Android package, and you see the following directory
SDK files structure under Android of your installation directory.
• Bin
• Doc
• Jar
• Libs
• Libs_x86
• License
• SamplePlayer
Follow these steps to complete the prerequisites for importing the SDK
libraries:
1. Create the libs directory under the SamplePlayer directory, if the
SamplePlayer directory does not include the libs directory already.
2. Copy all .jar files (Java SDK libraries) to libs.
If you want to use the debug version to import logs, copy all .jar files
under Jar\debug to libs and copy all .so files under Libs\debug to
the folder created in step 3.
3. Create a directory named armeabi under libs.
Or
If you use x86, create a directory named x86 under libs.
4. Copy all .so files (C/C++ shared libraries) to armeabi.
Or
Copy all .so files (C/C++ shared libraries) to x86.
5. Create a directory named assets under SamplePlayer, if it does not
exist already, and then copy the license file, voVidDec.dat to assets.
To use the OSMP+ SDK, add the following sample codes to import Java
SDK libraries.
import com.visualon.OSMPPlayer.*;
import com.visualon.OSMPPlayerImpl.*;
• VOCommonPlayer
• VOCommonPlayerAssetSelection
• VOCommonPlayerConfiguration
• VOCommonPlayerControl
• VOCommonPlayerDeviceInfo
• VOCommonPlayerHDMI
• VOCommonPlayerHTTPConfiguration
com.visualon.OSMPPlayer • VOCommonPlayerListener
• VOCommonPlayerRTSPConfiguration
• VOCommonPlayerStatus
• VOCommonPlayerSubtitle
• VOOSMPChunkInfo
• VOOSMPInitParam
• VOOSMPType
• VOOSMPVerificationInfo
• VOCommonPlayerHDMIImpl
• VOCommonPlayerImpl
• VOOSMPAssetIndexImpl
com.visualon.OSMPPlayerImpl
• VOOSMPAssetPropertyImpl
• VOOSMPEnumUtils
• VOOSMPInitParamImpl
3.1.3 Opening Use VOCommonPlayer.open() to open the media source. See the
media source following for sample codes.
// Auto-detect source format
VO_OSMP_SRC_FORMAT format =
VO_OSMP_SRC_FORMAT.VO_OSMP_SRC_AUTO_DETECT;
// Set source flag to asynchronous
VO_OSMP_SRC_FLAG eSourceFlag;
eSourceFlag = VO_OSMP_SRC_FLAG.VO_OSMP_FLAG_SRC_OPEN_ASYNC;
VOOSMPOpenParam openParam = new VOOSMPOpenParam();
openParam.setDecoderType(VO_OSMP_DECODER_TYPE.VP_OSMP_DEC_VIDEO_SW
.getValue() |
VO_OSMP_DECODER_TYPE.VO_OSMP_DEC_AUDIO_SW.getValue());
//Open media source
m_sdkPlayer.open(m_strVideoPath, eSourceFlag, format, openParam);
3.1.4 Handling Use VOCommonPlayerListener() to handle SDK events. See the following
SDK events for sample codes.
private VOCommonPlayerListener m_ListenerEvent = new
VOCommonPlayerListener(){
// SDK Event Handling
...
public VO_OSMP_RETURN_CODE onVOEvent(VO_OSMP_CB_EVENT_ID nID, int
nParam1, int nParam2, Object obj) {
switch(nID) {
...
Case VO_OSMP_CB_OPEN_FINISHED: {
if (nParam1 == VO_OSMP_RETURN_CODE.VO_OSMP_ERR_NONE.getValue())
{ // MediaPlayer is opened
VO_OSMP_RETURN_CODE nRet;
// Start (play) media pipeline
mRet = m_sdkPlayer.start();
...
} else {
onError(m_sdkPlayer, nParam1, 0);
}
break;
}
...
}
return VO_OSMP_RETURN_CODE.VO_OSMP_ERR_NONE; }
3.1.5 Starting The OSMP+ player can start the playback either in the Sync mode or in the
playback Async mode. See the following for the source code of opening the source
in Sync mode or in Async mode.
3.1.5.1 Sync
eSourceFlag = VO_OSMP_SRC_FLAG.VO_OSMP_FLAG_SRC_OPEN_SYNC;
m_sdkPlayer.open(...)
m_sdkPlayer.start();
3.1.5.2 Async
eSourceFlag = VO_OSMP_SRC_FLAG.VO_OSMP_FLAG_SRC_OPEN_ASYNC;
m_sdkPlayer.open(...);
3.1.6 Stopping Use VOCommonPlayer.stop() to stop playback. See the following for the
playback sample code for the whole stop function.
m_sdkPlayer.stop();
m_sdkPlayer.close();
m_sdkPlayer.destroy();
m_sdkPlayer = null;
See the following for the sample code of the seeking operation.
To select a track:
1. Get the number of video tracks by using int count =
m_sdkPlayer.getVideoCount();
2. Use m_sdkPlayer.selectVideo(index) and m_sdkPlayer.commit() to
select the corresponding index of track for playback.
If the first track is selected, the index value is 0. Increase the index
value in the ascending order. For example, if the second track is
selected, the index value is 1.
Set the index value to -1, which means to adjust the video track
automatically according to the network bandwidth.
Note: For audio and subtitle selection, the index value cannot be set to
-1. Refer to VOCommonPlayerAssetSelection for the all related functions.
m_sdkPlayer.setSubtitlePath(strSubtitlePath);
3.1.10 Download OSMP+ supports to download streaming to local disks. Refer to the
Manager VOOSMPStreamingDownloader interface for details.
(Optional)
3.1.10.1 Initializing Download Manager
See the following for the sample code of initializing Download Manager.
m_downloader = new VOOSMPStreamingDownloaderImpl();
String apkPath = CommonFunc.getApkPath(m_context);
VOOSMPStreamingDownloaderInitParam init = new
VOOSMPStreamingDownloaderInitParam();
init.setContext(m_context);
init.setLibraryPath(apkPath);
m_downloader.init(this, init);
switch(event){
case
VO_OSMP_CB_STREAMING_DOWNLOADER_SYNC_AUTHENTICATION_DRM_SERVER_INF
O:
// DRM download support
{
VOOSMPVerificationInfo info = new
VOOSMPVerificationInfo();
info.setDataFlag(1);
if(m_verificationString != null)
info.setVerificationString(m_verificationString);
m_downloader.setDRMVerificationInfo(info);
break;
}
case VO_OSMP_CB_STREAMING_DOWNLOADER_OPEN_COMPLETE:
//Select video/audio/subtitle track to download;
m_downloader.selectVideo(index);
m_downloader.commitSelection();
…
m_downloader.start();
break;
case VO_OSMP_CB_STREAMING_DOWNLOADER_MANIFEST_OK:
//This is the download local path,it can be play throuth OSMP SDK
now
String localURL = String(obj);
m_sdkPlayer.open(localURL……);
break;
…
}
}
See the following for the sample code for specifying the hardware
decoder type.
VOOSMPOpenParam openParam = new VOOSMPOpenParam();
//use SW
openParam.setDecoderType(VO_OSMP_DECODER_TYPE.VP_OSMP_DEC_VIDEO_SW
.getValue() |
VO_OSMP_DECODER_TYPE.VO_OSMP_DEC_AUDIO_SW.getValue());
//use IOMX
openParam.setDecoderType(VO_OSMP_DECODER_TYPE.VP_OSMP_DEC_VIDEO_IO
MX.getValue() |
VO_OSMP_DECODER_TYPE.VO_OSMP_DEC_AUDIO_IOMX.getValue());
//use MediaCodec
openParam.setDecoderType(VO_OSMP_DECODER_TYPE.VP_OSMP_DEC_VIDEO_ME
DIACODEC.getValue() |
VO_OSMP_DECODER_TYPE.VO_OSMP_DEC_AUDIO_MEDIACODEC.getValue());
//use AutoHW
openParam.setDecoderType(VO_OSMP_DECODER_TYPE.VP_OSMP_DEC_VIDEO_
HARDWARE_AUTO_SELECTED.getValue() |
VO_OSMP_DECODER_TYPE.VO_OSMP_DEC_AUDIO_SW.getValue());
See the following for the sample code for setting the zoom mode.
• PanScan:
m_sdkPlayer.setZoomMode(VO_OSMP_ZOOM_MODE.VO_OSMP_ZOO
M_PANSCAN, null);
• FitWindow:
m_sdkPlayer.setZoomMode(VO_OSMP_ZOOM_MODE.VO_OSMP_ZOO
M_FITWINDOW, null);
• Original:
m_sdkPlayer.setZoomMode(VO_OSMP_ZOOM_MODE.VO_OSMP_ZOO
M_ORIGINAL, null);
• LetterBox:
m_sdkPlayer.setZoomMode(VO_OSMP_ZOOM_MODE.VO_OSMP_ZOO
M_LETTERBOX,null);
• ZoomIn:
Rect rect = new Rect(videoWidth / 4, videoHeight / 4, videoWidth * 3
/ 4, videoHeight * 3 / 4);
m_sdkPlayer.setZoomMode(VO_OSMP_ZOOM_MODE.VO_OSMP_ZO
OM_ZOOMIN, rect);
The integration Labs, which are compressed into the labs.zip file under Doc
of your installation package, provide working examples to accompany
the OSMP+ Player SDK Integration Guide for iOS Platforms. The integration
Labs focus on individual integration topics and require installation of the
SDK and license file. Start with README.txt compressed in the labs.zip file to
learn how to use Labs.
3.2.1 Preparing Import header files, libraries, and license file into the player project.
SDK files
3.2.1.1 Importing header files
Import the OSMP+ SDK header files that are relevant for your player
project. A basic SDK client requires the VOCommonPlayerImpl.h header
file. Table 12 lists the header files dependency.
• VOCommonPlayerDeviceInfo.h
(optional)
• VOCommonPlayerHDMI.h (optional)
• VOCommonPlayerHTTPConfiguration.h
VOOSMPBuffer. N/A
h
VOOSMPPCMB N/A
uffer.h
}
if (0 == strcmp(pszApiName, "voGetAudio2ReadAPI")) {
return (void
*)voGetAudio2ReadAPIAdapter;
}
}
• Configuring a view
• Defining the view size
• Setting the license
• Setting the event callback
See the following for the sample code for initializing an SDK instance.
3.2.4 Handling See the following for the sample code for handling the basic event.
SDK event
(VO_OSMP_RETURN_CODE) onVOEvent:(VO_OSMP_CB_EVENT_ID)nID
param1:(int)param1 param2:(int)param2 pObj:(void *)pObj
{
if (nID == VO_OSMP_CB_PLAY_COMPLETE) {
}
else if (nID == VO_OSMP_SRC_CB_OPEN_FINISHED)
{
}
return VO_OSMP_ERR_NONE;
}
3.2.5 Starting Use VOCommonPlayer.start() to start playback after opening the media
playback source.
[self.player start];
- (void)startDownloader
{
// Select downloader track and start playback.
}
[self.downloader close];
3.2.13 Zoom Use VOCommonPlayer.setZoomMode() to set the zoom mode. See the
following for the sample code of the zoom mode.
mode [in] Zoom mode. Refer to {@link VO_OSMP_ZOOM_MODE}.
Rect rt;
memset(&rt, 0, sizeof(Rect));
[self.player setZoomMode:mode rect:rt];
3.2.15 Enabling See the following for the sample code for enabling the Verimatrix DRM.
DRM
- (VO_OSMP_RETURN_CODE) setVerifiacationInfo
{
return ret;
}
Fill the * characters with the register key of VisualOn OSMP+ plug-
in object.
For other browsers on Windows, use the object type to specify the
plug-in object:
pluginObj.setAttribute("type", "application/x-visualon-
osmp");
For Safari on Mac OS, the video is plotted directly on the Safari
window.
pluginObj.setAttribute("wmode", "transparent");
3.3.2 Initializing
OSMP+
To create an OSMP+ instance, and then bind this instance to the plug-in
object created in 3.3.1 Creating a plug-in object:
1. Use the following code to create an OSMP+ instance, and then
bind it to the plug-in object:
voplayer = new VOCommonPlayer(OSMPPlayerPlugin);
voplayer.init(voOSMPType.VO_OSMP_PLAYER_ENGINE.VO_OSMP_VOME2
_PLAYER, '');
3.3.3 Enabling The OSMP+ SDK uses the AES-128 DRM by default. Refer to the following
DRM documents if you want to find the information to change the DRM server.
• Windows: Refer to DRM information in Table 3: Examples of Registry
location in OnStream MediaPlayer+ Plugin SDK Integration Guide for
Windows. pdf
• Mac: Refer to 7.6 Verimatrix in OnStream MediaPlayer+ Plugin SDK
Integration Guide for Mac OS.pdf.
The following is the required software for interfacing with the OSMP+ SDK
on Windows Phone 8.1:
• 64-bit Windows 8 Pro or higher
• Windows Phone 8.x SDK
• Microsoft Visual Studio Ultimate 2013 or higher
• Register a Windows Phone 8.x device by signing up for a developer
account
• Enable Hyper-V for Windows Phone 8.x emulator
• IsoStoreSpy for file exploration
Note: Refer to Register your Windows Phone for instructions about how to register
a Windows Phone device.
3.4.1 Preparing Import header files, libraries, and license file into the player project.
SDK files
Import the OSMP+ SDK header files that are relevant for your player
project. A basic SDK client requires the VOCommonplayer.h header file.
Table 13 lists the header files dependency.
• VOCommonPlayerDeviceInfo.h
• VOCommonPlayerHTTPConfiguration.h
• VOCommonPlayerListener.h
• VOCommonPlayerRTSPConfiguration.h
• VOCommonPlayerStatus.h
• VOCommonPlayerSubtitle.h
void* viewParam[2] = {
reinterpret_cast<void *>(window),
reinterpret_cast<void *>(swapChainPanel)
};
m_commonPlayer->setView(reinterpret_cast<void *>(viewParam));
With this wrapper, user can put the event handling logic in DirectXPage
and achieve the interaction between XAML UI and OSMP+ SDK.
For more information about DirectXPage, refer to DirectX and XAML
project template of VS2013. For more information about event handling
logic, refer to DirectXPage::initVOEventListener() function in the push-
mode OSMP+ sample.
3.4.5 Supported OSMP+ SDK for Windows Phone provides the following subset of APIs to
APIs and push retrieve the streaming data with push-mode. For more information about
buffer usage the following APIs, refer to API Reference Manual.zip under your installation
package.
• init
• destroy
• setView
• openSource
• close
• start
• pause
• stop
• setPosition
• setOnEventListener
• getPlayerStatus
4 In this guide, “we” refer to the VisualOn development engineering team that
• getPosition
• getMinPosition
• getMaxPosition
• getDuration
• getParameter
• setLicenseContent
• setLicenseFilePath
3.4.6 Enabling AES-128 DRM engine is loaded and enabled by default for the OSMP+
DRM sample player with Verimatrix on Windows Phone. Refer to the
DirectXPage.xaml file under \WinPhone\SameplePlayer for the DRM
configuration information.
Or
m_commonPlayer->setDRMLibrary(strText.c_str(),
strText1.c_str());
Verimatrix Client ID and then presents it to the web page. Refer to the
baseplayer.js file in the Sample Player project for details.
The following is the corresponding sample code:
function initDRMInfoByExtension(){
if (!Bph.setDRMLibrary) return;
var temp = getElement('DRMLibrary');
if (temp != null && temp.value){ strDRMLibName = temp.value; }
temp = getElement('DRMAPI');
if (temp != null && temp.value){ strDRMApiName = temp.value; }
Bph.setDRMLibrary(strDRMLibName,strDRMApiName,function(duid){
log_output('setDRMLibrary through extension: DRM ID=
'+duid+'\n');
});
}
this.setDRMLibrary = function(libname,libapiname,cb){
var cmd = 'setDRMLibrary';
var data = {cmd: cmd, libName:libname, libApiName:libapiname
};
_connection.postMessage(data);
_cmd_callbacks[cmd] = cb;
}
4.1 Overview........................................................................................................168
4.1 Overview
The following log line is a typical log line, each field is described in detail
below:
Note: For security reasons, the logging system is only enabled when using the
VisualOn debug libraries. To capture log, make sure that the debug libraries are
used in your applications.
$time$
@@@VOLOG,$LevelName$,$ModuleID$,$ThreadID$,$FileName$,$FunctionNam
e$,$LineNumber$,$YOURSLOG$
Notes:
1. The OSMP+ SDK will print the log messages with level 2 by default. If you want
to configure the log printing level yourself, modify the volog.cfg configuration file
as required and then copy the updated volog.cfg file to your local device. Refer
to 4.3 Customization of volog.cfg for more information.
2. Log level 3 and 4 should only be used exceptionally because the log file size
will quickly exceed the storage capability of your device.
• 0 (error): Indicates the printing level is 0 and the OSMP+ SDK will
output all error messages.
• 1(warning): Indicates the printing level is 1 and the OSMP+ SDK will
output all error and warning messages.
• 2 (info): Indicates the printing level is 2 and the OSMP+ SDK will output
all error, warning, and information messages.
• 3 (status): Indicates the printing level is 3 and the OSMP+ SDK will
output all error, warning, information, and status messages.
• 4 (running): Indicates the printing level is 4 and the OSMP+ SDK will
output all error, warning, information, status, and running messages.
after the workflow completes. However the player might crash during
playback and some of the log will be lost as some of the log
information is temporarily saved in the cache and is not flushed to local
storage. If you want to avoid losing the cached information in case of
crash, change ‘1’ to ‘0’. By setting ‘1’ to ‘0’, the log file is saved to the
directory defined as the second line directly and caching is not used.
Note: If caching is disabled, the write speed to the log file will be slower than
the normal usage.
Note: If the tmp directory does not exist on your mobile device, use the
‘adb shell’, ‘cd data/local’, and ‘mkdir tmp’ commands to create the
tmp directory.
4. Run the sample player. You can find the volog.log file under the
directory specified in step 2.
Note: You are not allowed to specify the path to save the log file on iOS.
0x00000000,2
0xFFFFFFFF,./,128000
0xFFFFFFFE,1
Note: You are not allowed to specify the path to save the log file on iOS.
0x00000000,2
0xFFFFFFFF,./,128000
0xFFFFFFFE,1
Note: Contents included in angle brackets <> will vary depending on the
device model that you are using.
Note: DebugView requires a lot of CPU and will affect playback. VisualOn
recommends using the volog.cfg option instead (see 4.4.3.2
Capturing/Configuring log output using volog.cfg).
Note: If you cannot find ProgramData under Disk C, select Tools > Folder
Options > View, select Show hidden files, folders, and drives, and then
click OK.
0x00000000,2
0xFFFFFFFF,C:\ProgramData\VisualOn\BrowserPlugin,128000
0xFFFFFFFE,1
3. Run the sample player. You can find the volog.log file under
C:\ProgramData\VisualOn\BrowserPlugin.
4.4.4 Capturing In the case of the VisualOn sample plug-in, the volog.cfg file is located
log on Mac under /Users/<user_name>/Library/Internet Plug-
NPAPI plug-in Ins/voBrowserPlugin.plugin/Contents/dylib. After installing the debug
version, the log file will be automatically saved to ~/Users /<user_name>.
If you want to configure the log output, perform the following to capture
the OSMP+ log on Mac OS NPAPI plug-in:
1. Open the volog.cfg file under /Users/<user_name>/Library/Internet
Plug-Ins/voBrowserPlugin.plugin/Contents/dylib after installing the
debug version.
2. You will see the following text. Make changes to volog.cfg file as
needed.
Refer to 4.3 Customization of volog.cfg for the detailed explanation
of the following tags/values.
0x00000000,2
0xFFFFFFFF,./,1280000
0xFFFFFFFE,1
3. Run the sample player. You can find the volog.log file under ~/Users
/<user_name>.
Note: Make sure that the volog.cfg file values are compatible with the
name of your customized application.
4.4.5 Capturing Follow the instructions to obtain your log file on Windows Phone 8.1:
log on Windows
Phone 1. Go to http://isostorespy.codeplex.com/ and then download
IsoStoreSpy.
2. Install and open IsoStoreSpy.
3. Connect your Windows phone to your computer with a USB cable
that comes with your phone.
5. Logs are generated and saved in the volog.log file located under
the same directory as volog.cfg.
If you do not want to install IsoStoreSpy and have ISETool.exe already
installed on your computer, follow the instructions below to obtain your log
file:
ISETool.exe rs de 9731be5a-856a-45fb-b85a-4054a33bf837
"E:\apk\IsolatedStore
4. The log file will be generated and saved on your Windows Phone.
Type the following command in the command line to copy the log
file to your computer. You can change the file path as needed.
ISETool.exe ts de 9731be5a-856a-45fb-b85a-4054a33bf837
"E:\apk
4.6.1 Bitrate Table 14 lists the keywords, keywords’ definitions, parameter types, and
Adaptation logs sample output messages for the Bitrate Adaptation related logs labeled
with LOGLEVEL=0.
Parameter
Keyword Definition Sample output message
type
VOLOG_KEYWORD_BA_CAP(x Maximum bitrate that can be BA CAP bandwidth:
int
) used <200000 b>
VOLOG_KEYWORD_BA_INIT_BI Initial bitrate that should be BA initial bitrate: <200000
int
TRATE(x) selected bps>
VOLOG_KEYWORD_BA_CPU_L CPU loading value when
int BA CPU-loading: <57%>
OADING(x) performing bitrate adaptation
BA stream bitrate changes
VOLOG_KEYWORD_BA_SWITC
Stream bitrate is changed Int, int from bitrate: <200000 bps>
HING(x,y)
to bitrate: <737777 bps>
4.6.2 Buffer logs Table 15 lists the keywords, keywords’ definitions, parameter types, and
sample output messages for the buffer related logs labeled with
LOGLEVEL=0. All keywords are the information about player’s buffer pool
or the buffering operation.
Parameter
Keyword Definition Sample output message
type
VOLOG_KEYWORD_BUFFER_M Maximum duration of buffer Buffer maximum length:
int
AXLEN(x) pool <20000 ms>
VOLOG_KEYWORD_BUFFER_B Position where bitrate Buffer BA position: <10032
int
A_POS(x,y) adaptation occurs ms>
VOLOG_KEYWORD_BUFFER_B Indicates that buffering is
N/A Buffer buffering in progress
UFFERING progress
4.6.3 Content Table 16 lists the keywords, keywords’ definitions, parameter types, and
logs sample output messages for the content related logs labeled with
LOGLEVEL=0.
Parameter
Keyword Definition Sample output message
type
Content URL:
VOLOG_KEYWORD_CONTENT Information of content URL
char* <http://10.2.68.105/nts/app
_URL(x) string
le/gear4/fileSequence1.ts>
VOLOG_KEYWORD_CONTENT Video codec type used for the Content video codec:
char*
_VIDEO_CODEC(x) content being played <AVPlayer>
VOLOG_KEYWORD_CONTENT Audio codec type used for the Content audio codec:
char*
_AUDIO_CODEC(x) content being played <AAC>
VOLOG_KEYWORD_CONTENT Video resolution in width <x> Content resolution: <1024 x
int, int
_RESOLUTION(x,y) height <y> 768>
VOLOG_KEYWORD_CONTENT Streaming type that is either Content streaming type:
char*
_STREAMING_MEDIA_TYPE(x) Live or VOD <Live>
4.6.4 Controller Table 17 lists the keywords, keywords’ definitions, parameter types, and
logs sample output messages for the controller related logs labeled with
LOGLEVEL=0.
4.6.5 DRM logs Table 18 lists the keywords, keywords’ definitions, parameter types, and
sample output messages for the DRM related logs labeled with
LOGLEVEL=0.
4.6.6 Hardware Table 19 lists the keywords, keywords’ definitions, parameter types, and
Codec logs sample output messages for the hardware codec related logs labeled
with LOGLEVEL=0.
Parameter
Keyword Definition Sample Output message
type
VOLOG_KEYWORD_MEDIAC Indicates that source is Hardware codec
N/A
ODEC_OPEN opened using MediaCodec MediaCodec is created
Indicates that source opened
VOLOG_KEYWORD_MEDIAC Hardware codec
with MediaCodec is N/A
ODEC_FINISHED MediaCodec is destroyed
completed
Hardware codec
VOLOG_KEYWORD_MEDIAC Shows the video head data of
char* MediaCodec video head
ODEC_VIDEO_HEAD_DATA(x) MediaCodec
data: <0x00>
VOLOG_KEYWORD_IOMX_ST Hardware codec IOMX is
MediaCodec starts N/A
ART created
VOLOG_KEYWORD_IOMX_ST MediaCodec completes N/A Hardware codec IOMX is
Parameter
Keyword Definition Sample Output message
type
OP destroyed
VOLOG_KEYWORD_IOMX_DE Hardware codec IOMX
Shows the device name char*
VICE_NAME(x) device name: <Galaxy S3>
Hardware codec IOMX
VOLOG_KEYWORD_IOMX_C Shows the IOMX component compontent:
char*
OMPONENT(x) information <OMX.Nvidia,h264,decode
r>
Hardware codec IOMX
VOLOG_KEYWORD_IOMX_VI
Shows the video resolution int, int video resolution: <1024 x
DEO_RESOLUTION(x,y)
768>
VOLOG_KEYWORD_IOMX_SU Shows the surface pointer Hardware codec IOMX
int
RFACE_POINTER(x) information surface pointer: <0x12345>
4.6.7 License Table 20 lists the keywords, keywords’ definitions, parameter types, and
logs sample output messages for the license related logs labeled with
LOGLEVEL=0.
Sample output
Keyword Definition Parameter type
message
VOLOG_KEYWORD_LICENSE_ Indicates that license check
N/A License check starts
START starts
VOLOG_KEYWORD_LICENSE_ Indicates that license check License check
N/A
STOP completes completes
VOLOG_KEYWORD_LICENSE_ Result of module being License check result:
int
CHECK_RESULT(x) performed the license check <successful>
4.6.8 Local File Table 21 lists the keywords, keywords’ definitions, parameter types, and
logs sample output messages for the local file related logs labeled with
LOGLEVEL=0.
Sample output
Keyword Definition Parameter type
message
VOLOG_KEYWORD_LOCAL_F Shows the file format Local file format:
char*
ILE_FORMAT(x) information <TS>
Local file clip
VOLOG_KEYWORD_LOCAL_ Shows the duration of local
int duration: <87670123
CLIP_DURATION(x) clip
ms>
4.6.9 KPI logs Table 22 lists the keywords, keywords’ definitions, parameter types, and
output messages for the KPI related logs labeled with LOGLEVEL=0.
Sample output
Keyword Definition Parameter type
message
Information of video rendering KPI Video rendering
VOLOG_KEYWORD_KPI_FPS(x
performance in the unit of FPS int performance: <247
)
(frame per second) FPS>
VOLOG_KEYWORD_KPI_FRA Quantity of video frames KPI <241> Video
int
ME_DROP(x) being dropped after playback frame(s) dropped
4.6.10 OS Source Table 23 lists the keywords, keywords’ definitions, parameter types, and
logs sample output messages for the OS source related logs labeled with
LOGLEVEL=0.
Sample output
Keyword Definition Parameter type
message
OS source switches
VOLOG_KEYWORD_OSSOURCE Indicates that a stream is
int, int stream from ID <-1>
_SELECT_STREAM(x,y) selected
to ID <1>
OS source switches
VOLOG_KEYWORD_OSSOURCE Indicates video IDs selected
int, int video from ID <-1> to
_SELECT_VIDEO(x,y) by OS source
ID <1>
OS source switches
VOLOG_KEYWORD_OSSOURCE Indicates audio IDs selected
int, int audio from ID <-1> to
_SELECT_AUDIO(x,y) by OS source
ID <1>
OS source switches
VOLOG_KEYWORD_OSSOURCE Indicates subtitle IDs
int, int subtitle from ID <-1>
_SELECT_SUBTITLE(x,y) selected by OS source
to ID <1>
VOLOG_KEYWORD_OSSOURCE Indicates that program OS source program
N/A
_PROGRAMINFO_RESET information is reset. info gets reset
VOLOG_KEYWORD_OSSOURCE Indicates that program OS source program
N/A
_PROGRAMINFO_CHANGED information is changed. info gets changed
4.6.11 Output Table 24 lists the keywords, keywords’ definitions, parameter types, and
Control logs sample output messages for the OS source related logs labeled with
LOGLEVEL=0.
Parameter
Keyword Definition Sample output message
type
VOLOG_KEYWORD_OUTPUT_ Best effort setting is enabled or Output control best effort
int
CONTROL_BEST_EFFORT(x) not (0/1) setting enabled: <1>
VOLOG_KEYWORD_OUTPUT_ HDCP is enforced or not(0/1) int Output control HDCP
Parameter
Keyword Definition Sample output message
type
CONTROL_HDCP(x) when using HDMI output enforced: <0>
VOLOG_KEYWORD_OUTPUT_ Airplay anti-mirroring is Output control anti-
int
CONTROL_ANTI_MIRROR(x) enabled or not(0/1) mirroring enabled: <0>
Resolution is downgraded or
VOLOG_KEYWORD_OUTPUT_ Output control CIT digital
not(0/1) when HDCP rule int
CONTROL_CIT_DIGITAL(x) setting enabled: <1>
cannot be enforced
VOLOG_KEYWORD_OUTPUT_
HDMI cable status Output control HDMI
CONTROL_HDMI_CONNECTE int
plugged/unplugged(0/1) connected: <1>
D(x)
VOLOG_KEYWORD_OUTPUT_
Airplay mirroring status Output control Airplay
CONTROL_MIRROR_CONNEC int
connected/disconnected(0/1) mirroring connected: <0>
TED(x)
VOLOG_KEYWORD_OUTPUT_ Output is Output control output
int
CONTROL_BLOCK_OUTPUT(x) blocked/unblocked(0/1) blocked: <0>
4.6.12 RTSP logs Table 25 lists the keywords, keywords’ definitions, parameter types, and
sample output messages for the RTSP related logs labeled with
LOGLEVEL=0.
Parameter
Keyword Definition Sample output message
type
RTSP server connection
VOLOG_KEYWORD_RTSP_SER Information of RTSP server
char*, int address: <102.110.0.8>
VER(x,y) address and port
and port: <80>
RTSP DESCRIBE request
message: <(DESCRIBE
rtsp://rtsp-
VOLOG_KEYWORD_RTSP_DES Information of RTSP DESCRIBE helix.visualon.com/source
char*
CRIBE_REQUEST(x) request string /mp4/mpeg4aac/mpeg4
_d1_1000kbps_30fps_aac_
ste_48khz_128kbps.mp4
RTSP/1.0>
RTSP DESCRIBE response
VOLOG_KEYWORD_RTSP_DES Information of RTSP DESCRIBE
char* message: <(RTSP/1.0 200
CRIBE_RESPONSE(x) response string
OK>
RTSP SETUP request
message: <(SETUP
rtsp://rtsp-
VOLOG_KEYWORD_RTSP_SET Information of RTSP SETUP helix.visualon.com/source
char*
UP_REQUEST(x) request string /mp4/mpeg4aac/mpeg4
_d1_1000kbps_30fps_aac_
ste_48khz_128kbps.mp4/st
reamid=65736 RTSP/1.0>
VOLOG_KEYWORD_RTSP_SET Information of RTSP SETUP RTSP SETUP response
char*
UP_RESPONSE(x) response string message: <(RTSP/1.0 200
Parameter
Keyword Definition Sample output message
type
OK>
RTSP PLAY request
message: <(PLAY
rtsp://rtsp-
VOLOG_KEYWORD_RTSP_PLA Information of RTSP PLAY helix.visualon.com/source
char*
Y_REQUEST(x) request string /mp4/mpeg4aac/mpeg4
_d1_1000kbps_30fps_aac_
ste_48khz_128kbps.mp4/st
reamid=65736 RTSP/1.0>
RTSP PLAY response
VOLOG_KEYWORD_RTSP_PLA Information of RTSP PLAY
char* message: <(RTSP/1.0 200
Y_RESPONSE(x) response string
OK>
RTSP TEARDOWN request
message: <(TEARDOWN
rtsp://rtsp-
VOLOG_KEYWORD_RTSP_TEA Information of RTSP PLAY helix.visualon.com/source
char*
RDOWN_REQUEST(x) request string /mp4/mpeg4aac/mpeg4
_d1_1000kbps_30fps_aac_
ste_48khz_128kbps.mp4
RTSP/1.0>
RTSP TEARDOWN response
VOLOG_KEYWORD_RTSP_TEA Information of RTSP PLAY
char* message: <(RTSP/1.0 200
RDOWN_RESPONSE(x) response string
OK>
RTSP OPTIONS request
message: <(OPTIONS
rtsp://rtsp-
VOLOG_KEYWORD_RTSP_OP Information of RTSP OPTIONS helix.visualon.com/source
char*
TIONS_REQUEST(x) request string /mp4/mpeg4aac/mpeg4
_d1_1000kbps_30fps_aac_
ste_48khz_128kbps.mp4
RTSP/1.0>
RTSP OPTIONS response
VOLOG_KEYWORD_RTSP_OP Information of RTSP OPTIONS
char* message: <(RTSP/1.0 200
TIONS_RESPONSE(x) response string
OK>
RTSP GET_PARAMETER
request message:
<(GET_PARAMETER
rtsp://rtsp-
VOLOG_KEYWORD_RTSP_GET Information of RTSP
char* helix.visualon.com/source
PARAM_REQUEST(x) GET_PARAMETER request string
/mp4/mpeg4aac/mpeg4
_d1_1000kbps_30fps_aac_
ste_48khz_128kbps.mp4
RTSP/1.0>
Information of RTSP RTSP GET_PARAMETER
VOLOG_KEYWORD_RTSP_GET
GET_PARAMETER response char* response message:
PARAM_RESPONSE(x)
string <(RTSP/1.0 200 OK>
VOLOG_KEYWORD_RTSP_GET Information of RTSP GET char* RTSP GET request
Parameter
Keyword Definition Sample output message
type
_REQUEST(x) request string message: <(GET
rtsp://rtsp-
helix.visualon.com/source
/mp4/mpeg4aac/mpeg4
_d1_1000kbps_30fps_aac_
ste_48khz_128kbps.mp4
RTSP/1.0>
RTSP POST request
message: <(POST
rtsp://rtsp-
VOLOG_KEYWORD_RTSP_PO Information of RTSP POST helix.visualon.com/source
char*
ST_REQUEST(x) request string /mp4/mpeg4aac/mpeg4
_d1_1000kbps_30fps_aac_
ste_48khz_128kbps.mp4
RTSP/1.0>
4.6.13 Streaming Table 26 lists the keywords, keywords’ definitions, parameter types, and
logs sample output messages for the streaming related logs labeled with
LOGLEVEL=0.
Sample output
Keyword Definition Parameter type
message
VOLOG_KEYWORD_STREAMI Streaming protocol Streaming protocol:
char*
NG_PROTOCOL(x) type(HLS/DASH/MS-SSTR) <HLS>
VOLOG_KEYWORD_STREAMI Streaming version:
Streaming spec version char*
NG_VERSION(x) <CE708>
VOLOG_KEYWORD_STREAMI All bitrates that streaming Streaming bitrate:
char*
NG_BITRATE(x) contains <200000 bps>
VOLOG_KEYWORD_STREAMI Streaming type:
Streaming type(VoD/Live/DVR) char*
NG_TYPE(x) <Live>
VOLOG_KEYWORD_STREAMI Streaming duration:
Streaming duration information int
NG_DURATION(x) <879932112 ms>
4.6.14 SourceIO Table 27 lists the keywords, keywords’ definitions, parameter types, and
logs sample output messages for the sourceIO related logs labeled with
LOGLEVEL=0.
Sample output
Keyword Definition Parameter type
message
SourceIO proxy
VOLOG_KEYWORD_SOURCEI address:
Proxy address and port char*, int
O_PROXY(x,y) <108.110.0.8> and
port: <8088>
Sample output
Keyword Definition Parameter type
message
SourceIO redirects
from url:
<http://public.infoze
n.cshls.lldns.net/infoz
VOLOG_KEYWORD_SOURCEI Redirection operation occurs en/public/public.m3
char*, char*
O_REDIRECT(x,y) when requesting a normal url u8> to url:
<http://public.infoze
n.cshls.lldns.net/infoz
en/public/public/pu
blic_1000.m3u8>
4.6.15 Subtitle Table 28 lists the keywords, keywords’ definitions, parameter types, and
logs sample output messages for the sourceIO related logs labeled with
LOGLEVEL=0.
Sample output
Keyword Definition Parameter type
message
Indicates external subtitle is Subtitle external
VOLOG_KEYWORD_SUBTITLE_
played, and shows the subtitle char* subtitle URI:
EXTERNAL(x)
URI <http://108.110.0.2>
VOLOG_KEYWORD_SUBTITLE_ Indicates subtitle from Subtitle internal
N/A
INTERNAL streaming source is played subtitle
Indicates the subtitle sepc, like
VOLOG_KEYWORD_SUBTITLE_ Subtitle spec:
TTML, SMPTE-TT, CC608, CC708, char*
SEPC(x) <WEBVTT>
WEBVTT, DVB-Sub, and so on
Indicates the subtitle
VOLOG_KEYWORD_SUBTITLE_ Subtitle container:
container, like TS, MP4, char*
CONTAINER(x) <MP4>
Manifest, ID3
4.6.16 VOME2 Table 29 lists the keywords, keywords’ definitions, parameter types, and
engine logs sample output messages for the VOME2 engine related logs labeled with
LOGLEVEL=0.
Parameter
Keyword Definition Sample output message
type
VOLOG_KEYWORD_VOME2E VOME2 engine <video>
Indicates the buffering starts char*
NGINE_BUFFER_START(x) buffering starts
VOLOG_KEYWORD_VOME2E Indicates the buffering VOME2 engine <video>
char*
NGINE_BUFFER_END(x) completes buffering completes
VOME2 engine Warning:
Indicates the difference AV render time
VOLOG_KEYWORD_VOME2E
between render time and int diff(render time -
NGINE_AV_NSYNC(x)
playback time playback time): <270048
ms>. AV may not be in
Parameter
Keyword Definition Sample output message
type
sync!
Indicates frame dropping may VOME2 engine drops
VOLOG_KEYWORD_VOME2E
cause video play in fast N/A frame may cause video
NGINE_FRAME_DROP
forward play in fast forward
VOME2 engine <video>
VOLOG_KEYWORD_VOME2E Indicates dropping of video
drops frame may cause
NGINE_MODULE_FRAME_DR frame may cause the char*
video play in fast
OP(x) playback in fast forward
forward
VOLOG_KEYWORD_VOME2E Indicate VOME2 engine VOME2 engine
int
NGINE_READ_SOURCE(x) completes succeeds, <11 ms> used
VOLOG_KEYWORD_VOME2E Indicates the information of VOME2 engine <video>
char*
NGINE_NEW_FORMAT(x) new format new format
VOLOG_KEYWORD_VOME2E VOME2 engine <audio>
Indicate the content type char*
NGINE_AV_ONLY(x) only
VOME2 engine <video>
VOLOG_KEYWORD_VOME2E Indicates the content reaches
char* reaches the end of the
NGINE_EOS(x) the end of the source
source
VOME2 engine <audio>
VOLOG_KEYWORD_VOME2E Indicates the time that input
char*, int input timestamp jumps:
NGINE_INPUT_TIME_DIFF(x,y) timestamp jumps
<304600> ms
VOME2 engine <audio>
VOLOG_KEYWORD_VOME2E
Indicates the time that output decoder output
NGINE_DEC_OUTPUT_DIFF(x,y char*, int
timestamp jumps timestamp jumps:
)
<10519> ms
VOME2 engine Warning:
VOLOG_KEYWORD_VOME2E Indicates the audio latency is
int audio latency is too big:
NGINE_LATENCY_ABNM(x) too large
<304600> ms
VOME2 engine <video>
VOLOG_KEYWORD_VOME2E Indicates the time that render
char*, int render timestamp
NGINE_RENDER_DIFF(x,y) timestamp jumps
jumps: <304582> ms
Chapter 5 License
5.2.1 Android See the following for the required code to activate production license on
Android.
InputStream is = null;
byte[] b = new byte[32*1024];
try {
is = context.getAssets().open("voVidDec.dat");
is.read(b);
is.close();
} catch (IOException e) {
e.printStackTrace();
}
m_sdkPlayer.setLicenseContent(b);
5.2.2 iOS See the following for the required code to activate production license on
iOS.
5.2.3 Windows The following is the needed code to activate production license on
plug-in Windows plug-in.
5.2.4 Mac OS See the following for the required code to activate production license on
plug-in Mac OS plug-in.
5.2.5 Chrome See the following for the required code to activate production license for
PPAPI plug-in Chrome PPAPI plug-ins.
Note: Chrome PPAPI only supports activating the production license with
setPreAgreedLicense. The approach of editing the registry key on Windows or
editing Info.plist on Mac OS does not work yet.
5.2.6 Windows See the following for the required code to activate production license on
Phone Windows Phone.
FILE *f;
fopen_s(&f, strFilePath.c_str(), "rb");
fseek(f, 0, SEEK_END);
long fsize = ftell(f);
fseek(f, 0, SEEK_SET);
unsigned char *licenseContent = (unsigned char
*)malloc(fsize);
fread(licenseContent, 1, fsize, f);
fclose(f);
int nRC = m_commonPlayer-
>setLicenseContent(licenseContent, fsize);
nRC = m_commonPlayer->setPreAgreedLicense("License key
here");
free(licenseContent);
Question 1: Why my device cannot play the video with the highest bitrate?
Question 3: How can I create the player for the debug purpose?
Answer 3: The solution may vary depending on the operating system that
you are using.
• Mac OS plug-in: Use the libraries under the Macintosh
/Libs/MacOS/x86/debug directory
• Android: Use the .so files under the \Libs\debug directory and the .jar
files under the \Jar\debug directory in your installation package.
• iOS: Use the .a files under the /Libs/debug directory.
• Windows plug-in: Use the .dll files and configuration files under
\Libs\Win32\debug directory.
Question 4: How can I quickly get started with the features provided by the
OSMP+ product?
Answer 4: The integration Labs, which are compressed into the labs.zip file
under Doc of your installation package, provide working examples to
accompany the OSMP+ Player SDK Integration Guide. The integration Labs
focus on individual integration topics and require installation of the SDK
and license file. Start with README.txt compressed in the labs.zip file to
learn how to use Labs.
Question 5: When an HLS stream is paused, what is the default time that
OSMP+ will buffer?
Answer 5: The buffer time is the sum of maximum buffering time and one
segment. The default maximum buffering time is 20 seconds.
Question 6: When a Live stream is paused, what is the default time that
OSMP+ will buffer?
Answer 6: The buffer time is the sum of maximum buffering time and one
segment. The default maximum buffering time is 20 seconds.
Answer 7: This value varies from the device. We do not have a limitation on
the maximum buffering time.
Answer 8: The preferred audio language supports both ISO 639-1 and ISO
639-2. See Table 30 for the detailed language list.
Events ...................................................................................................................198
API reference
For more information about the OSMP+ API, refer to the API Reference
Manual.zip file under the Doc directory in the installation package.
Events
This section briefly introduces error codes and event IDs used in OSMP+.
Description: No error
VO_OSMP_ERR_EOS
Value: 0X00000001
VO_OSMP_ERR_RETRY
Value: 0X00000002
VO_OSMP_ERR_FORMAT_CHANGE
Value: 0X00000003
VO_OSMP_ERR_AUDIO_NO_NOW
Value: 0X00000010
Suggestion: Status. The audio is not available, and user can choose to play
the video or stop playback.
VO_OSMP_ERR_VIDEO_NO_NOW
Value: 0X00000011
Suggestion: Status. Video is not available, and user can choose to play the
video or stop playback.
VO_OSMP_ERR_FLUSH_BUFFER
Value: 0X00000012
VO_OSMP_ERR_VIDEO
Value: 0X80000004
VO_OSMP_ERR_AUDIO
Value: 0X80000005
VO_OSMP_ERR_OUTMEMORY
Value: 0X80000006
VO_OSMP_ERR_POINTER
Value: 0X80000007
VO_OSMP_ERR_PARAMID
Value: 0X80000008
Suggestion: This is not a fatal error. Stop using the invalid parameter.
VO_OSMP_ERR_STATUS
Value: 0X80000009
Description: Cannot call the requested API under the current status.
VO_OSMP_ERR_IMPLEMENT
Value: 0X8000000A
VO_OSMP_ERR_SMALLSIZE
Value: 0X8000000B
VO_OSMP_ERR_OUT_OF_TIME
Value: 0X8000000C
VO_OSMP_ERR_WAIT_TIME
Value: 0X8000000D
VO_OSMP_ERR_UNKNOWN
Value: 0X8000000E
VO_OSMP_ERR_JNI
Value: 0X8000000F
VO_OSMP_ERR_LICENSE_FAIL
Value: 0X80000011
VO_OSMP_ERR_HTTPS_CA_FAIL
Value: 0X80000012
VO_OSMP_ERR_ARGUMENT
Value: 0X80000013
VO_OSMP_ERR_MULTIPLE_INSTANCES_NOT_SUPPORTED
Value: 0X80000014
VO_OSMP_ERR_UNINITIALIZE
Value: 0X80000101
VO_OSMP_SRC_ERR_OPEN_SRC_FAIL
Value: 0X81000001
VO_OSMP_SRC_ERR_CONTENT_ENCRYPT
Value: 0X81000002
VO_OSMP_SRC_ERR_PLAYMODE_UNSUPPORT
Value: 0X81000003
VO_OSMP_SRC_ERR_ERROR_DATA
Value: 0X81000004
VO_OSMP_SRC_ERR_SEEK_FAIL
Value: 0X81000005
Suggestion: Status. Seek failed. Seek again or skip the seek operation.
VO_OSMP_SRC_ERR_FORMAT_UNSUPPORT
Value: 0X81000006
VO_OSMP_SRC_ERR_TRACK_NOTFOUND
Value: 0X81000007
VO_OSMP_SRC_ERR_NO_DOWNLOAD_OP
Value: 0X81000008
VO_OSMP_SRC_ERR_NO_LIB_OP
Value: 0X81000009
VO_OSMP_SRC_ERR_OUTPUT_NOTFOUND
Value: 0X8100000A
VO_OSMP_SRC_ERR_CHUNK_SKIP
Value: 0X8100000B
VO_OSMP_SRC_ERR_SRC_UNINITIALIZE
Value: 0X80001001
VO_OSMP_HTTP_CONNECT_FAILED
Value: 0x00000000
Suggestion: Status.
VO_OSMP_HTTP_INVALID_RESPONSE
Value: 0x00000001
Suggestion: Status.
VO_OSMP_HTTP_CLIENT_ERROR
Value: 0x00000002
Suggestion: Status.
VO_OSMP_HTTP_SERVER_ERROR
Value: 0x00000003
Suggestion: Status.
VO_OSMP_SRC_ERR_DIVXUNSUPPORTED
Value: 0X8100000D
VO_OSMP_CB_EVENT_ID
VO_OSMP_CB_ERROR
Value: 0X8000000C
VO_OSMP_CB_MULTIPLE_INSTANCES_NOT_SUPPORTED
Value: 0X80000029
VO_OSMP_CB_PLAY_COMPLETE
Value: 0X00000001
VO_OSMP_CB_VIDEO_START_BUFFER
Value: 0X00000003
VO_OSMP_CB_VIDEO_STOP_BUFFER
Value: 0X00000004
VO_OSMP_CB_AUDIO_START_BUFFER
Value: 0X00000005
VO_OSMP_CB_AUDIO_STOP_BUFFER
Value: 0X00000006
VO_OSMP_CB_SRC_BUFFERING_TIME
Value: 0X00000007
VO_OSMP_CB_SEEK_COMPLETE
Value: 0X0000000D
VO_OSMP_CB_VIDEO_ASPECT_RATIO
Value: 0X0000000E
VO_OSMP_CB_VIDEO_SIZE_CHANGED
Value: 0X0000000F
VO_OSMP_CB_CODEC_NOT_SUPPORT
Value: 0X80000010
VO_OSMP_CB_DEBLOCK
Value: 0X00000011
VO_OSMP_CB_HW_DECODER_STATUS
Value: 0X00000013
VO_OSMP_CB_AUTHENTICATION_RESPONSE
Value: 0X00000014
VO_OSMP_CB_LANGUAGE_INFO_AVAILABLE
Value: 0X00000015
VO_OSMP_CB_VIDEO_RENDER_START
Value: 0X00000016
VO_OSMP_CB_OPEN_SRC_COMPLETE
Value: 0X00000017
VO_OSMP_CB_SEI_INFO
Value: 0X00000019
VO_OSMP_CB_AUDIO_RENDER_FAIL
Value: 0X8000001A
VO_OSMP_CB_PCM_OUTPUT
Value: 0X0000001C
Description: This event is issued only when PCM data output is enabled.
VO_OSMP_CB_LICENSE_FAIL
Value: 0X8000001D
VO_OSMP_CB_BLUETOOTHHANDSET_CONNECTION
Value: 0X00001011
VO_OSMP_CB_OUTPUT_CONTROL_BLOCK_PLAYBACK
Value: 0x00000024
VO_OSMP_CB_OUTPUT_CONTROL_BLOCK_OUTPUT
Value: 0x00000025
Suggestion: Status. User can choose to play the video or stop playback.
VO_OSMP_CB_OUTPUT_CONTROL_CHANGE_RESOLUTION
Value: 0x00000026
VO_OSMP_CB_OUTPUT_CONTROL_CAPTURE_SOFTWARE_RUNNING
Value: 0X0000002B
Suggestion: Status. The user can choose to play the video or stop
playback.
VO_OSMP_AD_CB_PLAYLIST_START
Value: 0X03000001
Description: Notify when the player starts displaying the first advertisement
video or content video.
VO_OSMP_AD_CB_PLAYLIST_END
Value: 0X03000002
VO_OSMP_AD_CB_CONTENT_START
Value: 0X03000003
VO_OSMP_AD_CB_CONTENT_END
Value: 0X03000004
VO_OSMP_AD_CB_AD_START
Value: 0X03000005
VO_OSMP_AD_CB_AD_END
Value: 0X03000006
VO_OSMP_AD_CB_VIDEO_PROGRESS
Value: 0X03000007
VO_OSMP_AD_CB_VIDEO_DONE
Value: 0X03000008
VO_OSMP_AD_CB_STATE_CHANGE
Value: 0X03000009
VO_OSMP_AD_CB_PLAYBACKINFO
Value: 0X0300000A
VO_OSMP_AD_CB_NO_AD_CONTENT
Value: 0X8300000B
VO_OSMP_AD_CB_AD_LOAD_ERROR
Value: 0X8300000C
VO_OSMP_AD_CB_VIDEO_NOT_AVAILABLE
Value: 0X8300000D
VO_OSMP_AD_CB_DATA_LOAD_ERROR
Value: 0X8300000E
Description: Notify when the content video experiences a fatal error while
loading or playback
VO_OSMP_AD_CB_VIDEO_GEO_BLOCKED
Value: 0X8300000F
VO_OSMP_SRC_CB_CONNECTING
Value: 0X02000001
VO_OSMP_SRC_CB_CONNECTION_FINISHED
Value: 0X02000002
VO_OSMP_SRC_CB_CONNECTION_TIMEOUT
Value: 0X82000003
VO_OSMP_SRC_CB_CONNECTION_LOSS
Value: 0X82000004
VO_OSMP_SRC_CB_DOWNLOAD_STATUS
Value: 0X02000005
VO_OSMP_SRC_CB_CONNECTION_FAIL
Value: 0X82000006
Suggestion: This is a fatal error for PD module. For Adaptive Streaming, this
is not a fatal error.
VO_OSMP_SRC_CB_DOWNLOAD_FAIL
Value: 0X82000007
VO_OSMP_SRC_CB_DRM_FAIL
Value: 0X82000008
VO_OSMP_SRC_CB_PLAYLIST_PARSE_ERR
Value: 0X82000009
VO_OSMP_SRC_CB_CONNECTION_REJECTED
Value: 0X8200000A
VO_OSMP_SRC_CB_BA_HAPPENED
Value: 0X0200000B
VO_OSMP_SRC_CB_DRM_NOT_SECURE
Value: 0X0200000C
VO_OSMP_SRC_CB_DRM_AV_OUT_FAIL
Value: 0X8200000D
VO_OSMP_SRC_CB_DOWNLOAD_FAIL_WAITING_RECOVER
Value: 0X8200000E
VO_OSMP_SRC_CB_DOWNLOAD_FAIL_RECOVER_SUCCESS
Value: 0X0200000F
VO_OSMP_SRC_CB_OPEN_FINISHED
Value: 0X02000010
VO_OSMP_SRC_CB_CUSTOMER_TAG
Value: 0X02000020
VO_OSMP_SRC_CB_ADAPTIVE_STREAMING_INFO
Value: 0X02000030
VO_OSMP_SRC_CB_ADAPTIVE_STREAMING_ERROR
Value: 0X02000040
VO_OSMP_SRC_CB_ADAPTIVE_STREAM_WARNING
Value: 0X02000050
VO_OSMP_SRC_CB_RTSP_ERROR
Value: 0X02000060
VO_OSMP_SRC_CB_SEEK_COMPLETE
Value: 0X02000070
VO_OSMP_SRC_CB_PROGRAM_CHANGED
Value: 0X02000071
VO_OSMP_SRC_CB_PROGRAM_RESET
Value: 0X02000072
VO_OSMP_SRC_CB_ADAPTIVE_STREAMING_SEEK2LASTCHUNK
Value: 0X02000073
Description: Notify when seeking to the last chunk of playlist (NTS link
without END tag needs change to live mode)
VO_OSMP_SRC_CB_NOT_APPLICABLE_MEDIA
Value: 0X02000074
Description: Network is not available now, but the player still has some
buffer data that can be played.
VO_OSMP_SRC_CB_PD_DOWNLOAD_POSITION
Value: 0X02000075
VO_OSMP_SRC_CB_PD_BUFFERING_PERCENT
Value: 0X02000076
VO_OSMP_SRC_CB_UPDATE_URL_COMPLETE
Value: 0X02000077
VO_OSMP_CB_SYNC_EVENT_ID
This is the enumeration for the callback sync event IDs. These events are
sent from the sub-thread. Do not update UI or call other VisualOn’s API in
callback.
VO_OSMP_SRC_CB_ IO_HTTP_START_DOWNLOAD
Value: 0X04000001
VO_OSMP_SRC_CB_ IO_HTTP_DOWNLOAD_FAIL
Value: 0X04000002
VO_OSMP_SRC_CB_DRM_INIT_DATA
Value: 0X03000004
VO_OSMP_SRC_CUSTOMERTAGID
VO_OSMP_SRC_CUSTOMERTAGID_TIMEDTAG
Value: 0X00000001
Description: The player calls back the time tag of HLS streaming with this
tag ID
VO_OSMP_SRC_CB_IO_HTTP_DOWNLOAD_FAIL
Value: 0X04000002
VO_OSMP_SRC_ADAPTIVE_STREAMING_INFO_EVENT
VO_OSMP_SRC_ADAPTIVE_STREAMING_INFO_EVENT_BITRATE_CHANGE
Value: 0X00000001
VO_OSMP_SRC_ADAPTIVE_STREAMING_INFO_EVENT_MEDIATYPE_CHANGE
Value: 0X00000002
VO_OSMP_SRC_ADAPTIVE_STREAMING_INFO_EVENT_PROGRAM_TYPE
Value: 0X00000003
VO_OSMP_SRC_ADAPTIVE_STREAMING_INFO_EVENT_CHUNK_BEGINDOWNL
OAD
Value: 0X00000004
VO_OSMP_SRC_ADAPTIVE_STREAMING_INFO_EVENT_CHUNK_DROPPED
Value: 0X00000005
VO_OSMP_SRC_ADAPTIVE_STREAMING_INFO_EVENT_CHUNK_DOWNLOAD
OK
Value: 0X00000006
VO_OSMP_SRC_ADAPTIVE_STREAMING_INFO_EVENT_PLAYLIST_DOWNLOAD
OK
Value: 0X00000007
VO_OSMP_SRC_ADAPTIVE_STREAMING_INFO_EVENT_PROGRAM_CHANGE
Value: 0X00000008
VO_OSMP_SRC_ADAPTIVE_STREAMING_INFO_EVENT_FILE_FORMATSUPPORT
ED
Value: 0X00000009
VO_OSMP_SRC_ADAPTIVE_STREAMING_INFO_EVENT_LIVESEEKABLE
Value: 0X0000000A
VO_OSMP_SRC_ADAPTIVE_STREAMING_INFO_EVENT_DISCONTINUE_SAMPLE
Value: 0X0000000B
Description: Indicates that this is the first sample from the discontinue
chunk.
VO_OSMP_SRC_ADAPTIVE_STREAMING_ERROR_EVENT
VO_OSMP_SRC_ADAPTIVE_STREAMING_ERROR_EVENT_PLAYLIST_PARSEFAIL
Value: 0X00000001
VO_OSMP_SRC_ADAPTIVE_STREAMING_ERROR_EVENT_PLAYLIST_UNSUPPOR
TED
Value: 0X00000002
VO_OSMP_SRC_ADAPTIVE_STREAMING_ERROR_EVENT_STREAMING_UNSUPP
ORTED
Value: 0X00000003
VO_OSMP_SRC_ADAPTIVE_STREAMING_ERROR_EVENT_STREAMING_DOWNL
OADFAIL
Value: 0X00000004
Description:
VO_OSMP_SRC_ADAPTIVE_STREAMING_ERROR_EVENT_STREAMING_DRMLIC
ENSEERROR
Value: 0X00000005
VO_OSMP_SRC_ADAPTIVE_STREAMING_ERROR_EVENT_STREAMING_VOLIBLI
CENSEERROR
Value: 0X00000006
VO_OSMP_SRC_ADAPTIVE_STREAMING_WARNING_EVENT
VO_OSMP_SRC_ADAPTIVE_STREAMING_WARNING_EVENT_CHUNK_DOWNL
OADERROR
Value: 0X00000001
VO_OSMP_SRC_ADAPTIVE_STREAMING_WARNING_EVENT_CHUNK_FILEFOR
MATUNSUPPORTED
Value: 0X00000002
VO_OSMP_SRC_ADAPTIVE_STREAMING_WARNING_EVENT_CHUNK_DRMERR
OR
Value: 0X00000003
VO_OSMP_SRC_ADAPTIVE_STREAMING_WARNING_EVENT_PLAYLIST_DOWNL
OADERROR
Value: 0X00000004
VO_OSMP_AVAILABLE_TRACK_TYPE
VO_OSMP_AVAILABLE_PUREAUDIO
Value: 0X00000000
Suggestion: Status. User can choose to play the audio only or stop
playback.
VO_OSMP_AVAILABLE_PUREVIDEO
Value: 0X00000001
Suggestion: Status. User can choose to play video only or stop playback.
VO_OSMP_AVAILABLE_AUDIOVIDEO
Value: 0X00000002
Suggestion: Status.
VO_OSMP_SRC_RTSP_ERROR
VO_OSMP_SRC_RTSP_ERROR_CONNECT_FAIL
Value: 0X00000001
VO_OSMP_SRC_RTSP_ERROR_DESCRIBE_FAIL
Value: 0X00000002
Description:
VO_OSMP_SRC_RTSP_ERROR_SETUP_FAIL
Value: 0X00000003
Description:
VO_OSMP_SRC_RTSP_ERROR_PLAY_FAIL
Value: 0X00000004
Description:
VO_OSMP_SRC_RTSP_ERROR_PAUSE_FAIL
Value: 0X00000005
Description:
VO_OSMP_SRC_RTSP_ERROR_OPTION_FAIL
Value: 0X00000006
Description:
VO_OSMP_SRC_RTSP_ERROR_SOCKET_ERROR
Value: 0X00000007
Description:
VO_OSMP_SRC_RTSP_ERROR_MAX
Value: 0XFFFFFFFF
VO_OSMP_CB_STREAMING_DOWNLOADER_EVENT_ID
This is the enumeration for the callback sync event IDs. This event is sent
from the sub thread. Do not update UI or call other VisualOn’s API in
callback.
VO_OSMP_CB_STREAMING_DOWNLOADER_OPEN_COMPLETE
Value: 0X10000001
Suggestion: Status
VO_OSMP_CB_STREAMING_DOWNLOADER_MANIFEST_OK
Value: 0X10000002
VO_OSMP_CB_STREAMING_DOWNLOADER_END
Value: 0X10000004
VO_OSMP_CB_STREAMING_DOWNLOADER_PROGRAM_INFO_CHANGE
Value: 0X10000005
Suggestion: Status
VO_OSMP_CB_STREAMING_DOWNLOADER_MANIFEST_UPDATE
Value: 0X10000006
Suggestion: Status
VO_OSMP_CB_STREAMING_DOWNLOADER_DOWNLOAD_MANIFEST_FAIL
Value: 0X90000001
VO_OSMP_CB_STREAMING_DOWNLOADER_WRITE_MANIFEST_FAIL
Value: 0X90000002
VO_OSMP_CB_STREAMING_DOWNLOADER_DOWNLOAD_CHUNK_FAIL
Value: 0X90000003
VO_OSMP_CB_STREAMING_DOWNLOADER_WRITE_CHUNK_FAIL
Value: 0X90000004
VO_OSMP_CB_STREAMING_DOWNLOADER_DISK_FULL
Value: 0X90000005
VO_OSMP_CB_STREAMING_DOWNLOADER_GENERATE_MANIFEST_FAIL
Value: 0X90000006
VO_OSMP_CB_STREAMING_DOWNLOADER_LIVE_STREAM_NOT_SUPPORT
Value: 0X90000007
VO_OSMP_CB_STREAMING_DOWNLOADER_LOCAL_STREAM_NOT_SUPPORT
Value: 0X90000008
VO_OSMP_CB_STREAMING_DOWNLOADER_LOCAL_PLAYLIST_INIT_FAIL
Value: 0X90000009
VO_OSMP_CB_STREAMING_DOWNLOADER_LISENCE_CHECK_FAIL
Value: 0X9000000A
VO_OSMP_CB_STREAMING_DOWNLOADER_INIT_IO_FAIL
Value: 0X9000000B
VO_OSMP_CB_STREAMING_DOWNLOADER_SWITCH_STATUS_FAIL
Value: 0X9000000C
VO_OSMP_CB_STREAMING_DOWNLOADER_CHECK_STATUS_FAIL
Value: 0X9000000D
VO_OSMP_CB_STREAMING_DOWNLOADER_CREATE_FOLDER_FAIL
Value: 0X90000010
Cap file.................................................................................................................225
Cap file
The device capability file (cap.xml) is an Extensible Markup Language
(XML) file that specifies the maximum bitrate that the SDK tries to play
when targeting a variant playlist (multiple tracks of the same content) on a
specific type of device. The maximum bitrate defined in the device
capability file overrides the default initial bitrate selection. The maximum
bitrate is also respected by the SDK bitrate adaptation algorithm.
Note: The bitrate cap defined in the cap.xml file is only applied when targeting a
variant playlist. If there is only a single audio or video track, the bitrate cap does
not apply.
White List
OSMP+ offers the option to change the default audio and video hardware
decoding settings for specific devices configurations. The list of devices
configurations (also known as the white list) is saved in the device.xml file
under the assets directory of the Android package.
Refer to 1.4.5.1.2 White List for details about the device.xml file.
Links.......................................................................................................................228
VisualOn Documentation
The following documents, available from your installation package,
provide additional and relevant information. If you cannot find any
document, contact your VisualOn representative.
• API Reference Manual.zip
• Labs.zip
• OnStream MediaPlayer+.Device Capability File AG.pdf
• OnStream MediaPlayer+.Player SDK Integration Guide for Android.pdf
• OnStream MediaPlayer+.SDK Project Setup for Android.pdf
• OnStream MediaPlayer+.Player SDK Integration Guide for iOS.pdf
• OnStream MediaPlayer+.SDK Project Setup for iOS.pdf
• OnStream MediaPlayer+ Plugin SDK Integration Guide for Mac OS.pdf
• OnStream MediaPlayer+ Plugin SDK Integration Guide for
Windows.pdf
• OnStream MediaPlayer+ Plugin UI-Control API Reference.pdf
Links
Refer to the following topics for the references related to separate
platforms when integrating or interfacing with the OSMP+ product.
Note: The links provided were working correctly at the time of publication.
• RFC 3267: Real-Time Transport Protocol (RTP) Payload Format and File
Storage Format for the Adaptive Multi-Rate (AMR) and Adaptive
Multi-Rate Wideband (ARM-WB) Audio Codecs
• RFC 4352: RTP Payload Format for the Extended Adaptive Multi-Rate
Wideband (AMR-WB+) Audio Codec
• RFC 2658: RTP Payload Format for PureVoice (tm) Audio
• MS-RTSP: RTP Payload Format for ASF Streams
• Single File Streaming
• [MS-WMSP]: Windows Media HTTP Streaming Protocol
• Dolby Digital Plus
• Analyzing Display and Performance
• Android Performance Case Study
• Improving Layout Performance
• Improving Your Code with lint
• Optimizing Your UI
• Using the Dev Tools App
• Timed Text Markup Language 1 (TTML)
• WebVtt: The Web Video Text Tracks Format
• FCC Notice