GLBasic forum

Main forum => GLBasic - en => Topic started by: r0ber7 on 2013-Sep-26

Title: INLINE C++ for direct control over OpenGL shaders
Post by: r0ber7 on 2013-Sep-26
Hi,

I was thinking: could you use INLINE C++ to control the OpenGL shaders?
I found some code:

http://r3dux.org/2013/08/a-simple-c-opengl-shader-loader/

Could that be of any use? I'm not very good in C++ (yet).
Title: Re: INLINE C++ for direct control over OpenGL shaders
Post by: MrTAToad on 2013-Sep-26
There should be some INLINE OpenGL stuff around the forums, which may or may not already have the shader functions in - if not, then it should be easy to add your code to it.
Title: Re: INLINE C++ for direct control over OpenGL shaders
Post by: r0ber7 on 2013-Sep-26
Hmm, thank you. I seem to remember that the X_ commands are 3D only. Will this no-brainer solution work in 2D as well? :)
Title: Re: INLINE C++ for direct control over OpenGL shaders
Post by: kanonet on 2013-Sep-26
Im pretty sure X_SHADER... commands work with 2D too, but cant test right now. If not or if you need more advanced shader stuff, send me a PN, i have done some work in last weeks.