chrismile / sgl

Simple Graphics Library (using OpenGL and SDL)
Other
16 stars 5 forks source link

samples ? #1

Open ebachard opened 6 years ago

ebachard commented 6 years ago

Hello,

First over all, thanks a lot for sharing your great work. After I discovered your repo, I started to learn your code. Doxygen helped me to undertand a bit, but I'm still unsure how to use your API.

Do you have one example to test ? (samples directory does not exist, or I didn't search the right location maybe ?.)

Last, this issue is not really an issue, so feel free to close it if you want :-)

-- ericb

chrismile commented 6 years ago

Hi,

thanks for your praise! I started 'sgl' (back in 2015 I think) as a way to make programming apps with SDL & OpenGL easier for myself. Before that, each time I started a new project, I copied&pasted my utility code for using SDL and OpenGL to each project. Because of that redundancy, each time I found a bug in my code, I had to fix it at many places, so I finally created this library.

Furthermore, when creating graphics applications, it is far more convenient to program higher-level code, i.e. having classes for geometry buffers, framebuffer objects, textures, etc., than having to call the OpenGL API interface directly. And I was never really happy with any other existing graphics libraries (like Cinder or openFrameworks), as they hardly ever give you direct control over advanced OpenGL features (like multisampled renderbuffers, image buffers, atomic counter buffers etc.).

If you have an Nvidia GPU, you can e.g. take this project as a simple sample: https://github.com/chrismile/GPU-Tiling-Test It is one of the projects I took most care to comment thorougly. Unfortunately, it uses some features only available on Nvidia GPUs. I created it for my Bachelor‘s thesis to test how graphics cards schedule fragment shaders. Unfortunately, I never found the time to create some more sophisticated (and general) sample application so far.

There are also some issues why I can‘t 100% recommend other users to build their projects upon sgl:

However, I greatly encourage you to adapt and use classes of sgl in your projects as you see fit. I released the library under the terms of the BSD license so anyone can use the code freely (as long as you tag me in adapted code parts as the original author). If you have questions regarding the structure of the project, feel free to ask!

Best regards, Christoph