VideoHelp Forum




+ Reply to Thread
Results 1 to 13 of 13
  1. Member
    Join Date
    Sep 2008
    Location
    Planet Snack!
    Search Comp PM
    Hi guys,


    I am currently re-encoding some files with hardsubs, since I need maximum compatibility for my DivX player. My original files is a MKV, and I am in the process of converting it into an AVI. If anybody wants some context in how I re-encode, I use a AVISynth Script with VirtualDubMod.

    At the same time, I also use VirtualDubMod to hardsub the subtitles. I have installed VobSub, and use its TextSub filter that it installed in VirtualDubMod to do the job.

    My problem is that certain fonts do not display or covert properly after I finish re-encoding.

    For example, this is a picture of the original file:

    Click image for larger version

Name:	Original.JPG
Views:	220
Size:	62.5 KB
ID:	13548

    The word circled in red is of interest here.


    Now here is a picture of the subtitle file:

    Click image for larger version

Name:	Subtitles.JPG
Views:	195
Size:	46.5 KB
ID:	13549

    The word circled in red seems to render fine in both the video version and the subtitle file on my computer.


    But after I convert the file through VirtualDubMod, and add the subtitles through VobSub's TextSub filter (in VDM), I get this:

    Click image for larger version

Name:	Re-Encoded.JPG
Views:	215
Size:	66.5 KB
ID:	13550

    Notice that the converted result converts the text in an ill manner.



    Can anybody help me here and tell me what has happened? I suspect the problem is either in VirtualDubMod or VobSub, but don't know where to start. Any tips would be nice.
    Quote Quote  
  2. VH Wanderer Ai Haibara's Avatar
    Join Date
    Jan 2006
    Location
    Somewhere on VideoHelp...
    Search Comp PM
    Make sure the font you're using to hardsub can actually handle that character. If the MKV you're using has fonts included for the subtitles, you might try installing them. (I can't remember whether or not you can get away with having them in the current directory as the videos when you're hardsubbing.)

    Also, if you haven't already tried it, you might update VSFilter (copying it to VirtualDub's plugins) to the latest version.
    If cameras add ten pounds, why would people want to eat them?
    Quote Quote  
  3. And why aren't you using the textsub filter in your AviSynth script? It'll save an unnecessary colorspace conversion and encode faster.
    Quote Quote  
  4. Member
    Join Date
    Sep 2008
    Location
    Planet Snack!
    Search Comp PM
    Originally Posted by Ai Haibara View Post
    Make sure the font you're using to hardsub can actually handle that character... Also, if you haven't already tried it, you might update VSFilter (copying it to VirtualDub's plugins) to the latest version.
    Will definitely look into and update.


    Originally Posted by manono View Post
    And why aren't you using the textsub filter in your AviSynth script? It'll save an unnecessary colorspace conversion and encode faster.
    The encode faster part I believe. I'll look into the syntax in a bit and try it out. But as for the colorspace conversion thing, can you explain in more depth as to what you mean. I want to learn how this works as I go, and am curious by what you mean.
    Quote Quote  
  5. Member
    Join Date
    Sep 2008
    Location
    Planet Snack!
    Search Comp PM
    Ummm... a problem guys. I don't know what happened exactly, but now the AVISynth script I used doesn't work anymore. It pops out with an error. Here's the basic script (I'll add in the modifications you guys suggested as soon as this works again):
    Code:
    Directshowsource("FileName-Here.mkv", fps=23.810, convertfps=true)
    The FileName-Here is the filename...

    And here's what MediaInfo says about the file:
    Code:
    General
    Complete name                    : L:\ <A bunch of Subfolders> \FileName-Here.mkv
    Format                           : Matroska
    File size                        : 149 MiB
    Duration                         : 23mn 50s
    Overall bit rate                 : 875 Kbps
    Encoded date                     : UTC 2011-04-05 18:38:03
    Writing application              : mkvmerge v4.0.0 ('The Stars were mine') built on Jun  6 2010 16:18:42
    Writing library                  : libebml v1.0.0 + libmatroska v1.0.0
    Cover                            : Yes
    
    Video
    Format                           : AVC
    Format/Info                      : Advanced Video Codec
    Format profile                   : High@L3.1
    Format settings, CABAC           : Yes
    Format settings, ReFrames        : 8 frames
    Codec ID                         : V_MPEG4/ISO/AVC
    Duration                         : 23mn 38s
    Nominal bit rate                 : 750 Kbps
    Width                            : 848 pixels
    Height                           : 480 pixels
    Display aspect ratio             : 16/9
    Frame rate                       : 23.810 fps
    Original frame rate              : 24.000 fps
    Colorimetry                      : 4:2:0
    Scan type                        : Progressive
    Bits/(Pixel*Frame)               : 0.077
    Writing library                  : x264 core 98 r1629 2e81ce1
    Encoding settings                : cabac=1 / ref=8 / deblock=1:0:0 / analyse=0x3:0x133 / me=umh / subme=7 / psy=1 / psy_rd=1.00:0.00 / mixed_ref=1 / me_range=16 / chroma_me=1 / trellis=2 / 8x8dct=1 / cqm=0 / deadzone=21,11 / fast_pskip=0 / chroma_qp_offset=-2 / threads=1 / sliced_threads=0 / nr=0 / decimate=1 / interlaced=0 / constrained_intra=0 / bframes=6 / b_pyramid=2 / b_adapt=2 / b_bias=0 / direct=3 / weightb=1 / weightp=0 / keyint=240 / keyint_min=24 / scenecut=40 / intra_refresh=0 / rc_lookahead=40 / rc=2pass / mbtree=1 / bitrate=750 / ratetol=1.0 / qcomp=0.60 / qpmin=10 / qpmax=51 / qpstep=4 / cplxblur=20.0 / qblur=0.5 / vbv_maxrate=1927 / vbv_bufsize=1927 / ip_ratio=1.40 / aq=1:0.50 / nal_hrd=none
    
    Audio
    Format                           : AAC
    Format/Info                      : Advanced Audio Codec
    Format version                   : Version 4
    Format profile                   : LC
    Format settings, SBR             : No
    Codec ID                         : A_AAC
    Duration                         : 23mn 50s
    Channel(s)                       : 2 channels
    Channel positions                : L R
    Sampling rate                    : 44.1 KHz
    Resolution                       : 16 bits
    
    Text
    Format                           : ASS
    Codec ID                         : S_TEXT/ASS
    Codec ID/Info                    : Advanced Sub Station Alpha
    I try opening the AVISynth script and get this error:
    Click image for larger version

