How to fix “Failed to play movie.”
Introduction
This article explains the cause of the error “Failed to play movie” that appears when starting the ThumbnailCity’s Viewer and how to address it.
This error occurs when ThumbnailCity attempts to play a movie internally using middleware*1 to pick up a image from the video, but fails. There are four main causes of error.
- Lack of codecs*4 such as splitter*2 and/or decoder*3 required to playback.
- Miss match between file extension and container*5 type.
- Bug or limitation of codecs installed.
- Movie file is broken.
*1: Software between OS and application. Ex. MediaFoundation*6, DirectShow*7 and libVLC*8.
*2: Software to extract video, audio and etc. data from a container.
*3: Software that decodes encoded video data.
*4: A generic term for decoders and encoders. It may also include splitters, etc.
*5: A file or file format spec that contains video and audio data, such as mp4 and mkv.
*6: Default middleware to playback multimedia on Windows OS.
*7: Legacy middleware to playback multimedia. Has disadvantages such as not supporting new GPUs.
*8: Middleware to playback videos which bundled with VLC Media Player.
Lack of codecs such as splitter and/or decoder required to playback.
When playing movie internally, ThumbnailCity tries MediaFoundation, DirectShow, and libVLC in turn and uses the middleware that successfully plays them. MediaFoundation and DirectShow have certain types of containers (e.g. FLV, mkv) and encodings (e.g. HEVC, VP9) that by default cannot be played due to intellectual property rights or other reasons. To play movies such containers and encodings that are not supported by these defaults, additional packages or third-party codecs must be installed.
- Codecs that can be added with MediaFoundation are primarily available from the Microsoft Store. ; They may be available from third parties.
- For AVC-encoded FLV videos, thumbnails can be generated by activating the “FLV Media Source” included with ThumbnailCity. “FLV Media Source” can be activated by executing “Change” from “App Features” or by re-running the installer and executing “Change”.
- Many of the codecs provided to DirectShow are available free of charge from third parties. You can find all sorts of things by searching for “DirectShow codec packs.”
- libVLC is available after installing VLC Media Player. However, when used from ThumbnailCity, processing performance is poor because only software decoding is supported.
Miss match between file extension and container type.
There are many cases of confusion between the extension and container type, such as a mkv container movie file with an “.mp4” extension it’s incorrect. Windows has a action to determine which application and thumbnail provider to use depending on the extension, so for example, if the application associated with the “.mp4” extension can also handle mkv containers, it will work correctly, but if that application cannot handle mkv containers, an error will occur. Check the container type of the movie file with MediaInfo or other software and modify to the correct extension, which may enable normal playback.
Bug or limitation of codecs installed.
In some cases, even if codecs that support container and encoding are installed, bugs or limitations in these codecs may cause errors. Specifically, we have observed cases where MediaFoundation fails or becomes freeze for AVC or HEVC encoded videos stored in mp4 or mkv containers, when the pixel color depth is 10 bits. In the case of such a problem caused by a particular combination of middleware and codecs, it may be possible to avoid the problem by changing the priority of the middleware (API priority in the notation) in the “System Settings” of ThumbnailCity.
Movie file is broken.
This is a case where the movie file is corrupted due to a hardware failure or a bug in another application, etc. It can be determined by examining the video file using MediaInfo, etc. However, it is not possible to determine the cause of the corruption. However, there is nothing you can do.
Note: In this article, “movie” refers to media including video and audio, and “video” refers to video only.