All Projects → cjgammon → Hydrogen

cjgammon / Hydrogen

Licence: other
SUPER Lightweight Canvas Display List for drawing objects on 2D Canvas

Programming Languages

javascript
184084 projects - #8 most used programming language

Projects that are alternatives of or similar to Hydrogen

pmj-cpp
"Progressive Multi-Jittered Sample Sequences" in C++
Stars: ✭ 34 (+161.54%)
Mutual labels:  rendering
DuEngine
An efficient interactive C++ renderer for ShaderToy-alike demos with 2D/3D/CubeMap/Video/Camera/LightField/Volume textures. (Partially used in my I3D 2018 papers)
Stars: ✭ 62 (+376.92%)
Mutual labels:  rendering
osci-render
〰📺🔊 Software for making music by drawing objects on an oscilloscope using audio.
Stars: ✭ 135 (+938.46%)
Mutual labels:  rendering
Messier87
A realtime raytracing blackhole renderer
Stars: ✭ 53 (+307.69%)
Mutual labels:  rendering
GoldenSun
A path tracer based on hardware ray tracing
Stars: ✭ 20 (+53.85%)
Mutual labels:  rendering
FunMirrors
This is a fun project I created to motivate computer vision enthusiasts and to highlight the importance of understanding fundamental concepts related to image formation in a camera.
Stars: ✭ 43 (+230.77%)
Mutual labels:  rendering
ign-rendering
C++ library designed to provide an abstraction for different rendering engines. It offers unified APIs for creating 3D graphics applications.
Stars: ✭ 34 (+161.54%)
Mutual labels:  rendering
phantom
👻 A reactive DOM rendering engine for building UIs.
Stars: ✭ 16 (+23.08%)
Mutual labels:  rendering
Squirrel-Engine
Multithreaded C/C++ Game Engine
Stars: ✭ 90 (+592.31%)
Mutual labels:  rendering
ForkerRenderer
CPU-Based Software Forward / Deferred Rasterizer, A Tiny OpenGL (PBR, Soft Shadow, SSAO) 🐼
Stars: ✭ 17 (+30.77%)
Mutual labels:  rendering
docker-opengl
Multi-Arch Docker - Mesa 3D OpenGL Software Rendering (Gallium) - LLVMpipe, and OpenSWR Drivers
Stars: ✭ 68 (+423.08%)
Mutual labels:  rendering
mcrt
Monte Carlo Raytracer from Scratch in C++11/14
Stars: ✭ 22 (+69.23%)
Mutual labels:  rendering
safemd
Safety first markdown rendering
Stars: ✭ 77 (+492.31%)
Mutual labels:  rendering
Kuplung
OpenGL Model Viewer
Stars: ✭ 15 (+15.38%)
Mutual labels:  rendering
blender-addon
Blender Addon to render light fields with depth and disparity maps
Stars: ✭ 106 (+715.38%)
Mutual labels:  rendering
fluctus
An interactive OpenCL wavefront path tracer
Stars: ✭ 55 (+323.08%)
Mutual labels:  rendering
evplp
Implementation of Efficient Energy-Compensated VPLs using Photon Splatting (and various rendering techniques)
Stars: ✭ 26 (+100%)
Mutual labels:  rendering
RefRESH
Create RefRESH data: dataset tools for Learning Rigidity in Dynamic Scenes with a Moving Camera for 3D Motion Field Estimation (ECCV 2018)
Stars: ✭ 51 (+292.31%)
Mutual labels:  rendering
PintarJS
Micro JS lib for direct WebGL and canvas rendering.
Stars: ✭ 15 (+15.38%)
Mutual labels:  rendering
cadise
A developing physically-based hobby renderer written in C++.
Stars: ✭ 30 (+130.77%)
Mutual labels:  rendering

Hydrogen

Intended to be a SUPER Lightweight Canvas Display List for drawing and animating objects on 2D Canvas

File size: 1kb

Below is an example of how to use with a loaded texture named tex.jpg.

<html>
    <head>
    </head>
    <body>
        <canvas id="mycanvas"></canvas>
        <script src="src/H.js"></script>
        <script>
            var _h = new H.Canvas('mycanvas'); //create a canvas instance using a DOM element

            _t = new Image();                  //create an image to be used as texture
            _t.src = "tex.jpg";
            _t.onload = function () {
                //texture has loaded
            }

            _s = new H.Sprite(_t);             //create a sprite with texture
            _s.s = 0.2;                        //scale
            _h.addChild(_s);                   //add to 'stage'

            var _h2 = new H.Canvas(500, 500);  //create a canvas instance with width and height
            document.body.appendChild(_h2.el); //append to DOM

            _s2 = new H.Sprite(_t);
            _s2.sy = 0.1;                      //scale y
            _s2.ox = 100;                      //set origin x (rotate and scale origin)
            _s2.oy = 100;                      //set origin y
            _h.addChild(_s2);                  //add to stage
            _h2.addChild(_s2);

            requestAnimationFrame(render);

            delta = 0;

            function render() {
                delta += 0.1;

                _h.render();                  //render the canvas
                _h2.render();

                _s.x += 1;                    //update values
                _s2.r += 0.01;
                _s2.sx = Math.sin(delta);

                requestAnimationFrame(render);
            }

        </script>
    </body>
</html>
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].