From b09093ff9bd05c1a50fe355258d81079b916a063 Mon Sep 17 00:00:00 2001 From: hiulit Date: Tue, 20 Oct 2020 16:37:25 +0200 Subject: [PATCH] Bumped to v2.0.0 --- CHANGELOG.md | 37 ++++++++++++++++++++++++++++++++----- README.md | 11 ++++++++--- crt_shader.shader | 4 ++-- 3 files changed, 42 insertions(+), 10 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 05b373c..a90aa4f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,22 +4,49 @@ * Up to date. +## [2.0.0] - 2020-10-20 + +**NOTE**: This release contains breaking changes. + +The parameters are basically the same but with new names. Check the [documentation](https://github.com/hiulit/Godot-3-2D-CRT-Shader/tree/master#shader-parameters). + +### Added + +* `curvature_x_amount` - Controls the curvature on the X axis. +* `curvature_y_amount` - Controls the curvature on the Y axis. + +### Changed + +* Every mention to **grille** is now referred as **vertical scan lines**. + +### Deprecated + +* ~~`scanlines_speed`~~ +* ~~`move_aberration`~~ +* ~~`aberration_speed`~~ + +## [1.3.1] - 2020-10-19 + +### Fixed + +* The scanlines and grille are now non-destructive. This allows to lower the opacity of the scanlines and grille without resulting in a completely black screen. Thanks to [Miltag](https://github.com/Miltage) for helping with this issue [#5](https://github.com/hiulit/Godot-3-2D-CRT-Shader/pull/5). + ## [1.3.0] - 2019-09-13 -## Added +### Added * New parameter: `aberration_amount` - To control the amount of aberration. * New parameter: `move_aberration` - To control the movement state of the aberration. * New parameter: `aberration_speed` - To control the speed of the moving aberration. -## Changed +### Changed * `boost` parameter now can go up to `2.0`. * `vignette` now depends on the screen size. ## [1.2.0] - 2019-07-18 -## Added +### Added * Screen texture and scanlines are now affected by curvature. * New parameter: `grille_opacity` - To control the opacity of the grille. @@ -27,12 +54,12 @@ * New parameter: `scanlines_speed` - To control the speed of the scanlines. * New parameter: `screen_size` - To control how many grille lines and scanlines appear. -## Changed +### Changed * `boost` and `vignette_opacity` steps are now `0.01`. * `vignette_opacity` default value is now `0.2`. -## Deprecated +### Deprecated * Parameter: `blend_color` - No longer needed. diff --git a/README.md b/README.md index b1ea08e..0edf9d2 100644 --- a/README.md +++ b/README.md @@ -71,10 +71,12 @@ Works best in `window/stretch/mode="2d"`. | Name | Type | Default | Description | | --- | --- | --- | --- | -| `horizontal_scan_lines_amount` | `float` | `180.0` | Controls how many horizontal scan lines appear. | +| `horizontal_scan_lines_amount` | `float` | `180.0` | Controls how many horizontal scan lines appear. Range from `0.0` to `180.0` with `0.1` steps. | Setting it to your project's `windows/size/height` should work fine, but you can play with it to get the results best fitted to your liking. +Having fewer scan lines will make them larger, which makes it harder for the moire effect to appear. + ### Horizontal scan lines opacity | Name | Type | Default | Description | @@ -91,10 +93,12 @@ Setting it to your project's `windows/size/height` should work fine, but you can | Name | Type | Default | Description | | --- | --- | --- | --- | -| `vertical_scan_lines_amount` | `float` | `320.0` | Controls how many vertical scan lines appear. | +| `vertical_scan_lines_amount` | `float` | `320.0` | Controls how many vertical scan lines appear. Range from `0.0` to `320.0` with `0.1` steps. | Setting it to your project's `windows/size/width` should work fine, but you can play with it to get the results best fitted to your liking. +Having fewer scan lines will make them larger, which makes it harder for the moire effect to appear. + ### Vertical scan lines opacity | Name | Type | Default | Description | @@ -111,7 +115,7 @@ Setting it to your project's `windows/size/width` should work fine, but you can | Name | Type | Default | Description | | --- | --- | --- | --- | -| `aberration_amount` | `float` | `0.0` | Controls the amount of chromatic aberration. Range from `0.0` to `10.0` with `1.0` steps. | +| `aberration_amount` | `float` | `0.0` | Controls the amount of chromatic aberration. Range from `0.0` to `10.0` with `0.01` steps. | ## Changelog @@ -128,6 +132,7 @@ Thanks to: * **knarkowicz** - For the orginal shader code, taken from https://www.shadertoy.com/view/XtlSD7. * [CowThing](https://github.com/CowThing) - For helping **a lot** in bringing actual distortion and many other improvements to the shader with [#1](https://github.com/hiulit/Godot-3-2D-CRT-Shader/pull/1). * [uheartbeast](https://twitter.com/uheartbeast) - For the amazing [chromatic aberration shader video tutorial](https://www.youtube.com/watch?v=-PJOHAsBcoI). +* [Miltag](https://github.com/Miltage) - For helping in fixing an issue with the scan lines opacity [#5](https://github.com/hiulit/Godot-3-2D-CRT-Shader/pull/5). * [Tom (Let's GameDev)](https://twitter.com/letsgamedev) - For the amazing [CRT shader video tutorial](https://www.youtube.com/watch?v=Dn8joy4tP2Q), which I took the scan lines from. ## License diff --git a/crt_shader.shader b/crt_shader.shader index b2f9902..9a466f0 100644 --- a/crt_shader.shader +++ b/crt_shader.shader @@ -20,10 +20,10 @@ uniform vec4 corner_color : hint_color = vec4(0.0, 0.0, 0.0, 1.0); uniform bool show_vignette = true; uniform float vignette_opacity : hint_range(0.0, 1.0, 0.01) = 0.2; uniform bool show_horizontal_scan_lines = true; -uniform float horizontal_scan_lines_amount : hint_range(0.0, 180.0) = 180.0; +uniform float horizontal_scan_lines_amount : hint_range(0.0, 180.0, 0.1) = 180.0; uniform float horizontal_scan_lines_opacity : hint_range(0.0, 1.0, 0.01) = 1.0; uniform bool show_vertical_scan_lines = false; -uniform float vertical_scan_lines_amount : hint_range(0.0, 320.0) = 320.0; +uniform float vertical_scan_lines_amount : hint_range(0.0, 320.0, 0.1) = 320.0; uniform float vertical_scan_lines_opacity : hint_range(0.0, 1.0, 0.01) = 1.0; uniform float boost : hint_range(1.0, 2.0, 0.01) = 1.2; uniform float aberration_amount : hint_range(0.0, 10.0, 0.01) = 0.0;