Jump to content

Option to record in mkv and/or mp4 file container


nars

Recommended Posts

Hi,

 

What about having an option to allow recording in mkv and/or mp4 file container? TS is a bit "problematic" to open on thirdparty apps, and mpg cannot be used for h264/aac apparently (it always saves on TS if I select mpg option).

 

Keep up the good work :biggrin:

 

Regards,

 

nars

Link to comment
  • 3 weeks later...

Are there already DVB apps offering MKV as recording format? I wonder if the container is suitable for it, since recording is very different from file conversion. The recorder has to do everything "on the fly" in push mode (which means it doesn't fetch data on demand, but the data is pushed into the recorder), and there is no possibility to look ahead.

Link to comment

No idea if there are any other DVB apps offering it as I don't use any other than DVBViewer ;)

 

Also I can not even find a working converter to convert my TS files (with H264 + LATM/LOAS AAC audio) to MKV, nor a working directshow splitter that supports such kind of audio ;)

Link to comment

Just tested the trial and indeed it works fine, thank you for the info ;) Despite a free solution like Haali Splitter supporting it would be obviously better but at least it is a solution.

Link to comment
  • 2 weeks later...
I wonder if the container is suitable for it

yes, it is suitable.

mpeg4 ts can be converted to mkv container by gdsmux.exe of haali splitter.

changing container = without reencoding.

 

The recorder has to do everything "on the fly"

it is possible do add feature that converts ts to mp4 or mkv automatically after recording?

it can be done also with external utility, also with paid utility if it costs under 10 euros.

ts files has so bad access time on my athlon 1.8 and western digital green power 5400 rmp hdd that it is not suitable for news and music channels, because they need a lot of jumpings during the wathing.

I agree that this feature pays 20 euros if it works stable.

Link to comment
mpeg4 ts can be converted to mkv container by gdsmux.exe of haali splitter.

 

Not possible for Portuguese (and other european) DVB-T streams using LATM/LOAS HE-AAC as gdsmux of haali splitter will not detect/demux the audio.

Link to comment
Not possible for Portuguese (and other european) DVB-T streams using LATM/LOAS HE-AAC as gdsmux

but it works with satellite channels that i watch.

i don't mean that must use exactly this utility, i just gave an example.

Link to comment
  • 5 weeks later...
  • 3 years later...

