Answers.Body: <p>Use cross-platform wrapper library <a href="https://github.com/FFMS/ffms2" rel="nofollow noreferrer">FFmpegSource</a> (around FFmpeg) — particularly, its filter <code>FFmpegSource2()</code> (instead of built-in <code>AviSource()</code> or <code>DirectShowSource()</code>).</p>
  
  <p>See <a href="http://avisynth.nl/index.php/FFmpegSource" rel="nofollow noreferrer">AviSynth Wiki</a> about it.</p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2019-12-22T20:25:26.247Z
Answers.Text: I think I was able to use the plugin (with `LoadPlugin("/path/to/ffms2/x86/ffms2.dll")`), and Media Player says `Windows Media Player is unable to open the file. It's possible that Media Player
  does not support this type of file or that you need a codec that is not
  installed. [Close] [Help online]`. A file `00009.MTS.ffindex` appeared next to the source. With the x64 path, I get an error from AviSynth, `error 0xc1`. Shall I update my question or is it a separate question?
Answers.UserDisplayName: emonigma
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2019-12-22T20:27:09.713Z
Answers.Text: Why not give a separate question? It's better than have 2 question in one.
Answers.UserDisplayName: MarianD
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2020-02-11T12:16:01.573Z
Answers.Text: See this follow-up thread: https://video.stackexchange.com/questions/29137/errors-in-ffmpegsource2-plugin-source-filter-for-avisynth for installation and usage of FFmpegSource2 for MTS and MP4 files.
Answers.UserDisplayName: emonigma
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2019-12-21T16:07:49.023Z
Answers.LastActivityDate: 2019-12-21T21:40:45.357Z
Answers.LastEditDate: 2019-12-21T21:40:45.357Z
Answers.UserDisplayName: MarianD
Body: <p>I want to process MTS (MPEG Transport Stream) files from an AVCHD camcorder in AviSynth. Displaying with <code>AviSource()</code> says that the file couldn't be opened, displaying with <code>DirectShowSource()</code> says that the format is not supported.</p>
  
  <p>I found no information about MTS on the AviSynth wiki. The <a href="http://avisynth.nl/index.php/TWriteAVI#Source_Filters" rel="nofollow noreferrer">list of source filters</a> has nothing on MTS or TS. I found <a href="http://forum.doom9.org/showthread.php?t=130359" rel="nofollow noreferrer">a thread about MTS and VirtualDub</a> but I would prefer dealing only with the source file instead of converting to another format.</p>
  
  <p>Can AviSynth handle MTS files?</p>
  
Tags: <codec><mpeg>
Title: Can AviSynth handle MTS files?
UserDisplayName: emonigma
ThreadText: # Can AviSynth handle MTS files?
  
  (Asked by: username_0 on 2019-12-20)
  
  I want to process MTS (MPEG Transport Stream) files from an AVCHD camcorder in AviSynth. Displaying with `AviSource()` says that the file couldn't be opened, displaying with `DirectShowSource()` says that the format is not supported.
  
  I found no information about MTS on the AviSynth wiki. The [list of source filters](http://avisynth.nl/index.php/TWriteAVI#Source_Filters) has nothing on MTS or TS. I found [a thread about MTS and VirtualDub](http://forum.doom9.org/showthread.php?t=130359) but I would prefer dealing only with the source file instead of converting to another format.
  
  Can AviSynth handle MTS files?
  
  **Tags:** codec, mpeg
  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_1 on 2019-12-21. Score: 1 | Accepted answer
  
  Use cross-platform wrapper library [FFmpegSource](https://github.com/FFMS/ffms2) (around FFmpeg) — particularly, its filter `FFmpegSource2()` (instead of built-in `AviSource()` or `DirectShowSource()`).
  
  See [AviSynth Wiki](http://avisynth.nl/index.php/FFmpegSource) about it.
  
  > **Comments:**
  > **username_0**: I think I was able to use the plugin (with `LoadPlugin("/path/to/ffms2/x86/ffms2.dll")`), and Media Player says `Windows Media Player is unable to open the file. It's possible that Media Player does not support this type of file or that you need a codec that is not installed. [Close] [Help online]`. A file `00009.MTS.ffindex` appeared next to the source. With the x64 path, I get an error from AviSynth, `error 0xc1`. Shall I update my question or is it a separate question?  
  > **username_1**: Why not give a separate question? It's better than have 2 question in one.  
  > **username_0**: See this follow-up thread: https://video.stackexchange.com/questions/29137/errors-in-ffmpegsource2-plugin-source-filter-for-avisynth for installation and usage of FFmpegSource2 for MTS and MP4 files.  
  
  ---
  
  