VideoHelp Forum




+ Reply to Thread
Results 1 to 19 of 19
  1. Member
    Join Date
    Nov 2006
    Location
    United States
    Search Comp PM
    Hello all. I just authored a DVD using QDVDauthor under Linux. It is a DVD for a board game consisting of mainly narrated shots of the playing board and some camcorder interviews.

    Based on computer playback it turned out superb, but playing it back on a standalone player connected to a SD TV isn't so good.

    During SD TV playback the camcorder filmed interviews are just fine, but the board sequences (which are generated via a computer screen capture program) are poor. The problem is that the colors are all washed out and there is a serious lack of sharpness. This may be due to the image being scaled up to fit the screen. Short of having to re-film all the board sequences is there any processing that can be applied to the source AVIs to increase the color intensity and sharpness that will improve TV playback quality without adversely affecting the already good PC playback quality?
    Many thanks.

    P.S. By any chance is there a guide for optimizing video quality for SD TV playback?
    Quote Quote  
  2. I'm a MEGA Super Moderator Baldrick's Avatar
    Join Date
    Aug 2000
    Location
    Sweden
    Search Comp PM
    Still pictures or screen recordings usually look pretty bad if you convert to dvd mpeg.

    What converter are you using? Or does qdvdauthor converts also?
    Could you post a short sample from the dvd board sequences?
    Quote Quote  
  3. Always Watching guns1inger's Avatar
    Join Date
    Apr 2004
    Location
    Miskatonic U
    Search Comp PM
    Also, what are the source details ? resolution, framerate etc.
    Read my blog here.
    Quote Quote  
  4. Member
    Join Date
    Nov 2006
    Location
    United States
    Search Comp PM
    Originally Posted by Baldrick
    Still pictures or screen recordings usually look pretty bad if you convert to dvd mpeg.

    What converter are you using? Or does qdvdauthor converts also?
    Could you post a short sample from the dvd board sequences?
    The source AVIs for the board sequences are produced by camtasia. Here's typical mplayer output:

    AVI file format detected.
    VIDEO: [tscc] 676x680 24bpp 5.000 fps 19.1 kbps ( 2.3 kbyte/s)
    ================================================== ========================
    Opening video decoder: [ffmpeg] FFmpeg's libavcodec codec family
    Selected video codec: [ffcamtasia] vfm: ffmpeg (TechSmith Camtasia Screen Codec (native))

    I then used ffmpeg to scale/crop/pad the avi.
    Finally it was put into NTSC DVD compliant form with the appropriate command on http://www.mplayerhq.hu/DOCS/HTML/en/menc-feat-vcd-dvd.html

    It seems like I'm screwed on this as there seems to be no way to avoid lossy video compression en route to a standard compliant NTSC DVD. The only thing I can think of is to try capturing a source image which might be less susceptible to the effects of mpeg compression, i.e. 100% solid color values with no gradients. If you have any suggestions on where in this process an improvement might be made please let me know.

    P.S. The scaling probably didn't help matters, but as you can see from the source image size was unavoidable.
    Quote Quote  
  5. Always Watching guns1inger's Avatar
    Join Date
    Apr 2004
    Location
    Miskatonic U
    Search Comp PM
    I suspect the missing 19 fps is the biggest problem. The encoder needs to fill the gaps to get to at least 23.976 fps, if not the full 29.976 fps (depends how you are encoding it), which means a lot of frame blending. You need to try to capture at a higher framerate.
    Read my blog here.
    Quote Quote  
  6. Member
    Join Date
    Nov 2006
    Location
    United States
    Search Comp PM
    Originally Posted by guns1inger
    I suspect the missing 19 fps is the biggest problem. The encoder needs to fill the gaps to get to at least 23.976 fps, if not the full 29.976 fps (depends how you are encoding it), which means a lot of frame blending. You need to try to capture at a higher framerate.
    I thought by encoding at a higher rate the gaps were filled in with duplicate delta frames (-vf harddup in mencoder)? I don't see how duplicate frames would affect video quality. What is this "frame blending" that you refer to?
    Quote Quote  
  7. Member
    Join Date
    Nov 2006
    Location
    United States
    Search Comp PM
    Originally Posted by nbi
    Originally Posted by guns1inger
    I suspect the missing 19 fps is the biggest problem. The encoder needs to fill the gaps to get to at least 23.976 fps, if not the full 29.976 fps (depends how you are encoding it), which means a lot of frame blending. You need to try to capture at a higher framerate.
    I thought by encoding at a higher rate the gaps were filled in with duplicate delta frames (-vf harddup in mencoder)? I don't see how duplicate frames would affect video quality. What is this "frame blending" that you refer to?
    I should have googled this before being quick to respond.

    From what I read it looks like the delta changes are spread across the frames used to fill in the gaps in "frame blending" as opposed to merely duplicating delta frames. Assuming my interpretation of blending is close to target what can I do to disable it in mencoder? I'm not sure blending would be desirable for the board clips, so yes, I agree I need to capture at a higher rate (although I'm curious what the video would look like with duplicated as opposed to blended frames). Thanks for your help.
    Quote Quote  
  8. Member
    Join Date
    Nov 2006
    Location
    United States
    Search Comp PM
    Apparently ffmpeg introduces degradation when padding or cropping since the original portion of the frame looks much worse afterwards. So that's yet another thing contributing to the video degradation.

    Isn't this a bug in ffmpeg? It claims to "convert as losslessly as possible". IMHO, this should mean that the cropped/padded image is at least as good as the original. After all why shouldn't it be, we are only adding/subtracting pixels around an area that should remain unchanged.
    Quote Quote  
  9. MPEG2 encoding uses a YUV colorspace with 4:2:0 subsampling. The reduced color resolution is probably responsible for some of your fuzziness (assuming an RGB 4:4:4 source).

    Top is RGB 4:4:4, bottom is MPG YUV 4:2:0 (8000 kbps):


    Why don't you post a few seconds of the source video and a few seconds of the converted video. Then someone can take a look and make suggestions.
    Last edited by jagabo; 1st Feb 2014 at 17:59.
    Quote Quote  
  10. Always Watching guns1inger's Avatar
    Join Date
    Apr 2004
    Location
    Miskatonic U
    Search Comp PM
    You should also consider using Avisynth to pad out the frame with addborders, and make and colourspace conversions for you.
    Read my blog here.
    Quote Quote  
  11. Member thecoalman's Avatar
    Join Date
    Feb 2004
    Location
    Pennsylvania
    Search PM
    For future reference even if you had captured at a higher resolution and scaled down, correct frame rate and all the other stars aligned you most likely would still encouter problems. Besides the reduced resoltion from scaling you,have further reduction in sharpness due to the differences in the way a TV and monitor display. It really depends on what your capturing. Games wouldn't matter that much because the focus is on the game but if there is any text involved.... The biggest issues when going from screen capture to DVD is text readability. Even setting your screen resolution to 800x600 and setting the fonts high will produce unreadable text and/or a very odd looking video due to the large fonts (e.g average person doesn't have title bar that takes up 20% of the screen).

    One solution is to set your monitor at a resolution like 1024x768 or even higher, use that for the capture settings on the application. Once captured use your video editor to zoom and pan around the video to focus on the task at hand. Zoom out ocaasioanlly as needed to give the person reference to where they are at.
    Quote Quote  
  12. Member
    Join Date
    Nov 2006
    Location
    United States
    Search Comp PM
    Thanks for the feedback.

    mpeg encoding is definitely playing a role as I'm getting the same kind of fuzziness as in jagabo's example. Don't know what can be done to address the colorspace problem.

    Was completely oblivious to Avisynth and will take a look.

    Sigh. This project is shaping up to be a real PITA.
    Quote Quote  
  13. Member
    Join Date
    Nov 2006
    Location
    United States
    Search Comp PM
    Ok, where do I find an Avisynth HOWTO that lets me address my issues?

    I've sifted through all the guides and can't find anything that explains what Avisynth is all about and gives basic examples of its use that are pertinent to the problem I'm trying to solve. I've even gone to the Avisynth home page and have visited various recommended links.

    Could someone who followed this thread articulate a high level Avisynth game plan for resolving the types of problems that jagabo identified? You don't need to spoon feed me detailed procedures, just a high level plan for getting from point A to point B using Avisynth. I'll roll up my sleeves and dig in. Thanks.

    The problem as I understand it so far is that the screen capture AVIs (captured by TechSmith's camtasia) lose their image quality when encoded to DVD compliant mpeg. In my case there is no avoiding the encoding to a valid NTSC DVD. So where in this process can Avisynth be utilized to make improvements? I'm guessing it would be used to manipulate the capture source to mitigate losses due to the mpeg encoding. For example, utilizing solid bold colors wherever possible and eliminating gradients. If I'm on the right track please let me know. If I'm out of the ballpark please let me know that too.
    Quote Quote  
  14. Originally Posted by nbi
    Could someone who followed this thread articulate a high level Avisynth game plan for resolving the types of problems that jagabo identified?
    The problem I pointed out cannot be addressed by AviSynth. It is an inherent part of MPEG encoding. You have to address it at the source -- by avoiding small colored text. Or at least make sure the text and background colors have a large luminance (after conversion to YUV) difference.

    The thing to understand here is that MPEG encoding uses the full resolution of the luminace channel (the grayscale portion) but reduces the color channels to half resolution. So your 720x480 frame is encoded as a 720x480 brightness channel and two 360x240 color channels. Further, transmitting the lower resolution color channels through a composite cable from the DVD player to the TV may reduce the color resolution even more.

    If your problems come from resizing (your 676x680 source must be cropped, padded, and/or resized in some way) you may be able to address it using the Crop(), AddBorders() and/or Resize functions in AviSynth. Those functions are covered in the AviSynth docs that were installed along with AviSynth. I suggest LanczosResize() for downsizing, BicubicResize() or LanczosResize() for upsizing.

    Originally Posted by nbi
    The problem as I understand it so far is that the screen capture AVIs (captured by TechSmith's camtasia) lose their image quality when encoded to DVD compliant mpeg. In my case there is no avoiding the encoding to a valid NTSC DVD. So where in this process can Avisynth be utilized to make improvements? I'm guessing it would be used to manipulate the capture source to mitigate losses due to the mpeg encoding. For example, utilizing solid bold colors wherever possible and eliminating gradients. If I'm on the right track please let me know. If I'm out of the ballpark please let me know that too. :shock:
    Without seeing a sample of the source, and without knowing exactly how you want it to look after conversion (ie, stretched to full screen, retain the aspect ratio, in a small box with help text next to it, etc), it isn't possible to give very specific pointers.

    Some general guidelines: gradients won't necessarily cause problems (unless they're changing a lot from frame to frame). Avoid small text, avoid text with serif's, use strong luminance differences between text and backgrounds (black and white will work best), avoid very thin horzontal lines, some RGB colors do not translate well to YUV, etc.
    Quote Quote  
  15. Member
    Join Date
    Nov 2006
    Location
    United States
    Search Comp PM
    Well so much for Avisynth. It seems to be installed correctly but does not frame serve the video correctly. The sympton is wildly flasing video which looks like only parts of the original are being served. That's with using virtualdub. I created a real simple .avs that only opens the source avi. One would think this shouldn't be problematic, but when I preview the input via virtualdub it's wildly flashing. I've scoured the documentation and forums, but can't find any clues as to what's wrong. Not exactly the best supported software.
    Quote Quote  
  16. That sounds like a codec problem.

    Add Info() to the end of your script. AviSynth will print information about the source onto the video it outputs.

    AviSource("file.avi")
    Info()
    Quote Quote  
  17. Member
    Join Date
    Nov 2006
    Location
    United States
    Search Comp PM
    Originally Posted by jagabo
    That sounds like a codec problem.

    Add Info() to the end of your script. AviSynth will print information about the source onto the video it outputs.

    AviSource("file.avi")
    Info()
    I did that. Yes, it correctly identifies attributes of the source video, but how does that help me solve the problem?

    My avs script also contained cropping, padding, and the LanczosResize. It seemed to do all those ok, but since the output was trashed it was useless.

    I was not able to find any warnings or disclaimers about input that Avisynth can't handle. Other than a slow video framerate of 5 fps the source video seems unremarkable. No other video app such as ffmpeg, mencoder, virtualdub has any problems with this video. Is it a colorspace issue? ffmpeg reports the video as being "yuv420p". I don't know the implications of that, but am inclined to think it's not a problem because all the other apps seem to handle it ok (by ok I mean producing usable although perhaps degraded output without choking). I have no clue what the problem is.
    Quote Quote  
  18. Member
    Join Date
    Nov 2006
    Location
    United States
    Search Comp PM
    Some progress with Avisynth. It seems AviSource can't load AVIs containing TechSmith codec generated video. However DirectShowSource can (well at least the video, the audio track is not found).

    Now if I could only avoid splitting and recombining the video and audio.
    Quote Quote  
  19. AviSource() uses VFW codecs, DirectShowSource() uses DirectShow codecs.
    Quote Quote  



Similar Threads

Visit our sponsor! Try DVDFab and backup Blu-rays!