Jump to content

Convert recordings to MKV option removed?


Kramerika

Recommended Posts

Kramerika

I searched for a topic related to this, but did not find one.  I apologize if it was addressed elsewhere.  I have had the option checked to DVR live TV as MKV files for a long time.  The latest update seems to have removed that option as all my recordings are now in the larger TS format.  I don't see the option, so I assumed it was removed?  Just wondering why.

Edited by Kramerika
Link to comment
Share on other sites

It hasn't been a stable option for a few reasons:

  • You can't seek while playing in-progress recordings to mkv
  • Some audio/subtitle tracks get lost from the original stream
  • Some players have difficulty with the resulting mkv

We put in a lot of effort to resolve these issues but we always found that anytime we resolved it for one user's live tv stream, it inevitably caused a problem for someone else. So that's why we decided to stop doing the on the fly recording conversion.

 

We have replaced this with a new convert media feature that you can use after the recording has occurred. You can learn more about it by checking out the release announcement:

https://emby.media/community/index.php?/blog/1/entry-423-emby-server-34-released/

 

It is a brand new feature so we realize it's not perfect yet, please feel free to create feature requests for additional things you'd like to see related to it. Thanks !

Link to comment
Share on other sites

Kramerika

Besides not having any issues with MKV recordings lately, my main concern is the size when stored for the sake of hard drive space.  I generally don't save them, and if I did, I would process them through Handbrake on my own.  In my experience, the TS files tend to be 1.5 - 2 times as large as the MKV files.  I'll just have to be more diligent about deleting them.  I can't report on how TS files perform versus my experience with MKV files yet as I have not watched enough recordings with the TS format, but if I have issues, I will report them here.

Link to comment
Share on other sites

You may want to try the convert media feature to convert to mkv or mp4.

Link to comment
Share on other sites

hstamas

Ah man. This was one of the reasons I gave up on Plex DVR. For some reason my Kodi install does not play back TS files as well as it does MKV so I definitely want the conversion but don't want to deal with having to get rid of TS files all the time due to space limitations. Is there a way to have this convert (after the fact is fine) but have it delete the original TS file after its done? Does Emby support post processing scripts as an option? I don't remember?

Link to comment
Share on other sites

Ah man. This was one of the reasons I gave up on Plex DVR. For some reason my Kodi install does not play back TS files as well as it does MKV so I definitely want the conversion but don't want to deal with having to get rid of TS files all the time due to space limitations. Is there a way to have this convert (after the fact is fine) but have it delete the original TS file after its done? Does Emby support post processing scripts as an option? I don't remember?

 

Try our convert media feature. We will be adding an option to delete the original. Thanks.

Link to comment
Share on other sites

hstamas

Try our convert media feature. We will be adding an option to delete the original. Thanks.

 

Great @@Luke. I'll watch for that to be implemented before I jump to v3.4 and let you all know how it works.

 

What does Emby do now out of curiosity? It it converting on the fly as its being recorded? I know I hear my computers fans speed up at the end of a show recording but it only lasts a few minutes.

Link to comment
Share on other sites

  • 3 months later...
Kramerika

We have replaced this with a new convert media feature that you can use after the recording has occurred. You can learn more about it by checking out the release announcement:

https://emby.media/community/index.php?/blog/1/entry-423-emby-server-34-released/

 

Sorry to dig up an old post, but I finally got around to trying the conversion feature.  It does not work for me.  I go to the media browser in a web browser on my PC.  I am logged in with my admin account.  I click on a folder with recordings, choose convert from the options, and set the convert options.  I click "Convert" and it closes the windows and syncs.  Nothing happens to the files in the folder.  I open the convert options again and they are reset to the default.  This account has access to do everything on the server in terms of control including "allow media conversion".  What am I doing wrong?

Link to comment
Share on other sites

Kramerika

ok, it finally did the conversion.  So it won't save my settings and I have to go back and do this every so often instead of it doing it automatically?  That would be annoying.  When I look at the settings for that folder, they are back to default.

 

It also converted the AC3 audio to AAC.  Any way to prevent that?  I just want to convert the video to a lower bitrate (smaller size) but leave the audio alone.

 

Ultimately the way that I would like it to behave is that I set it for all files in a particular folder to be converted automatically after a recording is finished to MKV or MP4 with a lower bitrate but leaving the audio alone.  I don't want to constantly have to manage it but want the files to always be stored in a smaller size beyond their initial recorded size but with the same audio format.  How do I set it to do this?

Edited by Kramerika
Link to comment
Share on other sites

jasonmcroy

ok, it finally did the conversion.  So it won't save my settings and I have to go back and do this every so often instead of it doing it automatically?  That would be annoying.  When I look at the settings for that folder, they are back to default.

 

It also converted the AC3 audio to AAC.  Any way to prevent that?  I just want to convert the video to a lower bitrate (smaller size) but leave the audio alone.

 

Ultimately the way that I would like it to behave is that I set it for all files in a particular folder to be converted automatically after a recording is finished to MKV or MP4 with a lower bitrate but leaving the audio alone.  I don't want to constantly have to manage it but want the files to always be stored in a smaller size beyond their initial recorded size but with the same audio format.  How do I set it to do this?

 

You can't do that currently. I have asked for this over and over and it still isn't implemented. I just want a simple remux to ,mkv with audio untouched but for some reason it doesn't get paid attention to as important enough to implement even though I feel like it's an easy thing to put in.

 

For this reason I have to rely on MCEBuddy to do it for me (it takes like 4 minutes to do this on an hour long recording) because the Emby solution takes about an hour and uses too much of my cpu while doing it because it transcodes the file.

Link to comment
Share on other sites

hstamas

If anyone is looking for simple remuxing, attached here is a post process script that someone set up for me when I was using Plex that seems to be working fine with Emby. Just make sure you have FFMPEG installed. Edit the script line where it points to FFMPEG and then point to this script under your DVR settings in Emby Server.

 

 Comcast in my area broadcasts in h.264 and Emby is saving as a .ts file. For what ever reason my Kodi installation does not play .ts files back smoothly so I am remuxing them to a .mkv  file and all works well.

 

Postprocess 2.sh.zip

  • Like 1
Link to comment
Share on other sites

jasonmcroy

If anyone is looking for simple remuxing, attached here is a post process script that someone set up for me when I was using Plex that seems to be working fine with Emby. Just make sure you have FFMPEG installed. Edit the script line where it points to FFMPEG and then point to this script under your DVR settings in Emby Server.

 

 Comcast in my area broadcasts in h.264 and Emby is saving as a .ts file. For what ever reason my Kodi installation does not play .ts files back smoothly so I am remuxing them to a .mkv  file and all works well.

 

attachicon.gifPostprocess 2.sh.zip

 

Thank you very much for this! I have been trying to figure out how to do this and haven't been able to. This will help me a lot since I consider MCEBuddy overkill for what I need it for.

Link to comment
Share on other sites

Kramerika

That's a bummer that there is no way to do it directly.  I am more familiar with Handbrake, and I am using Windows for the server.  I can use HandbrakeCLI as a post-processing application with command line options.  It works to convert the recording and maintain the audio, but I need it to also delete the original file at the least as the point is to save disk space without having to monitor it.  I tried using a batch file as the post-processing application with the call to Handbrake and another call to delete the original file, but it didn't work.

Edited by Kramerika
Link to comment
Share on other sites

jasonmcroy

Thank you very much for this! I have been trying to figure out how to do this and haven't been able to. This will help me a lot since I consider MCEBuddy overkill for what I need it for.

 

If anyone is looking for simple remuxing, attached here is a post process script that someone set up for me when I was using Plex that seems to be working fine with Emby. Just make sure you have FFMPEG installed. Edit the script line where it points to FFMPEG and then point to this script under your DVR settings in Emby Server.

 

 Comcast in my area broadcasts in h.264 and Emby is saving as a .ts file. For what ever reason my Kodi installation does not play .ts files back smoothly so I am remuxing them to a .mkv  file and all works well.

 

attachicon.gifPostprocess 2.sh.zip

 

I guess I spoke too soon. I downloaded and realized this is a script for Linux and I am on Windows currently. So, back to the drawing board...

Link to comment
Share on other sites

Kramerika

If you want to try Handbrake CLI, you can download it here.

 

https://handbrake.fr/downloads2.php

I am trying to use it for the DVR section of Emby for the post processing app.  Here are the command line options that I am using to compress it more but pass-through the audio.

 

