Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Custom shader #21

Open
wants to merge 7 commits into
base: master
Choose a base branch
from
Open

Conversation

AnnieQiuuu
Copy link

vert.glsl:

  • Introduce the u_Time as the increment variable
  • Use sin function to distort the vertex postition to make it swing according to time

frag.glsl:

  • Introduce the u_Time as the increment variable
  • Introduce the u_Transparency to control the transparency of the geometry
  • Implemented Fractal Brownian Motion function based on Perlin noise
  • Generated noise fluctuates over time
  • Inteporlate between background color and geometry color to achieve the effect of smooth fusion of the object and the background

main.ts:

  • color can be modified with the palette
  • transparency of the geometry can be modified with the slide

Live demo: https://annieqiuuu.github.io/hw00-intro-base/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant