Популярное

Музыка Кино и Анимация Автомобили Животные Спорт Путешествия Игры Юмор

Интересные видео

2025 Сериалы Трейлеры Новости Как сделать Видеоуроки Diy своими руками

Топ запросов

смотреть а4 schoolboy runaway турецкий сериал смотреть мультфильмы эдисон
dTub
Скачать

OpenGL Fragment Shaders | How Do Fragment Shaders Work?

programming

software development

tutorial

how-to

opengl

shaders

glsl

Автор: An Object Is A

Загружено: 17 дек. 2019 г.

Просмотров: 9 471 просмотр

Описание:

How are fragment shaders actually working?

More than one color on screen?

Why so difficult?

This series is based off of the free on-line book, "The Book Of Shaders", by Patricio Gonzalez Vivo and Jen Lowe.
https://thebookofshaders.com/

If you feel like donating, please donate to those two; a donation link is found on their website linked above.

Previous video:    • OpenGL Fragment Shaders | GLSL and Ou...  

Editor used: https://patriciogonzalezvivo.github.i...


Subscribe to my channel:    / @anobj  

If you find value in what I do, think about supporting my channel:
Paypal: https://www.paypal.me/anobjisa
Bitcoin: 3H4NKKwPdbiE5Gtc3Uk2DiwszqHhrRbmKK
Ethereum: 0x48702412F448a27be03836fb6FE6456603668030
Litecoin: MNJ4uv3GD4r62VpQ8rHX1Pj1ihWCj74hCK

Find me here:
Bitchute: https://www.bitchute.com/channel/gPUm...
Twitter:   / anobjectisa1  
Minds: https://www.minds.com/an_object_is_a/
Instagram:   / an_object_is_a  

Code used:

1.

#ifdef GL_ES
precision mediump float;
#endif

uniform vec2 u_resolution;

void main() {
vec2 st = gl_FragCoord.xy/u_resolution;

// Youtube descriptions do not allow the angle brackets
// gteq = greater than or equal to
// lteq = less than or equal to
if (st.x gteq 0.500 && st.x lteq 0.503 &&
st.y gteq 0.500 && st.y lteq 0.503) {
gl_FragColor = vec4(1.,1.0,1.0,1.0);
} else {
gl_FragColor = vec4(0.,0.0,0.0,1.0);
}
}

2.

#ifdef GL_ES
precision mediump float;
#endif

uniform vec2 u_resolution;

void main() {
vec2 st = gl_FragCoord.xy/u_resolution;
vec3 canvas = vec3(1.0);

canvas = mix(canvas, vec3(1.0,0.0,0.0), st.x);
gl_FragColor = vec4(canvas, 1.0);
}

OpenGL Fragment Shaders | How Do Fragment Shaders Work?

Поделиться в:

Доступные форматы для скачивания:

Скачать видео mp4

  • Информация по загрузке:

Скачать аудио mp3

Похожие видео

OpenGL Fragment Shaders | How Do Fragment Shaders Pick a Color?

OpenGL Fragment Shaders | How Do Fragment Shaders Pick a Color?

Introduction to shaders: Learn the basics!

Introduction to shaders: Learn the basics!

Graphics Pipeline Overview - Vulkan Game Engine Tutorial 02

Graphics Pipeline Overview - Vulkan Game Engine Tutorial 02

An introduction to Shader Art Coding

An introduction to Shader Art Coding

Building custom fragment shaders - Flutter Build Show

Building custom fragment shaders - Flutter Build Show

How Big Budget AAA Games Render Clouds

How Big Budget AAA Games Render Clouds

Mega Hits 2025 🌱 The Best Of Vocal Deep House Music Mix 2025 🌱 Summer Music Mix 2025 #4

Mega Hits 2025 🌱 The Best Of Vocal Deep House Music Mix 2025 🌱 Summer Music Mix 2025 #4

React Parallax Scrolling Web Design Solution | Build Cooler React Websites

React Parallax Scrolling Web Design Solution | Build Cooler React Websites

Музыка для работы - Deep Focus Mix для программирования, кодирования

Музыка для работы - Deep Focus Mix для программирования, кодирования

How The Wind Waker Redefined Cel Shading

How The Wind Waker Redefined Cel Shading

© 2025 dtub. Все права защищены.



  • Контакты
  • О нас
  • Политика конфиденциальности



Контакты для правообладателей: [email protected]