VideoHelp Forum




+ Reply to Thread
Page 2 of 2
FirstFirst 1 2
Results 31 to 42 of 42
  1. Originally Posted by poisondeathray View Post
    Originally Posted by Miti View Post
    Just to make sure - if the original files are about 3 gb, what would you expect the new outputfile to be at with the current settings?
    Impossible to say

    The only thing you can say for certain, is lower CRF values will yield larger filesizes

    When you use crf encoding, it's 1 pass "quality" based, and the bitrate will depend on content complexity

    Usually, if you have complex content (difficult to compress), eg. lots of motion, lots of noise, filesizes will be larger

    I see. I ask since the file thus far is over 1 gb, which will make the output file about 15 gb. Wondering whether that could be right and I guess it can.

    I must say you guys have been really helpful and I am impressed by your knowledge. However, it is strange that it is so difficult for me to get a decent looking video in mp4 in this day and age without seeking expert advice and downloading various programs for testing. Sigh...

    I do see why you find it interesting though!
    Quote Quote  
  2. Originally Posted by Miti View Post


    I see. I ask since the file thus far is over 1 gb, which will make the output file about 15 gb. Wondering whether that could be right and I guess it can.

    Not necessarily true either. If your video is front heavy (more action in the beginning), it might only be 5 GB. Or if it has more action at the end it might be 20GB. The content complexity determines the filesize when you use use CRF encoding

    If after some encodes, you're getting consistently too large in filesize encodes for your tastes, try increasing the CRF value


    An easier to use GUI would be handbrake or vidcoder. There are GUI's for ffmpeg like Tencoder, ffqueue.

    But if you use any of these GUI's and if you're going to deinterlace, make sure you "double rate" deinterlace or "bob" deinterlace it's sometimes called; otherwise you will get choppy motion with 1/2 the motion samples
    Quote Quote  
  3. Originally Posted by racer-x View Post
    If compatibility across multiple devices is a concern, I would go with this script instead:
    Code:
    SET PATH="C:\FFMpeg"
    for %%a in ("*.mts") do ffmpeg -i "%%a" -vf yadif=mode=1:parity=tff -s 1280x720 -c:v libx264 -level 41 -pix_fmt yuv420p -preset medium -crf 19 -c:a aac -strict experimental -ar 48000 -ab 256k -f mp4 "%%~na.mp4"
    
    pause

    So far I have had the best luck using the code above in terms of output, conversion time and ability to watch on different devices. A couple of questions:

    1) Will the quality be even better on -crf 16 or 15? And how low can I go without risking that some athletes might not be able to watch it?

    2) How can I merge the output files (mp4) without quality loss (or learning curve). A quick Google takes me to mp4joiner - has anyone got experience with this?
    Quote Quote  
  4. Originally Posted by Miti View Post
    Originally Posted by racer-x View Post
    If compatibility across multiple devices is a concern, I would go with this script instead:
    Code:
    SET PATH="C:\FFMpeg"
    for %%a in ("*.mts") do ffmpeg -i "%%a" -vf yadif=mode=1:parity=tff -s 1280x720 -c:v libx264 -level 41 -pix_fmt yuv420p -preset medium -crf 19 -c:a aac -strict experimental -ar 48000 -ab 256k -f mp4 "%%~na.mp4"
    
    pause

    So far I have had the best luck using the code above in terms of output, conversion time and ability to watch on different devices. A couple of questions:

    1) Will the quality be even better on -crf 16 or 15? And how low can I go without risking that some athletes might not be able to watch it?

    2) How can I merge the output files (mp4) without quality loss (or learning curve). A quick Google takes me to mp4joiner - has anyone got experience with this?
    So I tried a bit and concluded this: I can not tell the difference between -crf 15 and 19, so I went with 19 for the end product. Also I joined the files with mp4joiner and it worked well.

    Now to the next problem. Sideline is an analyzing tool that also allows me to export new video clips the way I need to. Some athletes need certain clips, other athletes need different ones. But when I try to export clips I get an error saying that the key frames are to far apart to proceed with accurate cutting. This does not happen with normal mp4s. Is there anyway to solve this in the code given by racer-x? Is something in the code connected to key frames?
    Last edited by Miti; 18th Feb 2015 at 06:50.
    Quote Quote  
  5. Banned
    Join Date
    Oct 2014
    Location
    Northern California
    Search PM
    Originally Posted by Miti View Post
    Now to the next problem.
    Your workflow creates instead of solves problems.

    What is the point in going through hoops to get the best format and then cut it up and render the parts again?

    Just take the original source and then edit and render to all files you need to deliver.

    One step should do it!
    Quote Quote  
  6. Originally Posted by Miti View Post


    So far I have had the best luck using the code above in terms of output, conversion time and ability to watch on different devices. A couple of questions:

    1) Will the quality be even better on -crf 16 or 15? And how low can I go without risking that some athletes might not be able to watch it?
    Lower CRF values result in larger filesizes and higher quality. You should use vbv cap for specific devices, otherwise it's just a guess. Some devices will stutter or not play

    2) How can I merge the output files (mp4) without quality loss (or learning curve). A quick Google takes me to mp4joiner - has anyone got experience with this?
    You should edit and merge before encoding. You can encounter problems trying to append after. Edit the original transport streams. If you need to append them, you can use tsmuxer (ffmpeg can do it too)

    Now to the next problem. Sideline is an analyzing tool that also allows me to export new video clips the way I need to. Some athletes need certain clips, other athletes need different ones. But when I try to export clips I get an error saying that the key frames are to far apart to proceed with accurate cutting. This does not happen with normal mp4s. Is there anyway to solve this in the code given by racer-x? Is something in the code connected to key frames?
    max keyframe interval is -g in ffmpeg

    so if you had a 50fps output, and wanted 1 second keyframes, it would be -g 50 . -g 25 would be 0.5 sec. The shorter the keyframe interval, the more accurate the cutting, but the worse the compression
    Quote Quote  
  7. Originally Posted by newpball View Post
    Originally Posted by Miti View Post
    Now to the next problem.
    Your workflow creates instead of solves problems.

    What is the point in going through hoops to get the best format and then cut it up and render the parts again?

    Just take the original source and then edit and render to all files you need to deliver.

    One step should do it!

    Exactly. This current workflow seems very convoluted, waste of time, and introduces unecessary additional loss of quality

    Find out what formats Sideline support
    Quote Quote  
  8. Originally Posted by newpball View Post
    Originally Posted by Miti View Post
    Now to the next problem.
    Your workflow creates instead of solves problems.

    What is the point in going through hoops to get the best format and then cut it up and render the parts again?

    Just take the original source and then edit and render to all files you need to deliver.

    One step should do it!
    I am looking for that one step that can do it - that is why I am doing the testing. I had no idea what keyframes were till I wrote here (and I still have my doubts that I do). If someone could make a code in ffmpeg that could get high quality .mp4's from .mts at around 5gb (1 hour and 20 minutes of sports) + with keyframes that made it possible to do accurate cutting in Sideline I would not ask so much
    Quote Quote  
  9. Banned
    Join Date
    Oct 2014
    Location
    Northern California
    Search PM
    Originally Posted by Miti View Post
    I am looking for that one step that can do it - that is why I am doing the testing. I had no idea what keyframes were till I wrote here (and I still have my doubts that I do). If someone could make a code in ffmpeg that could get high quality .mp4's from .mts at around 5gb (1 hour and 20 minutes of sports) + with keyframes that made it possible to do accurate cutting in Sideline I would not ask so much
    That is not one step!

    One step is take the original file and dump it in your favorite NLE and save it as a project. Then you can get back to it as many times as you want to generate whatever cuts in whatever format you like!

    A simple, smooth, easy and proven to work for decades method!

    But I have a fear you will find a reason not to do it like that.

    Quote Quote  
  10. Originally Posted by newpball View Post
    Originally Posted by Miti View Post
    I am looking for that one step that can do it - that is why I am doing the testing. I had no idea what keyframes were till I wrote here (and I still have my doubts that I do). If someone could make a code in ffmpeg that could get high quality .mp4's from .mts at around 5gb (1 hour and 20 minutes of sports) + with keyframes that made it possible to do accurate cutting in Sideline I would not ask so much
    That is not one step!

    One step is take the original file and dump it in your favorite NLE and save it as a project. Then you can get back to it as many times as you want to generate whatever cuts in whatever format you like!

    A simple, smooth, easy and proven to work for decades method!

    But I have a fear you will find a reason not to do it like that.

    As the thread clearly states I am a newbie, so if you say so it might as well be right.

    A reason not to do that would be that Sideline allows me to make clips across games, search for clips that match criteria through a formula that I have created that fits my needs. So if I for instance would like to see all situations where a certain player makes a foul throughout the entire season - I can do that (if the input format works naturally). If I want to see how the team acts in offensive transitions against teams with a certain formation - I can do that too etc.
    Quote Quote  
  11. Member racer-x's Avatar
    Join Date
    Mar 2003
    Location
    3rd Rock from the Sun
    Search Comp PM
    KeyFrames every 1/2 second should be sufficient:

    Code:
    SET PATH="C:\FFMpeg"
    for %%a in ("*.mts") do ffmpeg -i "%%a" -vf yadif=mode=1:parity=tff -s 1280x720 -c:v libx264 -level 41 -pix_fmt yuv420p -g 25 -preset medium -crf 19 -c:a aac -strict experimental -ar 48000 -ab 256k -f mp4 "%%~na.mp4"
    
    pause
    Got my retirement plans all set. Looks like I only have to work another 5 years after I die........
    Quote Quote  
  12. Originally Posted by racer-x View Post
    KeyFrames every 1/2 second should be sufficient:

    Code:
    SET PATH="C:\FFMpeg"
    for %%a in ("*.mts") do ffmpeg -i "%%a" -vf yadif=mode=1:parity=tff -s 1280x720 -c:v libx264 -level 41 -pix_fmt yuv420p -g 25 -preset medium -crf 19 -c:a aac -strict experimental -ar 48000 -ab 256k -f mp4 "%%~na.mp4"
    
    pause
    Thank you very much! This worked perfectly. It is good quality, acceptable size and works in my program.
    Quote Quote  
Visit our sponsor! Try DVDFab and backup Blu-rays!