Page 1 of 1

No audio when playing THIS MKV through PS3

PostPosted: Wed Apr 13, 2011 3:11 pm
by individual
  Code:
BECONAS> ffmpeg -i City\ of\ Ember\ 2008.mkv
FFmpeg version UNKNOWN, Copyright (c) 2000-2011 the FFmpeg developers
  built on Apr  8 2011 17:16:26 with gcc 4.2.3
  configuration: --arch=arm --enable-armv5te --prefix=/opt --extra-cflags=-I/opt/include --extra-ldflags=-L/opt/lib --enable-static --disable-shared --disable-ffplay --disable-ffserver --enable-libmp3lame
  libavutil     50.36. 0 / 50.36. 0
  libavcore      0.16. 0 /  0.16. 0
  libavcodec    52.108. 0 / 52.108. 0
  libavformat   52.92. 0 / 52.92. 0
  libavdevice   52. 2. 3 / 52. 2. 3
  libavfilter    1.72. 0 /  1.72. 0
  libswscale     0.12. 0 /  0.12. 0
[matroska,webm @ 0xb8ecf0] Estimating duration from bitrate, this may be inaccurate

Seems stream 0 codec frame rate differs from container frame rate: 48.00 (10000000/208333) -> 24.00 (10000000/416666)
Input #0, matroska,webm, from 'City of Ember 2008.mkv':
  Duration: 01:34:43.00, start: 0.000000, bitrate: N/A
    Stream #0.0: Video: h264, yuv420p, 1280x544 [PAR 1:1 DAR 40:17], 24 fps, 24 tbr, 1k tbn, 48 tbc
    Stream #0.1: Audio: aac, 48000 Hz, 5.1, s16
At least one output file must be specified


  Code:
General
Unique ID                        : 236827371253190587776064533017302779143 (0xB22B4AE77C897CE1B9D7E4D05A9DC507)
Complete name                    : Z:\video\Movies\City of Ember 2008\City of Ember 2008.mkv
Format                           : Matroska
File size                        : 1.69 GiB
Duration                         : 1h 34mn
Overall bit rate                 : 2 558 Kbps
Encoded date                     : UTC 2011-04-07 21:22:56
Writing application              : mkvmerge v4.6.0 ('Still Crazy After All These Years') built on Mar 10 2011 02:50:32
Writing library                  : libebml v1.2.0 + libmatroska v1.1.0

Video
ID                               : 1
Format                           : AVC
Format/Info                      : Advanced Video Codec
Format profile                   : High@L4.0
Format settings, CABAC           : Yes
Format settings, ReFrames        : 10 frames
Codec ID                         : V_MPEG4/ISO/AVC
Duration                         : 1h 34mn
Nominal bit rate                 : 2 256 Kbps
Width                            : 1 280 pixels
Height                           : 544 pixels
Display aspect ratio             : 2.35:1
Frame rate                       : 24.000 fps
Color space                      : YUV
Chroma subsampling               : 4:2:0
Bit depth                        : 8 bits
Scan type                        : Progressive
Bits/(Pixel*Frame)               : 0.135
Writing library                  : x264 core 114 r1913 5fd3dce
Encoding settings                : cabac=1 / ref=10 / deblock=1:0:0 / analyse=0x3:0x113 / me=umh / subme=10 / psy=1 / psy_rd=2.00:1.00 / mixed_ref=1 / me_range=32 / chroma_me=1 / trellis=2 / 8x8dct=1 / cqm=0 / deadzone=21,11 / fast_pskip=0 / chroma_qp_offset=-4 / threads=3 / sliced_threads=0 / nr=20 / decimate=1 / interlaced=0 / constrained_intra=0 / bframes=3 / b_pyramid=2 / b_adapt=1 / b_bias=0 / direct=3 / weightb=1 / open_gop=0 / weightp=2 / keyint=250 / keyint_min=24 / scenecut=15 / intra_refresh=0 / rc_lookahead=50 / rc=2pass / mbtree=1 / bitrate=2256 / ratetol=2.0 / qcomp=0.40 / qpmin=10 / qpmax=51 / qpstep=4 / cplxblur=20.0 / qblur=0.5 / ip_ratio=1.40 / aq=1:1.00