-i "{path}" -o "{path}".mkv -f av_mkv -a 1 -E copy:ac3 -e x264 -q 22.0 --cfr -r 29.97 --loose-anamorphic --encoder-preset medium --encoder-profile high --encoder-level 4.1
 
That much works.  The problem is that I need a way to automate the deletion of the original file.
  • Like 1
Link to comment
Share on other sites

jasonmcroy

 

If you want to try Handbrake CLI, you can download it here.

 

https://handbrake.fr/downloads2.php

I am trying to use it for the DVR section of Emby for the post processing app.  Here are the command line options that I am using to compress it more but pass-through the audio.

 

-i "{path}" -o "{path}".mkv -f av_mkv -a 1 -E copy:ac3 -e x264 -q 22.0 --cfr -r 29.97 --loose-anamorphic --encoder-preset medium --encoder-profile high --encoder-level 4.1
 
That much works.  The problem is that I need a way to automate the deletion of the original file.

 

 

Thanks, I will try it out.

 

How long does a conversion normally take for you?

Link to comment
Share on other sites

mastrmind11

 

If you want to try Handbrake CLI, you can download it here.

 

https://handbrake.fr/downloads2.php

I am trying to use it for the DVR section of Emby for the post processing app.  Here are the command line options that I am using to compress it more but pass-through the audio.

 

-i "{path}" -o "{path}".mkv -f av_mkv -a 1 -E copy:ac3 -e x264 -q 22.0 --cfr -r 29.97 --loose-anamorphic --encoder-preset medium --encoder-profile high --encoder-level 4.1
 
That much works.  The problem is that I need a way to automate the deletion of the original file.

 

wouldn't this do it? 

-i "{path}" -o "{path}".mkv -f av_mkv -a 1 -E copy:ac3 -e x264 -q 22.0 --cfr -r 29.97 --loose-anamorphic --encoder-preset medium --encoder-profile high --encoder-level 4.1 && rm {path} 

the && directive will execute the following command only if the first command exited successfully.

Edited by mastrmind11
Link to comment
Share on other sites

Kramerika

I can't get that to work. It is executing Handbrake and converting the file, but it does not delete the original file.  Should that be "del" rather than "rm"?  I am going to try del.

Edited by Kramerika
Link to comment
Share on other sites

mastrmind11

I can't get that to work. It is executing Handbrake and converting the file, but it does not delete the original file.  Should that be "del" rather than "rm"?  I am going to try del.

No clue.  I assumed it was a linux system, in which case it's rm.  You can also try writing a shell script that takes the path arg and does something with it, then just call the script w/ whatever.sh {path}.  I have not tried any post processing w/ emby but scripts are pretty universal.  if you're windows, then I'm of no help, gave up on that garbage decades ago.

Link to comment
Share on other sites

hstamas

I guess I spoke too soon. I downloaded and realized this is a script for Linux and I am on Windows currently. So, back to the drawing board...

My bad guys. This was written for me and I’m on a Mac. I assumed scripts like this were pretty universal OS wise but I really don’t know.

Link to comment
Share on other sites

jasonmcroy

My bad guys. This was written for me and I’m on a Mac. I assumed scripts like this were pretty universal OS wise but I really don’t know.

 

No need to apologize to me - you were trying to help and I appreciate it. It lead me down a path to try again to figure out how to create a batch file to do this on Windows. However, I can't seem to figure it out. 

 

Oh well, hopefully one day it will be included in the Live TV section as an option...

Link to comment
Share on other sites

Kramerika
I am on Windows.  As a batch file, this works (substituting the actual file names), but through the post processing in Emby DVR, it does not.  Is it not passing {path} to the second command?

 

HandBrakeCLI -i "{path}" -o "{path}".mkv -f av_mkv -a 1 -E copy:ac3 -e x264 -q 22.0 --cfr -r 29.97 --loose-anamorphic --encoder-preset medium --encoder-profile high --encoder-level 4.1 && del "{path}"

Edited by Kramerika
Link to comment
Share on other sites

jasonmcroy

@@jasonmcroy and others you will probably find this post interesting and useful (hopefully)  ;)

 

https://emby.media/community/index.php?/topic/62567-post-processing-script-working-example-powershell/

 

Thanks @@PenkethBoy - I will play around with this a little later on today and let you know how it goes. It looks like there is a lot of potential here!

  • Like 1
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...