Subtitles in Tizen TV Emulator

992 views Asked by At

I am developing an application using AVPlay API. I could play the video URL successfully, however the subtitles do not work. They are working in the VLC Player. (See the image below.)

I am using the following code to get the stream properties, but cannot see anything related to the subtitles.

How can I display the subtitles in the emulator? Thanks in advance...

getCurrentStreamInfo: function() {
    var streamInfo = webapis.avplay.getCurrentStreamInfo();
    var text = '';
         for (var i = 0; i < streamInfo.length; i++) {
         text += 'index: ' + streamInfo[i].index + '';
         text += 'type: ' + streamInfo[i].type + '';
         text += 'extra_info: ' + streamInfo[i].extra_info + '';
    }
    info.innerHTML = text;
},

However, I see the following when displaying the stream info in VLC Player

enter image description here

2

There are 2 answers

0
Widmo On

My working one-liner, Camera: DAHUA EZ-IP IPC-D2B40-0360B

Solution: convert RTSP to Samsung TIZEN, SipTV App.

#!/bin/bash

/usr/bin/ffmpeg -fflags nobuffer \
 -rtsp_transport tcp \
 -i "rtsp://admin:[email protected]:554/cam/realmonitor?channel=1&subtype=0" \
 -acodec libfaac -ar 48000 -ab 128k -ac 2 -vcodec libx264 -s 640x480 -b 512k -scodec mov_text \
 -f segment \
 -hls_flags delete_segments \
 -segment_wrap 10 \
 -segment_list_flags live \
 -segment_time 1 \
 -segment_list_size 1 \
 -segment_format mpegts \
 -segment_list /var/www/html/cctv/cctv.m3u8 \
 -segment_list_type m3u8 \
 -segment_list_entry_prefix /cctv/stream/ \
 /var/www/html/cctv/stream/%d.ts

It is nice to use RAMDisk, to store chunks.

1
Markus Schumann On

It looks like you are playing back an MPEG-2 Transport Stream with DVB subtitles which is not a supported format according to http://www.samsung.com/us/support/answer/ANS00049952/

I'd use FFMPEG to transcode your file to a format that the TV/emulator can play back.

I'd start with: ffmpeg -i YOUR_FILE -acodec libfaac -ar 48000 -ab 128k -ac 2 -vcodec libx264 -s 640x480 -b 512k -scodec mov_text output.mp4

Likely you have to do some try and error finding the ffmpeg output that plays with subtitles in the emulator. There a number of formats that ffmpeg can write and that are on the list at http://www.samsung.com/us/support/answer/ANS00049952/