This commit is contained in:
2026-03-27 07:06:16 +01:00
commit 1541961403
340 changed files with 151916 additions and 0 deletions
+14
View File
@@ -0,0 +1,14 @@
## **Installation Instructions**
### Windows
- [(GLSL/MPV)](GLSL_Instructions_Windows_MPV.md)
- [(GLSL/Plex)](GLSL_Instructions_Windows_Plex.md)
### Linux
- [(GLSL/MPV)](GLSL_Instructions_Linux.md)
- [(GLSL/Plex)](GLSL_Instructions_Linux_Plex.md)
### Mac
- [(GLSL/MPV)](GLSL_Instructions_Mac_MPV.md)
- [(GLSL/IINA)](GLSL_Instructions_Mac_IINA.md)
- [(GLSL/Plex)](GLSL_Instructions_Mac_Plex.md)
@@ -0,0 +1,102 @@
# Advanced Usage Instructions (GLSL / MPV) (v4.x)
## Modes
Now, Anime4K has 3 major modes, as the small CNN networks cannot learn effectively every type of distribution shift and degradation seen in the wild. Human judgement will serve (for now) as the stopgap solution. Usually the correct mode is the one that looks best.
The easiest way is to first visually inspect each mode in the A-B-C order. Mode A has the most visible artifacts of the three modes if used incorrectly. B and C can be harder to distinguish for lower resolution anime.
If you want increased perceptual quality, use the corresponding secondary mode.
| Primary Mode | Corresponding Secondary Mode |
| ------------- |-------------|
| A | A+A |
| B | B+B |
| C | C+A |
Here's what each mode is optimized for and what it does:
| Modes | Optimized for? | Positive effects | Negative effects (If used incorrectly) |
| ------------- |-------------| -----| -----|
| A | Most 1080p anime<br/>Some older 720p anime<br/>Most old SD anime<br/>\(High amounts of blur)<br/>\(A lot of resampling artifacts)<br/>\(Smearing due to compression) | High perceptual quality<br/>Reduces compression artifacts<br/>Reconstructs most degraded lines<br/>Reduces large amounts of blur<br/>Reduces noise | Can amplify ringing if already present<br/>Can amplify banding if already present<br/>Strong denoising might blur textures |
| B | Some 1080p anime<br/>Most 720p anime<br/>1080p->720p downscaled anime<br/>\(Low amounts of blur)<br/>\(Some resampling artifacts)<br/>\(Ringing due to downsampling) | Reduces compression artifacts<br/>Reconstructs some degraded lines<br/>Reduces some blur<br/>Reduces noise<br/>Reduces ringing<br/>Reduces aliasing | Some artifacts might not be removed<br/>Some lines might still be blurry<br/>Strong denoising might blur textures|
| C | 1080p->480p downscaled anime<br/>Very rarely, 1080p animated movies<br/>Images with no degradation<br/>Wallpapers<br/>Pixiv art | Highest PSNR<br/>Reduces noise | Low perceptual quality<br/>Can amplify ringing if already present<br/>Can amplify resampling artifacts|
| A+A\* | Same as A | Highest perceptual quality<br/>Reconstructs almost all degraded lines<br/>Same positive effects from mode A | Can cause severe ringing<br/>Can cause banding<br/>Can cause aliasing<br/>Same negative effects from mode A<br/>Slower than mode A|
| B+B\* | Same as B | High perceptual quality<br/>Same positive effects from mode B | Same negative effects from mode B<br/>Slower than mode B|
| C+A\* | Same as C | Slightly higher perceptual quality<br/>Same positive effects from mode C | Same negative effects from mode C<br/>Slower than mode C|
\*These modes should only be used on upscaling ratios of x2 or higher. If you have a 1080p screen, using mode A on 1080p anime will improve image quality, but mode A+A will most likely oversharpen and degrade the image.
## Advanced Customization
Not satisfied from simply using the default options? Curious about unsupported/weird modes such as B+A, A+B or B+A+A ? This quick guide will get you started on customizing your own restoration pipeline.
First, the basics.
- All the shaders can be used standalone or in combination with any other shaders.
- You can only use each shader file once. Using the same file two or more times causes buggy behaviour and loss of performance. Either use a different variant or copy and rename the duplicate shaders.
- The shaders process the image in the same order as the filename order given in `input.conf`. One exception is `Clamp_Highlights`, explained in the table below.
- You are free to choose the CNN variant (S, M, L, VL, UL) for better speed or quality. Each step in size for CNN shaders doubles the processing time. For example, if the M version takes 5ms to run, the L version should take approximately 10ms to run, 20ms for VL and so on.
- Non-CNN shaders are significantly faster but might be of lower quality.
Quick explanation of each shader type:
| Shader Type (in order of importance) | Effect |
| ------------- |-------------|
| Restore | The shader that makes Anime4K different from other upscalers. Restores image, best used before upscaling. Removes compression artifacts, blur, ringing, etc. `Restore` is more optimized for upsampling artifacts and blur, while `Restore_Soft` is more optimized for downsampling artifacts and aliasing. |
| Upscale | Upscales an image by a factor of x2, assumes image contains no degradation. |
| Upscale_Denoise | Upscales an image by a factor of x2 and denoises it with no GPU performance penality. |
| Clamp_Highlights | Computes and saves image statistics at the location it is placed in the shader stage, then clamps the image highlights at the end after all the shaders to prevent overshoot and reduce ringing. |
| Darken | Darkens lines in image. As what constitutes a line is ambiguous, might darken other stuff. Use according to personal taste. |
| Thin | Makes lines thinner in image. As what constitutes a line is ambiguous, might thin other stuff. Use according to personal taste. |
| Denoise | Applies a denoising filter to the image. |
| Deblur | Applies a deblur filter to the image. Sharpens details without overshoot or ringing. |
| AutoDownscalePre_x4 | Downscales an image after a first upscaling step, so that the second x2 upscaling step exactly matches screen size. This improves performance without noticeably impacting quality as you will not be working with images larger than the screen size. Should be placed between two Upscale shaders. Without this shader, the default behaviour is to downscale to the screen size after running all shaders. |
| AutoDownscalePre_x2 | Downscales an image after a first upscaling step to match screen size. This improves performance without noticeably impacting quality as you will not be working with images larger than the screen size. Should be placed after the first Upscale shader. Without this shader, the default behaviour is to downscale to the screen size after running all shaders. |
____
Overview of default modes:
| Mode | Shaders |
| ------------- |-------------|
| A | `Restore -> Upscale -> Upscale` |
| B | `Restore_Soft -> Upscale -> Upscale` |
| C | `Upscale_Denoise -> Upscale` |
| A+A | `Restore -> Upscale -> Restore -> Upscale` |
| B+B | `Restore_Soft -> Upscale -> Restore_Soft -> Upscale` |
| C+A | `Upscale_Denoise -> Restore -> Upscale` |
*Note: Clamp_Highlights and AutoDownscalePre were removed from table for clarity.*
____
How the modes are defined:
- Mode A is defined initially as: `Restore -> Upscale`
- Mode B is defined initially as: `Restore_Soft -> Upscale`
- Mode C is defined initially as: `Upscale`
- If the mode does not start with a `Restore` shader, it must start with a `Upscale_Denoise` or `Denoise` shader, as almost every video compression algorithm is lossy.
- All modes have to add upscale shaders until the entire shader pipeline upscales at least 4x. A reasonable assumption is the smallest reasonable video size being 480p and the largest screen being 4K, upscaling at 4x is close to the 4.5x of 480p->4K.
____
With the definitions above, we can see for example, what C+A+B is.
1. Initial definition:<br/>`C (Upscale) -> A (Restore -> Upscale) -> B (Restore_Soft -> Upscale)`
2. All modes have to start with restore/denoise:<br/>`C (Upscale_Denoise) -> A (Restore -> Upscale) -> B (Restore_Soft -> Upscale)`
3. Upscale ratio of 4x is already met.
4. C+A+B is:<br/>`Upscale_Denoise -> Restore -> Upscale -> Restore_Soft -> Upscale`
5. Shader variants (S/M/L/VL/UL) can be chosen at will.
## Best Practices
It is recommended to always include `Clamp_Highlights` at the beginning to prevent ringing in some anime, but removing it will slightly improve speed.
Adding a `Restore` shader after an upscaling step improves perceptual quality, but makes processing slower and might introduce artifacts.
Shaders applied after a x2 upscaling step will take four times the processing time. For example, if a shader takes 10ms to run when placed before a upscaler, it will need 40ms if placed after the upscaler. This can be counteracted by using a smaller CNN variant two steps below. (eg. S instead of L)
Artifacts introduced by lower quality shaders (eg. M or S variants) usually are not noticeable when working at very high resolutions. This advantage can be used to reduce GPU fan noise/heat and power use if you do not mind slightly lower image quality.
The target for 24fps video is usually ~41ms. Frame drops will appear if the GPU cannot keep up. If that happens, use lower quality/faster shader variants.
Use the mpv profiler (press Shift+I and then 2 on the keyboard's top row) to verify whether your GPU can keep up.
| Video Framerate | Maximum time (ms) |
|-----------|-------------------|
| 24 | 41 |
| 30 | 33 |
| 60 | 16 |
----
@@ -0,0 +1,70 @@
# Usage Instructions (GLSL / MPV) (v4.x)
## Installing and Setting Up Anime4K for Linux-based Distributions (and other Unix-like OS)
1. Install `mpv` from repositories of your distribution, some of the common ones are mentioned here
### Fedora Silverblue
1. Install the RPM-Fusion "free" repository, if not already installed, paste in the command below
`sudo rpm-ostree install https://mirrors.rpmfusion.org/free/fedora/rpmfusion-free-release-$(rpm -E %fedora).noarch.rpm https://mirrors.rpmfusion.org/nonfree/fedora/rpmfusion-nonfree-release-$(rpm -E %fedora).noarch.rpm`
2. Reboot and install `mpv`
3. Reboot and continue to step 2
### Fedora
sudo dnf install mpv
### Ubuntu and Derivatives
sudo apt install mpv
### Arch and Derivatives
sudo pacman -S mpv
### Gentoo (Add USE Flags as mentioned [here](https://wiki.gentoo.org/wiki/Mpv#USE_flags))
sudo emerge --ask media-video/mpv`
- Note: make sure to install a version of [**mpv**](https://mpv.io/) that was released after June 2021, older versions [might not work](https://github.com/bloc97/Anime4K/issues/134).
2. Clone the repo using `git clone https://github.com/bloc97/Anime4K.git`, or download the template files and extract them.
- **Optimized shaders for lower-end GPU:**
*(Eg. GTX 980, GTX 1060, RX 570)*
- Download the template files [here](https://github.com/Tama47/Anime4K/releases/download/v4.0.1/GLSL_Mac_Linux_Low-end.zip).
- <details>
<summary>Or click here to install manually.</summary>
<ul>
<li>Copy & Paste the code from <a href="Template/GLSL_Mac_Linux_Low-end/input.conf">input.conf</a> and <a href="Template/GLSL_Mac_Linux_Low-end/mpv.conf">mpv.conf</a> in your <code>input.conf</code> and <code>mpv.conf</code> file.</li>
<li>Then download and extract the shaders from <a href="https://github.com/bloc97/Anime4K/releases">releases</a> and put them in the <code>shaders</code> folder.</li>
</ul>
</details>
- **Optimized shaders for higher-end GPU:**
*(Eg. GTX 1080, RTX 2070, RTX 3060, RX 590, Vega 56, 5700XT, 6600XT)*
- Download the template files [here](https://github.com/Tama47/Anime4K/releases/download/v4.0.1/GLSL_Mac_Linux_High-end.zip).
- <details>
<summary>Or click here to install manually.</summary>
<ul>
<li>Copy & Paste the code from <a href="Template/GLSL_Mac_Linux_High-end/input.conf">input.conf</a> and <a href="Template/GLSL_Mac_Linux_High-end/mpv.conf">mpv.conf</a> in your <code>input.conf</code> and <code>mpv.conf</code> file.</li>
<li>Then download and extract the shaders from <a href="https://github.com/bloc97/Anime4K/releases">releases</a> and put them in the <code>shaders</code> folder.</li>
</ul>
</details>
3. Navigate to `~/.config/mpv` and move the `input.conf`, `mpv.conf` and the `shaders` folder into the `mpv` directory.
`mv path/to/stuff ~/.config/mpv`
![image](https://user-images.githubusercontent.com/45941793/162597836-22de46b1-fd04-4054-a5ec-f83452ed4e13.png)
____
## Quick Usage Instructions
1. Anime4K has 3 major modes: A, B, and C. Each mode is optimized for a different class of anime degradations.
- Mode A is automatically enabled, if you use our template (this can be change in `mpv.conf`).
2. To enable each mode manually:
- Press **CTRL+1** to enable Mode A (Optimized for 1080p Anime).
- Press **CTRL+2** to enable Mode B (Optimized for 720p Anime).
- Press **CTRL+3** to enable Mode C (Optimized for 480p Anime).
- Press **CTRL+0** to clear all shaders (Disable Anime4K).
3. For more explanations and customization options, see the [Advanced Usage Instructions](GLSL_Instructions_Advanced.md#advanced-usage-instructions-glsl--mpv-v4x).
@@ -0,0 +1,52 @@
# Usage Instructions (GLSL / PLEX) (v4.x)
## Installing and Setting Up Anime4K for Plex on Linux
1. Download `Plex for Linux` or `Plex HTPC (for Linux Home Theater PCs)` from [**here**](https://www.plex.tv/media-server-downloads/#plex-app).
- *Note: Only the desktop version of the app supports GLSL shaders.*
2. Open `Plex` or `Plex HTPC` (this will create the config location for you).
3. Download the template files, and extract it (open the .zip file).
- **Optimized shaders for lower-end GPU:**
*(Eg. GTX 980, GTX 1060, RX 570)*
- Download the template files [here](https://github.com/Tama47/Anime4K/releases/download/v4.0.1/GLSL_Mac_Linux_Low-end.zip).
- <details>
<summary>Or click here to install manually.</summary>
<ul>
<li>Copy & Paste the code from <a href="Template/GLSL_Mac_Linux_Low-end/input.conf">input.conf</a> and <a href="Template/GLSL_Mac_Linux_Low-end/mpv.conf">mpv.conf</a> in your <code>input.conf</code> and <code>mpv.conf</code> file.</li>
<li>Then download and extract the shaders from <a href="https://github.com/bloc97/Anime4K/releases">releases</a> and put them in the <code>shaders</code> folder.</li>
</ul>
</details>
- **Optimized shaders for higher-end GPU:**
*(Eg. GTX 1080, RTX 2070, RTX 3060, RX 590, Vega 56, 5700XT, 6600XT)*
- Download the template files [here](https://github.com/Tama47/Anime4K/releases/download/v4.0.1/GLSL_Mac_Linux_High-end.zip).
- <details>
<summary>Or click here to install manually.</summary>
<ul>
<li>Copy & Paste the code from <a href="Template/GLSL_Mac_Linux_High-end/input.conf">input.conf</a> and <a href="Template/GLSL_Mac_Linux_High-end/mpv.conf">mpv.conf</a> in your <code>input.conf</code> and <code>mpv.conf</code> file.</li>
<li>Then download and extract the shaders from <a href="https://github.com/bloc97/Anime4K/releases">releases</a> and put them in the <code>shaders</code> folder.</li>
</ul>
</details>
3. Navigate to your local `Plex` or `Plex HTPC` data directory.
#### Flatpak
/home/.var/app/tv.plex.PlexHTPC/data/plex/
5. Move the `input.conf`, `mpv.conf` and the `shaders` folder into the directory.
____
## Quick Usage Instructions
1. Anime4K has 3 major modes: A, B, and C. Each mode is optimized for a different class of anime degradations.
- Mode A is automatically enabled, if you use our template (this can be change in `mpv.conf`).
2. To enable each mode manually:
- Press **CTRL+1** to enable Mode A (Optimized for 1080p Anime).
- Press **CTRL+2** to enable Mode B (Optimized for 720p Anime).
- Press **CTRL+3** to enable Mode C (Optimized for 480p Anime).
- Press **CTRL+0** to clear all shaders (Disable Anime4K).
3. For more explanations and customization options, see the [Advanced Usage Instructions](GLSL_Instructions_Advanced.md#advanced-usage-instructions-glsl--mpv-v4x).
@@ -0,0 +1,54 @@
# Usage Instructions (GLSL / MPV) (v4.x)
## Installing and setting up Anime4K for Intel-based and Apple Silicon Mac
*If you wish to use another media player, look at their documentation on how to install GLSL shaders and modify the shader accordingly if needed.*
1. Install mpv via [**Homebrew**](https://formulae.brew.sh/formula/mpv) or download the latest release [**here**](https://laboratory.stolendata.net/~djinn/mpv_osx/mpv-latest.tar.gz)
2. Download the .glsl shader files [**here**](https://github.com/bloc97/Anime4K/releases)
3. Copy the .glsl files to `~/.config/mpv/shaders`
4. (Optional) If `mpv.conf` does not exist in `~/.config/mpv/`, create an empty file and follow [**these instructions**](https://wiki.archlinux.org/index.php/Mpv#Configuration) to optimize your configuration.
5. If `input.conf` does not exist in `~/.config/mpv/`, create an empty file and paste one of the following code blocks inside the file:
- Note: Only the Homebrew version are built for Native Apple Silicon.
----
**Optimized shaders for lower-end GPU:**
*(Eg. M1, M2)*
*If upscaling to resolutions smaller than 4K, lower end GPUs can be used.*
```
CTRL+1 no-osd change-list glsl-shaders set "~~/shaders/Anime4K_Clamp_Highlights.glsl:~~/shaders/Anime4K_Restore_CNN_M.glsl:~~/shaders/Anime4K_Upscale_CNN_x2_M.glsl:~~/shaders/Anime4K_AutoDownscalePre_x2.glsl:~~/shaders/Anime4K_AutoDownscalePre_x4.glsl:~~/shaders/Anime4K_Upscale_CNN_x2_S.glsl"; show-text "Anime4K: Mode A (Fast)"
CTRL+2 no-osd change-list glsl-shaders set "~~/shaders/Anime4K_Clamp_Highlights.glsl:~~/shaders/Anime4K_Restore_CNN_Soft_M.glsl:~~/shaders/Anime4K_Upscale_CNN_x2_M.glsl:~~/shaders/Anime4K_AutoDownscalePre_x2.glsl:~~/shaders/Anime4K_AutoDownscalePre_x4.glsl:~~/shaders/Anime4K_Upscale_CNN_x2_S.glsl"; show-text "Anime4K: Mode B (Fast)"
CTRL+3 no-osd change-list glsl-shaders set "~~/shaders/Anime4K_Clamp_Highlights.glsl:~~/shaders/Anime4K_Upscale_Denoise_CNN_x2_M.glsl:~~/shaders/Anime4K_AutoDownscalePre_x2.glsl:~~/shaders/Anime4K_AutoDownscalePre_x4.glsl:~~/shaders/Anime4K_Upscale_CNN_x2_S.glsl"; show-text "Anime4K: Mode C (Fast)"
CTRL+4 no-osd change-list glsl-shaders set "~~/shaders/Anime4K_Clamp_Highlights.glsl:~~/shaders/Anime4K_Restore_CNN_M.glsl:~~/shaders/Anime4K_Upscale_CNN_x2_M.glsl:~~/shaders/Anime4K_Restore_CNN_S.glsl:~~/shaders/Anime4K_AutoDownscalePre_x2.glsl:~~/shaders/Anime4K_AutoDownscalePre_x4.glsl:~~/shaders/Anime4K_Upscale_CNN_x2_S.glsl"; show-text "Anime4K: Mode A+A (Fast)"
CTRL+5 no-osd change-list glsl-shaders set "~~/shaders/Anime4K_Clamp_Highlights.glsl:~~/shaders/Anime4K_Restore_CNN_Soft_M.glsl:~~/shaders/Anime4K_Upscale_CNN_x2_M.glsl:~~/shaders/Anime4K_AutoDownscalePre_x2.glsl:~~/shaders/Anime4K_AutoDownscalePre_x4.glsl:~~/shaders/Anime4K_Restore_CNN_Soft_S.glsl:~~/shaders/Anime4K_Upscale_CNN_x2_S.glsl"; show-text "Anime4K: Mode B+B (Fast)"
CTRL+6 no-osd change-list glsl-shaders set "~~/shaders/Anime4K_Clamp_Highlights.glsl:~~/shaders/Anime4K_Upscale_Denoise_CNN_x2_M.glsl:~~/shaders/Anime4K_AutoDownscalePre_x2.glsl:~~/shaders/Anime4K_AutoDownscalePre_x4.glsl:~~/shaders/Anime4K_Restore_CNN_S.glsl:~~/shaders/Anime4K_Upscale_CNN_x2_S.glsl"; show-text "Anime4K: Mode C+A (Fast)"
CTRL+0 no-osd change-list glsl-shaders clr ""; show-text "GLSL shaders cleared"
```
____
#### **Optimized shaders for higher-end GPU:**
(Untested, might still have performance issues at higher resolutions)
*(Eg. M1 Pro, M1 Max, M1 Ultra, M2 Pro, M2 Max)*
*If upscaling to resolutions smaller than 4K, lower end GPUs can be used.*
```
CTRL+1 no-osd change-list glsl-shaders set "~~/shaders/Anime4K_Clamp_Highlights.glsl:~~/shaders/Anime4K_Restore_CNN_VL.glsl:~~/shaders/Anime4K_Upscale_CNN_x2_VL.glsl:~~/shaders/Anime4K_AutoDownscalePre_x2.glsl:~~/shaders/Anime4K_AutoDownscalePre_x4.glsl:~~/shaders/Anime4K_Upscale_CNN_x2_M.glsl"; show-text "Anime4K: Mode A (HQ)"
CTRL+2 no-osd change-list glsl-shaders set "~~/shaders/Anime4K_Clamp_Highlights.glsl:~~/shaders/Anime4K_Restore_CNN_Soft_VL.glsl:~~/shaders/Anime4K_Upscale_CNN_x2_VL.glsl:~~/shaders/Anime4K_AutoDownscalePre_x2.glsl:~~/shaders/Anime4K_AutoDownscalePre_x4.glsl:~~/shaders/Anime4K_Upscale_CNN_x2_M.glsl"; show-text "Anime4K: Mode B (HQ)"
CTRL+3 no-osd change-list glsl-shaders set "~~/shaders/Anime4K_Clamp_Highlights.glsl:~~/shaders/Anime4K_Upscale_Denoise_CNN_x2_VL.glsl:~~/shaders/Anime4K_AutoDownscalePre_x2.glsl:~~/shaders/Anime4K_AutoDownscalePre_x4.glsl:~~/shaders/Anime4K_Upscale_CNN_x2_M.glsl"; show-text "Anime4K: Mode C (HQ)"
CTRL+4 no-osd change-list glsl-shaders set "~~/shaders/Anime4K_Clamp_Highlights.glsl:~~/shaders/Anime4K_Restore_CNN_VL.glsl:~~/shaders/Anime4K_Upscale_CNN_x2_VL.glsl:~~/shaders/Anime4K_Restore_CNN_M.glsl:~~/shaders/Anime4K_AutoDownscalePre_x2.glsl:~~/shaders/Anime4K_AutoDownscalePre_x4.glsl:~~/shaders/Anime4K_Upscale_CNN_x2_M.glsl"; show-text "Anime4K: Mode A+A (HQ)"
CTRL+5 no-osd change-list glsl-shaders set "~~/shaders/Anime4K_Clamp_Highlights.glsl:~~/shaders/Anime4K_Restore_CNN_Soft_VL.glsl:~~/shaders/Anime4K_Upscale_CNN_x2_VL.glsl:~~/shaders/Anime4K_AutoDownscalePre_x2.glsl:~~/shaders/Anime4K_AutoDownscalePre_x4.glsl:~~/shaders/Anime4K_Restore_CNN_Soft_M.glsl:~~/shaders/Anime4K_Upscale_CNN_x2_M.glsl"; show-text "Anime4K: Mode B+B (HQ)"
CTRL+6 no-osd change-list glsl-shaders set "~~/shaders/Anime4K_Clamp_Highlights.glsl:~~/shaders/Anime4K_Upscale_Denoise_CNN_x2_VL.glsl:~~/shaders/Anime4K_AutoDownscalePre_x2.glsl:~~/shaders/Anime4K_AutoDownscalePre_x4.glsl:~~/shaders/Anime4K_Restore_CNN_M.glsl:~~/shaders/Anime4K_Upscale_CNN_x2_M.glsl"; show-text "Anime4K: Mode C+A (HQ)"
CTRL+0 no-osd change-list glsl-shaders clr ""; show-text "GLSL shaders cleared"
```
____
## Usage Instructions for Anime4K
1. Anime4K v4.x has 3 major modes: A, B and C. To enable one of the modes, press CTRL+1 for mode A, CTRL+2 for B and so on. CTRL+0 will clear and disable all the shaders. Each mode is optimized for a different class of anime degradations, explanations are in [Advanced Usage Instructions#modes](GLSL_Instructions_Advanced.md#modes) (soon in the wiki). For now you can just try each mode (starting from A) and use the one that looks the best.
2. To verify the installation was correctly done, enable one of the Anime4K modes and use the MPV profiler to check if there are a few shaders with the name Anime4K running. To access the profiler, press Shift+I and then 2 on the keyboard's top row.
This is what you should see (this example is from v2.0RC2, but also applies to newer versions):
![Profiler](../results/MPV_Profiler.png?raw=true)
3. For advanced usage and more customization options, see the [Advanced Usage Instructions](GLSL_Instructions_Advanced.md) page.
@@ -0,0 +1,34 @@
# Usage Instructions (GLSL / IINA) (v4.x)
## Installing and Setting Up Anime4K for IINA on Apple Silicon and Intel-based Mac
The easiest way to use Anime4K with IINA is to follow our `mpv` guide [**here**](GLSL_Instructions_Mac_MPV.md).
- *Note: you may need to create the `mpv` folder, if you did not install mpv.*
Then follow these steps:
1. Download the latest release of [IINA](https://iina.io/download/), if you haven't already.
2. Open IINA and click on `IINA` in the top menu bar. Then click on `Settings...` from the drop-down menu.
<img width="400" src="Screenshots/Mac/IINA/Settings.png">
3. In the `Settings`>`Advanced` window, click on `Enable advanced settings` and then select `Use config directory: ~/.config/mpv/`.
<img width="800" src="Screenshots/Mac/IINA/Advanced.png">
4. That's it! Anime4K is now ready to use with IINA.
____
## Quick Usage Instructions
1. Anime4K has 3 major modes: A, B, and C. Each mode is optimized for a different class of anime degradations.
- Mode A is automatically enabled, if you use our template (this can be change in `mpv.conf`).
2. To enable each mode manually:
- Press **CTRL+1** to enable Mode A (Optimized for 1080p Anime).
- Press **CTRL+2** to enable Mode B (Optimized for 720p Anime).
- Press **CTRL+3** to enable Mode C (Optimized for 480p Anime).
- Press **CTRL+0** to clear all shaders (Disable Anime4K).
3. For more explanations and customization options, see the [Advanced Usage Instructions](GLSL_Instructions_Advanced.md#advanced-usage-instructions-glsl--mpv-v4x).
@@ -0,0 +1,71 @@
# Usage Instructions (GLSL / MPV) (v4.x)
## Installing and Setting Up Anime4K for mpv on Apple Silicon and Intel-based Mac
*If you wish to use another media player, look at their documentation on how to install GLSL shaders and modify the shader accordingly if needed.*
1. Install mpv via [Homebrew](https://formulae.brew.sh/formula/mpv) or download the latest release [here](https://laboratory.stolendata.net/~djinn/mpv_osx/mpv-latest.tar.gz).
- **Note:** Only the Homebrew version is built for native Apple Silicon.
- <details>
<summary>Click Here for Homebrew Installation</summary>
<ol type="1">
<li>If Homebrew is not installed, follow the instructions at <a href="https://brew.sh">https://brew.sh</a> to install it.</li>
<li>Keep the terminal window open and follow the instructions under "Next steps" to add Homebrew to your PATH.</li>
<li>Follow the instructions at <a href="https://formulae.brew.sh/formula/mpv">https://formulae.brew.sh/formula/mpv</a> to install mpv.</li>
</ol>
</details>
2. Open mpv (this will create the mpv config file location for you).
3. Download the template files and extract them (open the `.zip` file).
- **Optimized shaders for lower-end GPU:**
*(Eg. M1, M2, Intel chips)*
- Download the template files [here](https://github.com/Tama47/Anime4K/releases/download/v4.0.1/GLSL_Mac_Linux_Low-end.zip).
- <details>
<summary>Or click here to install manually.</summary>
<ul>
<li>Copy & Paste the code from <a href="Template/GLSL_Mac_Linux_Low-end/input.conf">input.conf</a> and <a href="Template/GLSL_Mac_Linux_Low-end/mpv.conf">mpv.conf</a> in your <code>input.conf</code> and <code>mpv.conf</code> file.</li>
<li>Then download and extract the shaders from <a href="https://github.com/bloc97/Anime4K/releases">releases</a> and put them in the <code>shaders</code> folder.</li>
</ul>
</details>
- **Optimized shaders for higher-end GPU:**
*(Eg. M1 Pro, M1 Max, M1 Ultra, M2 Pro, M2 Max, Intel chips)*
(Untested, might still have performance issues)
- Download the template files [here](https://github.com/Tama47/Anime4K/releases/download/v4.0.1/GLSL_Mac_Linux_High-end.zip).
- <details>
<summary>Or click here to install manually.</summary>
<ul>
<li>Copy & Paste the code from <a href="Template/GLSL_Mac_Linux_High-end/input.conf">input.conf</a> and <a href="Template/GLSL_Mac_Linux_High-end/mpv.conf">mpv.conf</a> in your <code>input.conf</code> and <code>mpv.conf</code> file.</li>
<li>Then download and extract the shaders from <a href="https://github.com/bloc97/Anime4K/releases">releases</a> and put them in the <code>shaders</code> folder.</li>
</ul>
</details>
4. In the Finder on your Mac, choose `Go` > `Go to Folder...`
<img width="500" src="Screenshots/Mac/Finder.png">
5. Paste `~/.config/mpv/` and hit Enter.
<img width="500" src="Screenshots/Mac/mpv/location.png">
6. Move the `input.conf`, `mpv.conf`, and the `shaders` folder into the `mpv` folder.
<img width="800" src="Screenshots/Mac/mpv/config.png">
7. That's it! Anime4K is now installed and ready to use.
____
## Quick Usage Instructions
1. Anime4K has 3 major modes: A, B, and C. Each mode is optimized for a different class of anime degradations.
- Mode A is automatically enabled, if you use our template (this can be change in `mpv.conf`).
2. To enable each mode manually:
- Press **CTRL+1** to enable Mode A (Optimized for 1080p Anime).
- Press **CTRL+2** to enable Mode B (Optimized for 720p Anime).
- Press **CTRL+3** to enable Mode C (Optimized for 480p Anime).
- Press **CTRL+0** to clear all shaders (Disable Anime4K).
3. For more explanations and customization options, see the [Advanced Usage Instructions](GLSL_Instructions_Advanced.md#advanced-usage-instructions-glsl--mpv-v4x).
@@ -0,0 +1,63 @@
# Usage Instructions (GLSL / PLEX) (v4.x)
## Installing and Setting Up Anime4K for Plex on Apple Silicon and Intel-Based Mac
1. Download `Plex for Mac` or `Plex HTPC (for macOS Home Theater PCs)` from [**here**](https://www.plex.tv/media-server-downloads/#plex-app).
- *Note: Only the desktop version of the app supports GLSL shaders.*
2. Open `Plex` or `Plex HTPC` (this will create the Application Support location for you).
3. Download the template files and extract them (open the .zip file).
- **Optimized shaders for lower-end GPU:**
*(Eg. M1, M2, Intel chips)*
- Download the template files [here](https://github.com/Tama47/Anime4K/releases/download/v4.0.1/GLSL_Mac_Linux_Low-end.zip).
- <details>
<summary>Or click here to install manually.</summary>
<ul>
<li>Copy & Paste the code from <a href="Template/GLSL_Mac_Linux_Low-end/input.conf">input.conf</a> and <a href="Template/GLSL_Mac_Linux_Low-end/mpv.conf">mpv.conf</a> in your <code>input.conf</code> and <code>mpv.conf</code> file.</li>
<li>Then download and extract the shaders from <a href="https://github.com/bloc97/Anime4K/releases">releases</a> and put them in the <code>shaders</code> folder.</li>
</ul>
</details>
- **Optimized shaders for higher-end GPU:**
*(Eg. M1 Pro, M1 Max, M1 Ultra, M2 Pro, M2 Max, Intel chips)*
(Untested, might still have performance issues)
- Download the template files [here](https://github.com/Tama47/Anime4K/releases/download/v4.0.1/GLSL_Mac_Linux_High-end.zip).
- <details>
<summary>Or click here to install manually.</summary>
<ul>
<li>Copy & Paste the code from <a href="Template/GLSL_Mac_Linux_High-end/input.conf">input.conf</a> and <a href="Template/GLSL_Mac_Linux_High-end/mpv.conf">mpv.conf</a> in your <code>input.conf</code> and <code>mpv.conf</code> file.</li>
<li>Then download and extract the shaders from <a href="https://github.com/bloc97/Anime4K/releases">releases</a> and put them in the <code>shaders</code> folder.</li>
</ul>
</details>
4. In the Finder on your Mac, choose `Go` > `Go to Folder...`
<img width="500" src="Screenshots/Mac/Finder.png">
5. Paste `~/Library/Application Support/Plex/` or `~/Library/Application Support/Plex HTPC/` and hit Enter.
<img width="500" src="Screenshots/Mac/Plex/location.png"><br>
<img width="500" src="Screenshots/Mac/Plex HTPC/location.png">
6. Move the `input.conf`, `mpv.conf`, and the `shaders` folder into the `Plex` or `Plex HTPC` folder.
<img width="800" src="Screenshots/Mac/Plex/config.png"><br>
<img width="800" src="Screenshots/Mac/Plex HTPC/config.png">
7. That's it! Anime4K is now installed and ready to use.
____
## Quick Usage Instructions
1. Anime4K has 3 major modes: A, B, and C. Each mode is optimized for a different class of anime degradations.
- Mode A is automatically enabled, if you use our template (this can be change in `mpv.conf`).
2. To enable each mode manually:
- Press **CTRL+1** to enable Mode A (Optimized for 1080p Anime).
- Press **CTRL+2** to enable Mode B (Optimized for 720p Anime).
- Press **CTRL+3** to enable Mode C (Optimized for 480p Anime).
- Press **CTRL+0** to clear all shaders (Disable Anime4K).
3. For more explanations and customization options, see the [Advanced Usage Instructions](GLSL_Instructions_Advanced.md#advanced-usage-instructions-glsl--mpv-v4x).
@@ -0,0 +1,20 @@
# Usage Instructions (GLSL / PLEX MPV) (v4.x)
## Installing and setting up Anime4K for Plex Media Player/Plex HTPC
1. Install Plex Media Player or Plex HTPC from [**here**](https://www.plex.tv/media-server-downloads/#plex-app)
2. Download the .glsl shader files [**here**](https://github.com/bloc97/Anime4K/releases)
3. Copy the .glsl files to `~/Library/Application Support/Plex/shaders` or `~/Library/Application Support/Plex HTPC/shaders` for Mac and `%LOCALAPPDATA%\Plex\shaders` or `%LOCALAPPDATA%\Plex HTPC\shaders` for Windows.
4. (Optional) If `mpv.conf` does not exist in `~/Library/Application Support/Plex/`, `~/Library/Application Support/Plex HTPC/`, `%LOCALAPPDATA%\Plex\`, or `%LOCALAPPDATA%\Plex HTPC\`, create an empty file and follow [**these instructions**](https://wiki.archlinux.org/index.php/Mpv#Configuration) to optimize your configuration.
5. If `input.conf` does not exist in `~/Library/Application Support/Plex/`, `~/Library/Application Support/Plex HTPC/`, `%LOCALAPPDATA%\Plex\`, or `%LOCALAPPDATA%\Plex HTPC\`, create an empty file and paste one of the following code blocks inside the file:
- Note: Only works on the desktop version of the app.
----
## Follow Device Specific Installation
- Installation Instructions can be found [**here**](https://github.com/bloc97/Anime4K#installation-instructions)
@@ -0,0 +1,56 @@
# Usage Instructions (GLSL / MPV) (v4.x)
## Installing and Setting Up Anime4K for mpv on Windows
*If you wish to use another media player, look at their documentation on how to install GLSL shaders and modify the shader accordingly if needed.*
1. Download the latest release of mpv [**here**](https://sourceforge.net/projects/mpv-player-windows/files/latest/download).
2. Open mpv (this will create the mpv config file location for you).
3. Download the template files, and extract it (open the .zip file).
- **Optimized shaders for lower-end GPU:**
*(Eg. GTX 980, GTX 1060, RX 570)*
- Download the template files [here](https://github.com/Tama47/Anime4K/releases/download/v4.0.1/GLSL_Windows_Low-end.zip).
- <details>
<summary>Or click here to install manually.</summary>
<ul>
<li>Copy & Paste the code from <a href="Template/GLSL_Windows_Low-end/input.conf">input.conf</a> and <a href="Template/GLSL_Windows_Low-end/mpv.conf">mpv.conf</a> in your <code>input.conf</code> and <code>mpv.conf</code> file.</li>
<li>Then download and extract the shaders from <a href="https://github.com/bloc97/Anime4K/releases">releases</a> and put them in the <code>shaders</code> folder.</li>
</ul>
</details>
- **Optimized shaders for higher-end GPU:**
*(Eg. GTX 1080, RTX 2070, RTX 3060, RX 590, Vega 56, 5700XT, 6600XT)*
- Download the template files [here](https://github.com/Tama47/Anime4K/releases/download/v4.0.1/GLSL_Windows_High-end.zip).
- <details>
<summary>Or click here to install manually.</summary>
<ul>
<li>Copy & Paste the code from <a href="Template/GLSL_Windows_High-end/input.conf">input.conf</a> and <a href="Template/GLSL_Windows_High-end/mpv.conf">mpv.conf</a> in your <code>input.conf</code> and <code>mpv.conf</code> file.</li>
<li>Then download and extract the shaders from <a href="https://github.com/bloc97/Anime4K/releases">releases</a> and put them in the <code>shaders</code> folder.</li>
</ul>
</details>
4. Open File Explorer and type in `%APPDATA%/mpv`, then hit Enter.
<img width="800" src="Screenshots/Windows/mpv/location.png">
5. Move the `input.conf`, `mpv.conf` and the `shaders` folder into the `mpv` folder.
<img width="800" src="Screenshots/Windows/mpv/config.png">
6. That's it, Anime4K is now installed and ready to use!
____
## Quick Usage Instructions
1. Anime4K has 3 major modes: A, B, and C. Each mode is optimized for a different class of anime degradations.
- Mode A is automatically enabled, if you use our template (this can be change in `mpv.conf`).
2. To enable each mode manually:
- Press **CTRL+1** to enable Mode A (Optimized for 1080p Anime).
- Press **CTRL+2** to enable Mode B (Optimized for 720p Anime).
- Press **CTRL+3** to enable Mode C (Optimized for 480p Anime).
- Press **CTRL+0** to clear all shaders (Disable Anime4K).
3. For more explanations and customization options, see the [Advanced Usage Instructions](GLSL_Instructions_Advanced.md#advanced-usage-instructions-glsl--mpv-v4x).
@@ -0,0 +1,58 @@
# Usage Instructions (GLSL / PLEX) (v4.x)
## Installing and Setting Up Anime4K for Plex on Windows
1. Download `Plex for Windows` or `Plex HTPC (for Windows Home Theater PCs)` from [**here**](https://www.plex.tv/media-server-downloads/#plex-app).
- *Note: Only the desktop version of the app supports GLSL shaders.*
2. Open `Plex` or `Plex HTPC` (this will create the config location for you).
3. Download the template files, and extract it (open the .zip file).
- **Optimized shaders for lower-end GPU:**
*(Eg. GTX 980, GTX 1060, RX 570)*
- Download the template files [here](https://github.com/Tama47/Anime4K/releases/download/v4.0.1/GLSL_Windows_Low-end.zip).
- <details>
<summary>Or click here to install manually.</summary>
<ul>
<li>Copy & Paste the code from <a href="Template/GLSL_Windows_Low-end/input.conf">input.conf</a> and <a href="Template/GLSL_Windows_Low-end/mpv.conf">mpv.conf</a> in your <code>input.conf</code> and <code>mpv.conf</code> file.</li>
<li>Then download and extract the shaders from <a href="https://github.com/bloc97/Anime4K/releases">releases</a> and put them in the <code>shaders</code> folder.</li>
</ul>
</details>
- **Optimized shaders for higher-end GPU:**
*(Eg. GTX 1080, RTX 2070, RTX 3060, RX 590, Vega 56, 5700XT, 6600XT)*
- Download the template files [here](https://github.com/Tama47/Anime4K/releases/download/v4.0.1/GLSL_Windows_High-end.zip).
- <details>
<summary>Or click here to install manually.</summary>
<ul>
<li>Copy & Paste the code from <a href="Template/GLSL_Windows_High-end/input.conf">input.conf</a> and <a href="Template/GLSL_Windows_High-end/mpv.conf">mpv.conf</a> in your <code>input.conf</code> and <code>mpv.conf</code> file.</li>
<li>Then download and extract the shaders from <a href="https://github.com/bloc97/Anime4K/releases">releases</a> and put them in the <code>shaders</code> folder.</li>
</ul>
</details>
4. Open File Explorer and type in `%LOCALAPPDATA%\Plex` or `%LOCALAPPDATA%\Plex HTPC`, then hit Enter.
<img width="800" src="Screenshots/Windows/Plex/location.png">
<img width="800" src="Screenshots/Windows/Plex HTPC/location.png">
5. Move the `input.conf`, `mpv.conf` and the `shaders` folder into the into the `Plex` or `Plex HTPC` folder.
<img width="800" src="Screenshots/Windows/Plex/config.png">
<img width="800" src="Screenshots/Windows/Plex HTPC/config.png">
6. That's it, Anime4K is now installed and ready to use!
____
## Quick Usage Instructions
1. Anime4K has 3 major modes: A, B, and C. Each mode is optimized for a different class of anime degradations.
- Mode A is automatically enabled, if you use our template (this can be change in `mpv.conf`).
2. To enable each mode manually:
- Press **CTRL+1** to enable Mode A (Optimized for 1080p Anime).
- Press **CTRL+2** to enable Mode B (Optimized for 720p Anime).
- Press **CTRL+3** to enable Mode C (Optimized for 480p Anime).
- Press **CTRL+0** to clear all shaders (Disable Anime4K).
3. For more explanations and customization options, see the [Advanced Usage Instructions](GLSL_Instructions_Advanced.md#advanced-usage-instructions-glsl--mpv-v4x).