Im trying to stream an mkv container as an flv. I am able to get it working with the following steps
- Code: Select all
step1:
ffmpeg -ss %o -i %s -async 1 -b %bk -s %wx%h -ar 44100 -ac 2 -v 0 -f flv -vcodec libx264 -preset superfast -threads 0 -
step2:
yamdi -i- -o-
However.. strangely enough, even though this works nicely, the bitrate (%b) and size (%w, %h) do nothing whatsoever .. this is the line thats printed out in the log
- Code: Select all
guest listening to "video.mkv"
however, whats funny is that I think the step2 command I have entered is incorrect. Running the yamdi command manually from the cli tells me I need to supply a -t (temp file).
Now if I do supply a temp file in step 2.. I get different output, but no streaming video. Video playback just does not happen.
Heres the output I get.
- Code: Select all
[2013-07-13 15:41:00,397] INFO PlayQueueInputStream - guest listening to "video.mkv"
[2013-07-13 15:41:00,399] DEBUG TranscodeInputStream - Starting transcoder: [/var/subsonic/transcode/ffmpeg] [-ss] [0] [-i] [video.mkv] [-async] [1] [-b] [32k] [-ar] [44100] [-ac] [2] [-v] [0] [-f] [flv] [-vcodec] [libx264] [-preset] [superfast] [-threads] [0] [-]
[2013-07-13 15:41:00,400] DEBUG TranscodeInputStream - Starting transcoder: [/var/subsonic/transcode/yamdi] [-i] [-] [-t] [/tmp/video.tmp] [-o] [-]
im not sure I understand whats happening.. are the transcoders being called in parallel ? likewise Why would it work in the first instance but not in the second. Additionally in the first case, the video can be any size and it pretty much begins to play within a few seconds. I dont know if a tmp file is being generated or not but I cant locate one anywhere. In the second case though, my app just freezes because ffmpeg output seems to be getting stored in the tmp file creating by yamdi and for some reason its never outputted.
with regards to flvtool2 i cant that working whatsoever.. in any case.