Are there already DVB apps offering MKV as recording format? I wonder if the container is suitable for it, since recording is very different from file conversion. The recorder has to do everything "on the fly" in push mode (which means it doesn't fetch data on demand, but the data is pushed into the recorder), and there is no possibility to look ahead.

 

Sorry to bump this old topic, but re-replying you: tvheadend offers it by default (it's possible to select either mkv or ts) and I do find the mkv to work better with my wd tv live for eg. as with ts it doesn't support to seek on the file and shows running and total time always as 00:00:00 :( Also tvheadend is opensource then you can probably easily look how it is made ;)

Link to comment

Sorry to bump this old topic, but re-replying you: tvheadend offers it by default (it's possible to select either mkv or ts) and I do find the mkv to work better with my wd tv live for eg. as with ts it doesn't support to seek on the file and shows running and total time always as 00:00:00 :( Also tvheadend is opensource then you can probably easily look how it is made ;)

Re-bump tvheadend is a different "engine" that runs exclusively on *nux it's possible to add a convert task after the recording and delete the *.ts file after conversion, probably isn't implemented natively because it breaks dvb subtitles and other sub streams or because mkv isn't free for commercial applications.Just read from matroska file and it's free.

Edited by DunnoX
Link to comment

There are no plans to record in anything other than mpeg or ts. There is simply IMHO no need for it.

You can always define an after recording task which converts the file and deletes the old. You just need to write the program.

Link to comment

ok, thanks for your replies. Then if anybody knows a good solution to convert ts to mkv (supporting h264/aac(latm)) without recompression please post it... I'm digging for it... so far I have been experimenting with ffmpeg with something like ffmpeg -i input.ts -sn -vcodec copy -acodec copy -r 25 -f matroska output.mkv (had to use -r else it would set the mkv as being 59fps for some weird reason) also tried with -absf aac_adtstoasc but no go... I do always get a file without audio, the only way I can get audio is to recode it (what is not what I'm looking for) or convert it to pcm with -acodec pcm_s16le but... :( I may post for help on this somewhere related to ffmpeg guys.... anyway if anybody knows another tool to do what I want it will be very appreciated, else I will need to continue recording on tvheadend to be able to play the recordings properly on my wd tv live and can't play properly some few old ones recorded with DVBViewer :(

Edited by nars
Link to comment

Try extracting (demultiplexing) the audio and video stream from the .TS file and then use mkvtoolnix (not sure if it works) and your ffmpeg line is incorrect if you copy vcodec and acodec ffmpeg doesn't output mkv (don't ask me why I hadn't had my coffee yet) and it gives you fake 59fps probably because source is interpolated.

Edited by DunnoX
Link to comment
  • 2 weeks later...

Didn't tried demultiplexing, converting audio and remultiplexing with mkvtoolnix yet.. but just found that latest ffmpeg build from git doesn't need the -r anymore, it now detects framerate properly, also despite not perfect solution, I'm currently using it to easily convert my ts's to mkv by just re-compressing audio, to be able to play on wdtv properly, i.e. I do just use:

 

ffmpeg -i input.ts -sn -vcodec copy -acodec libvo_aacenc output.mkv

 

it takes near 5 min to recompress audio on 1h30m files, not that bad... ffmpeg includes code to handle/decode latm aac, however if we just 'copy' such latm aac audio to mkv then almost nothing will play audio on such mkv file... while using ffmpeg to recompress audio to aac will output non latm aac recompessed audio, and that surely doesn't have any problems to be played... also after talking with some guys on ffmpeg irc channel about this following their suggestion I did created an enhancement ticket on ffmpeg trac about eventually making a way to have a filter option allowing to convert latm to raw aac with 'copy' option on ffmpeg, without needing to re-compress audio, the ticket is at:

https://ffmpeg.org/trac/ffmpeg/ticket/2439#propertyform

 

Also if I want a really fast way to convert files just temporarily to play on wdtv I can also just convert audio to pcm with:

ffmpeg -i input.ts -sn -vcodec copy -acodec pcm_s16le output.mkv

 

Not perfect solution for sure, but ok for me so far... just wanted to post it to sum what I'm doing for the case it may help someone else...

 

P.S. If anyone else also looking for same I do, please vote and/or comment my ticket on ffmpeg trac, maybe it get's implemented ;)

Link to comment
  • 4 weeks later...
  • 2 weeks later...

I wonder if the container is suitable for it

I have been told (by the VideoReDo people) that it does not officially support subtitles so, although they do work, the answer is probably not at this time, especially while most mkv editors do not pass through subtitles if they exist in mkv files.

Link to comment
  • 4 weeks later...

Hi,

I use several tool to convert ts to mkv and keep the DVB subpictures.

My favourite is Handbrake for conversion to mkv. Very usefull when the video stream isn't perfect at all, it can keep the sync between audio and video, dropping the bad video frames.

When I'm sure the recording is perfect, I can use also Ripbot.

To keep the DVB subpics, I rip them from TS using ProjectX, save them as .sub + idx

Finally I mux file.mkv + files.sub using MKVmerge.

Often the subtitles are problematic, but the result isn't so bad.

All apps are free.

Regards.

Link to comment
  • 6 months later...

Maybe DVB Recording service should have option record to application (like DV scheduler has). It has settings file where You can define recording formats. Defaults are like DVB recording service - TS. But also possible to define additional format - command line application ffmpeg which accepts direct input and You can define output format (ffmpeg -i - -y myfile.mkv)

 

This will solve problems with wanted formats that recorder does not provide. And responsibility for video on conversion will go to end user.

 

For me - I do recording for 3-5 hrs and then waiting for conversion end takes time.

What do You think?

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...