Audio
ID                               : 2
Format                           : AAC
Format/Info                      : Advanced Audio Codec
Format profile                   : LC
Codec ID                         : A_AAC
Duration                         : 1h 34mn
Channel(s)                       : 6 channels
Channel positions                : Front: L C R, Side: L R, LFE
Sampling rate                    : 48.0 KHz
Compression mode                 : Lossy


Re: No audio when playing THIS MKV through PS3

PostPosted: Mon Apr 18, 2011 7:09 pm
by Illico

Re: No audio when playing THIS MKV through PS3

PostPosted: Mon Apr 18, 2011 11:17 pm
by zip
It's transcoded, maybe the aBitrate is wrong..? Try enabling detailed logging, play the file and try executing the ffmpeg command from the log manually. Post the command here.

Re: No audio when playing THIS MKV through PS3

PostPosted: Tue Apr 19, 2011 6:39 am
by individual
Attached is the last log file. I must say I can't distingush exactly the command that I am supposed to reproduce manually from the command line - I am also not familiar with linux and command line, so, maybe I'm missing something. Some Playstation renderer lines are at the end of the log.

However, some sound DO comes from the speakers, but it's just "bits" of sounds, a fraction of a seccond long, which occur at a few seconds of silence interval - like someone would play with a broken audio cable and the sound comes only when the cable is not interupted. But the bits of sound are so short that they came out from the speakers like pops and clicks and pufs...

I tried to make a plastic description of what I am hearing, so, bare with me.

Re: No audio when playing THIS MKV through PS3

PostPosted: Tue Apr 19, 2011 7:27 am
by Illico
Serviio use this command line:
ffmpeg -i "/volume1/video/Movies/City of Ember 2008/City of Ember 2008.mkv" -y -vcodec copy -vbsf h264_mp4toannexb -copyts -acodec ac3 -ab 192k -ac 6 -map 0:0 -map 0:1 -sn -f mpegts /volume1/@tmp/Serviio/transcoding-temp-14-MPEG2TS.stf

Try this :
ffmpeg -i "/volume1/video/Movies/City of Ember 2008/City of Ember 2008.mkv" -y -vcodec copy -vbsf h264_mp4toannexb -copyts -acodec ac3 -ab 384k -ac 6 -map 0:0 -map 0:1 -sn -f mpegts /volume1/@tmp/Serviio/transcoding-temp-14-MPEG2TS.stf

Re: No audio when playing THIS MKV through PS3

PostPosted: Tue Apr 19, 2011 11:06 am
by individual
Illico wrote:Try this :
ffmpeg -i "/volume1/video/Movies/City of Ember 2008/City of Ember 2008.mkv" -y -vcodec copy -vbsf h264_mp4toannexb -copyts -acodec ac3 -ab 384k -ac 6 -map 0:0 -map 0:1 -sn -f mpegts /volume1/@tmp/Serviio/transcoding-temp-14-MPEG2TS.stf


Okey, here is the result:
  Code:
NAS> ffmpeg -i "/volume1/video/Movies/City of Ember 2008/City of Ember 2008.mkv" -y -vcodec copy -vbsf h264_mp4toannexb -copyts -acodec ac3 -ab 384k -ac 6 -map 0:0 -map
0:1 -sn -f mpegts /volume1/@tmp/Serviio/transcoding-temp-14-MPEG2TS.stf
FFmpeg version UNKNOWN, Copyright (c) 2000-2011 the FFmpeg developers
  built on Apr  8 2011 17:16:26 with gcc 4.2.3
  configuration: --arch=arm --enable-armv5te --prefix=/opt --extra-cflags=-I/opt/include --extra-ldflags=-L/opt/lib --enable-static --disable-shared --disable-ffplay --disable-ffserver --enable-libmp3lame
  libavutil     50.36. 0 / 50.36. 0
  libavcore      0.16. 0 /  0.16. 0
  libavcodec    52.108. 0 / 52.108. 0
  libavformat   52.92. 0 / 52.92. 0
  libavdevice   52. 2. 3 / 52. 2. 3
  libavfilter    1.72. 0 /  1.72. 0
  libswscale     0.12. 0 /  0.12. 0
