# Mediashare video using ffmpeg to convert mov to mpg



## arkmich (Mar 7, 2007)

I have a ViiV pc and am able to stream video and audio using Media Center to my HR22.

My videos which were originally encoded as mpeg play just fine.

I have some videos which are encoded as .mov (quicktime) and I am converting these to mpeg so they can play on the HR22 as well.

I've been able to convert them successfully and play them on the HR22, except these ones don't have trickplay enabled, and they don't show the total time of the video.

When I look at them even on the PC, they don't show the total time of the video there either, and even in Windows Media Player (WMP), they show as "0 seconds" in the library views (although when I play them in WMP, the duration shows).

So, I'm guessing I'm doing something wrong in the conversion which is corrupting some information in the file which WMP and Media Center and Mediashare need to display the duration and also to enable trickplay.

Here's the command I'm using in ffmpeg (below). If there are any experts out there who can help me tweak this so I can convert these files into mpeg ones which contain the duration, that would be great.


ffmpeg.exe -i ivs_ramblinman_eg.mov -threads 2 -f mpegts -b 2400k -s 720x480 -vcodec mpeg2video -acodec ac3 ramblinman.mpg


----------



## bhelton71 (Mar 8, 2007)

arkmich said:


> I have a ViiV pc and am able to stream video and audio using Media Center to my HR22.
> 
> My videos which were originally encoded as mpeg play just fine.
> 
> ...


At a glance your commandline doesn't look bad (little conservative on the bitrate ) - what are the original encoding parameters (codecs, bitrates, framerate, etc) on the mov file ? Just curious if something is confusing the encoder.


----------



## arkmich (Mar 7, 2007)

bhelton71 said:


> At a glance your commandline doesn't look bad (little conservative on the bitrate ) - what are the original encoding parameters (codecs, bitrates, framerate, etc) on the mov file ? Just curious if something is confusing the encoder.


Here (below) is the info I get when I just to an ffmpeg -i on the original file.

I've tried a few things, to no avail:
- converting first to program stream and then using streamclip to convert to TS
- dropping and/or changing the options for bitrate and size
- using "-target ntsc-dvd" instead of the bitrate and size commands

Also, the reason I'm really wanting FF/RW to work on these files is that they're guitar video lessons and I'm always wanting to go back a few seconds to review a section of a song. FYI, these are lessons I've purchased online from iVideosongs, whcih has great lessons (even some by the original artists) for a phenomenal value, in case anyone's interested. I currently use them on my desktop, and am looking forward to being able to use them on my TV through the HR22.

Thanks for taking a look.

FFmpeg version 0.5, Copyright (c) 2000-2009 Fabrice Bellard, et al.
configuration: --enable-gpl --enable-postproc --enable-swscale --enable-avfilter --enable-avfilter-lavf --enable-pthre
ads --enable-avisynth --enable-libfaac --enable-libfaad --enable-libmp3lame --enable-libspeex --enable-libtheora --enabl
e-libvorbis --enable-libxvid --enable-libx264 --enable-memalign-hack
libavutil 49.15. 0 / 49.15. 0
libavcodec 52.20. 0 / 52.20. 0
libavformat 52.31. 0 / 52.31. 0
libavdevice 52. 1. 0 / 52. 1. 0
libavfilter 0. 4. 0 / 0. 4. 0
libswscale 0. 7. 1 / 0. 7. 1
libpostproc 51. 2. 0 / 51. 2. 0
built on Mar 16 2009 16:09:18, gcc: 4.2.4 [Sherpya]
[mov,mp4,m4a,3gp,3g2,mj2 @ 0x1519770]multiple edit list entries, a/v desync might occur, patch welcome

Seems stream 0 codec frame rate differs from container frame rate: 59.94 (5994/100) -> 29.97 (30000/1001)
Last message repeated 2 times
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'ivs_ramblinman_eg.mov':
Duration: 01:23:19.36, start: 0.000000, bitrate: 536 kb/s
Stream #0.0(eng): Video: h264, yuv420p, 960x540, 29.97 tbr, 29.97 tbn, 59.94 tbc
Stream #0.1(eng): Audio: aac, 48000 Hz, stereo, s16
Stream #0.2(eng): Data: tmcd / 0x64636D74
Stream #0.3(eng): Subtitle: text / 0x74786574
At least one output file must be specified


----------

