Let's make the challenge: buttons and display box with pure OpenGL 3+
How to make a calculator
What why. I just need to know how to render multiple buttons with any shapes and a display box. I know the rest how to remove top. And rest just need to know this.
If you know how to draw a texture with OpenGL then you can draw buttons and a text. This tutorial shows how to draw a text with FreeType library: https://learnopengl.com/In-Practice/Text-Rendering You can download the example from the tutorial from GitHub: https://github.com/JoeyDeVries/LearnOpenGL/tree/master/src/7.in_practice/2.text_rendering
I compiled the example with MinGW 32bit (in Qt Creator) and it works:
@8Observer8 Why would I need this when I have imgui. Why are you adding additional things that have nothing to do with the problem. I just need a display box and multiple buttons with any shape(2 things).
@Shaanveer I know this is a bit of topic, but can you make icons instead of buttons that work like buttons. Because I was thinking I could use buttons and icons?
@Shaanveer But back on. All I need is a Buttons, Buttons, Buttons, Display box.
why use openGL? openGL doesn't seem really suited to making a calculator. I can see any use for the functionality that openGL provides such as shaders. I could be mistaken here and not understand what you are trying to do. I
and while imGUI is nice for games and the such, if targeting android and iPhone, aren't there other libraries/frameworks better suited for those platforms?
@undefined Then can you tell me the framework gui library that allows this. I don't want to change opengl but if I have to for better results I will. But I am fine to change gui library. Is it commen or any one no one knows. Try telling me a common on.