Giter VIP home page Giter VIP logo

godot-3-2d-crt-shader's Introduction

Godot 3 2D CRT Shader

A 2D shader for Godot 3 simulating a CRT.

A 2D shader for Godot 3 simulating a CRT - OFF A 2D shader for Godot 3 simulating a CRT- ON

Usage

  • Create a CanvasLayer.
  • Add a ColorRect as a child node of the CanvasLayer.
  • In the ColorRect properties:
    • Go to the Material section.
    • Click on the [empty] Material and load crt_material.tres.

If, for for reason, when loading the crt_material.tres, the crt.shader is empty, just open it with any text editor, copy the code in the Shader editor and save it.

Shader Parameters

Blend Color

Name Type Default Description
blend_color vec4 vec4(1.0, 1.0, 1.0, 1.0) White is complete transparent. Black is complete opaque. The in-between colors get blended with the canvas.

Boost

Name Type Default Description
boost float 1.2 Gives extra brightness to compensate for the scanlines and the vignette. Range from 1.0 to 1.5 with 0.05 steps.

Vignette opacity

Name Type Default Description
vignette_opacity float 0.3 Control the opacity of the vignette. Range from 0.1 to 0.5 with 0.05 steps.

Show grille

Name Type Default Description
show_grille bool true Enable/disable the grille.

Only works in window/stretch/mode="2d".

Show scanlines

Name Type Default Description
show_scanlines bool true Enable/disable the scanlines.

Show vignette

Name Type Default Description
show_vignette bool true Enable/disable the vignette.

Show curvature

Name Type Default Description
show_curvature bool true Enable/disable the curvature.

Changelog

See CHANGELOG.

Authors

Credits

Orginal code by knarkowicz. Taken from https://www.shadertoy.com/view/XtlSD7 .

License

MIT License.

godot-3-2d-crt-shader's People

Contributors

hiulit avatar

Stargazers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.