Skip to content

sasmaster/webgl

Folders and files

NameName
Last commit message
Last commit date

Latest commit

de7ff83 · Jan 11, 2024

History

32 Commits
Mar 5, 2023
Sep 20, 2022
Oct 31, 2022
Jan 11, 2024
Mar 24, 2023
Jan 11, 2024
Nov 18, 2022
Nov 18, 2022
Mar 5, 2023
Mar 5, 2023
Mar 5, 2023
Jan 11, 2024
Dec 26, 2023
Jun 30, 2018
Mar 5, 2023
Nov 18, 2022
Jun 30, 2018
Nov 18, 2022
Jan 11, 2024
Nov 18, 2022
Dec 23, 2023
Nov 18, 2022
Dec 23, 2023
Dec 26, 2023

Repository files navigation

webgl

This repo contains my personal experiments with WebGL API.

Make sure your browser supports WebGL 2.0 as all the samples use WebGL2.0 context and API.

Dependencies:

Currently only glMatrix lib for transformations.

Samples:

simple_vao.js - shows how to draw a quad using VAO (Vertex Array Object)

indexed_vao.js - shows how to draw a quad using VAO and indexed buffer (drawElements)

ubo_instanced.js - shows how to render 1024 quads using Uniform buffer containing transforms in a single draw call.

texture_mapping.js - shows how to render a mesh with texture mapped onto it.

frame_buffer.js - shows how to render to texture using offscreen fbo.

frame_buffer_multisampled.js - shows how to setup a multi-sampled(MSAA) offscfeen FBO and blit it to screen.

gauss-blur.js - explores different moethods of gaussian blur image effect (work in progress)

screen-tri.js - good old trick to render full screen pass using a triangle rather than rectangle

texel_size.js - shows how to sample and draw a texture in screen space and only in the area equal texture size in pixels.

video_decode.js - shows how to decode an mp4 video,using Web Codecs extensions (Chrome,Firefox only) and present on a webgl surface.

video_decode_html_element.js - shows how to decode an mp4 video using HTMLMediaElement object

gauss_blur_optimized_dynamic.js - shows fast (Separated) gaussian blur implementation using a technique by NVIDIA's to calculate coeffieicents in fragment shader

texture_color.js - shows how to update texture with color from typed array.

About

WebGL 2.0 API and image processing experiments

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published