Name:	Capture.JPG
Views:	367
Size:	32.3 KB
ID:	13552



    What frustrates me is that this I used this exact same script to make a converted file I showed you guys a couple of hours ago. What happened?
    Quote Quote  
  6. Originally Posted by adalect View Post
    But as for the colorspace conversion thing, can you explain in more depth as to what you mean.
    When you use VDub(Mod) filters, you have to use 'Full Processing'. This forces a colorspace conversion from YV12 (which I believe your 'source' is) to RGB and then back again. This slightly degrades the final quality as well as slowing the encode. Using the Textsub filter in the AviSynth script allows you to use 'FastRecompress' and it stays in YV12 all the way, a much better solution.
    Quote Quote  
  7. Member
    Join Date
    Sep 2008
    Location
    Planet Snack!
    Search Comp PM
    Thanks for the explanation manono. Very clear, very concise, and easy to understand. Much appreciated.

    Now... can anybody guide me with my DirectShowSource error?
    Quote Quote  
  8. DECEASED
    Join Date
    Jun 2009
    Location
    Heaven
    Search Comp PM
    Make sure both the AVS file and the MKV file are in the same folder ;
    Quote Quote  
  9. Member
    Join Date
    Sep 2008
    Location
    Planet Snack!
    Search Comp PM
    Originally Posted by El Heggunte View Post
    Make sure both the AVS file and the MKV file are in the same folder ;
    Both files are in the same folder. Judging by the wording of the error box, it seems AVISynth can find the file, but DirectShowSource doesn't seem to know how to react. I am not too sure as to what to do to fix DirectShowSource.
    Quote Quote  
  10. Originally Posted by adalect View Post
    I am not too sure as to what to do to fix DirectShowSource.
    Don't use it. Use FFMPEGSource instead:

    http://code.google.com/p/ffmpegsource/

    http://ffmpegsource.googlecode.com/svn/trunk/doc/ffms2-avisynth.html
    Quote Quote  
  11. DECEASED
    Join Date
    Jun 2009
    Location
    Heaven
    Search Comp PM
    ^
    ^ Well, the fact is, Avisynth not always builds (or attempts to build) a DirectShow graph in the same way as MPC-HC for example (not to mention Graphstudio and the infamous Windows Media Player). As a last resort, you can always (try to) build a functional graph manually in Graphstudio, save it, and apply DirectShow Source() on it. Besides, thanks to the 'convertfps' option, you can choose a framerate value more convenient than "23.810fps"

    Even though FFMpegSource is very-good, I simply don't like it very much Especially because in certain cases it has to use the annoying Haali Media Splitter. I prefer both LAV Splitter and AV Splitter to HMS, which is still "most useful" only to the «animé "releasers"», apparently.
    Last edited by El Heggunte; 20th Aug 2012 at 09:15. Reason: better wording
    Quote Quote  
  12. Member
    Join Date
    Sep 2008
    Location
    Planet Snack!
    Search Comp PM
    I did another batch of Googling, and many people mentioned that codecs may be a problem. I found that DirectShowSource failed to work with MKV files (but not AVI files), so I uninstalled and reinstalled the Haali Media Splitter package I had. Now it works! Thanks for the help so far guys.


    Originally Posted by Ai Haibara View Post
    Also, if you haven't already tried it, you might update VSFilter (copying it to VirtualDub's plugins) to the latest version.
    Trying this at the moment, and it seems to work. I'll update if something breaks, but otherwise it should be fine now. Thanks!


    Originally Posted by manono View Post
    Use FFMPEGSource instead...
    Just curious, what is the biggest difference between FFMPEGSource and DirectShowSource? I read something about support for variable frame rates, but then I also read something about having to index files if you use FFMPEGSource. Can you give me the skinny about this?
    Quote Quote  
  13. I never use DirectShowSource if I can possibly avoid it. For one thing, it's often not frame-accurate and seeking can be screwy. Yes, FFMPEGSource indexes the file, the way DGIndex indexes an MPG of some sort. But that is, in my opinion, a good thing, and it doesn't take long at all. I use it for everything but DVD/MPEGs (which I index first using DGIndex, together with MPEG2Source), and most AVIs (for which AviSource is usually used).
    Quote Quote  



Similar Threads

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