derelict-nanovg 1.0.0

A dynamic binding to the nanovg library.


To use this package, put the following dependency into your project's dependencies section:

dub.json
dub.sdl

/ Work in progress /

nanovg

NanoVG is small antialiased vector graphics rendering library for OpenGL

Author : Mikko Mononen https://github.com/memononen/nanovg

DerelictNANOVG

Dynamic bindings to the nanovg library for the D programming language.

How to use

You need a valid GL3 context to use nanovg (I will add nvgCreateGL2 and GLes later !);

You just need to create a NVGContext :

DerelictGL3.reload();
DerelictNANOVG.load();

auto nvg = nvgCreateGL3(NVGcreateFlags.NVG_STENCIL_STROKES | NVGcreateFlags.NVG_DEBUG);

// You can now draw something
while(gameAlive)
{
    ///...

    nvgBeginFrame(nvg, ...);
    {
        drawWindow(nvg, ...);
    }
    nvgEndFrame(nvg);

    ///..
}
Authors:
Mikko Mononen, Robert Georges
Dependencies:
derelict-util
Versions:
1.0.0 2016-Nov-26
Show all 1 versions
Download Stats:
  • 0 downloads today

  • 0 downloads this week

  • 1 downloads this month

  • 17 downloads total