[matroska,webm @ 0xb8ecf0] Estimating duration from bitrate, this may be inaccurate

Seems stream 0 codec frame rate differs from container frame rate: 48.00 (10000000/208333) -> 24.00 (10000000/416666)
Input #0, matroska,webm, from '/volume1/video/Movies/City of Ember 2008/City of Ember 2008.mkv':
  Duration: 01:34:43.00, start: 0.000000, bitrate: N/A
    Stream #0.0: Video: h264, yuv420p, 1280x544 [PAR 1:1 DAR 40:17], 24 fps, 24 tbr, 1k tbn, 48 tbc
    Stream #0.1: Audio: aac, 48000 Hz, 5.1, s16
[mpegts @ 0xbee4c0] muxrate VBR, pcr every 100 pkts, sdt every 200, pat/pmt every 40 pkts
Output #0, mpegts, to '/volume1/@tmp/Serviio/transcoding-temp-14-MPEG2TS.stf':
  Metadata:
    encoder         : Lavf52.92.0
    Stream #0.0: Video: [0][0][0][0] / 0x0000, yuv420p, 1280x544 [PAR 1:1 DAR 40:17], q=2-31, 90k tbn, 1k tbc
    Stream #0.1: Audio: ac3, 48000 Hz, 5.1, flt, 384 kb/s
Stream mapping:
  Stream #0.0 -> #0.0
  Stream #0.1 -> #0.1
Press [q] to stop encoding
frame= 3491 fps= 32 q=-1.0 Lsize=   46686kB time=145.33 bitrate=2631.5kbits/s
video:35542kB audio:6822kB global headers:0kB muxing overhead 10.201195%
NAS>

Re: No audio when playing THIS MKV through PS3

PostPosted: Tue Apr 19, 2011 1:26 pm
by Illico
Sorry, I was not clear on my request.(I wish you could add into serviio library the resulting file and check on your TV)
We'll make differently:
Could you edit the profiles.xml file and modify the PS3 section like this (just add aBitrate="384")
And retry to play your movie.
  Code:
   <Profile id="4" name="Playstation 3" extendsProfileId="1">
      <Detection>
         <HttpHeaders>
            <X-AV-Client-Info>.*PLAYSTATION 3.*</X-AV-Client-Info>
         </HttpHeaders>   
      </Detection>
      <MediaFormatProfiles>
         <MediaFormatProfile mime-type="video/divx">AVI</MediaFormatProfile>
      </MediaFormatProfiles>
      <Transcoding>
         <!--
            remux MKV with any video to MPEG2TS and possibly change audio to ac3, also AVI with H264
         -->
         <Video targetContainer="mpegts" targetACodec="ac3" aBitrate="384">
            <Matches container="matroska" />
            <Matches container="avi" vCodec="h264" />
         </Video>
      </Transcoding>
      <LimitImageResolution>false</LimitImageResolution>
   </Profile>

Re: No audio when playing THIS MKV through PS3

PostPosted: Wed Apr 20, 2011 8:15 am
by individual
@illico - After ammending PS3 profile with your suggestion, the sound is normal, loud and clear, without interruptions. Thank you!

I just hope that someone will develop more on the Playstation 3 profile.

Re: No audio when playing THIS MKV through PS3

PostPosted: Wed Apr 20, 2011 8:55 am
by zip
Cool, I'll include it in the profile: https://bitbucket.org/xnejp03/serviio/i ... r-abitrate