I read through the glui documentation and tried it out. It was a great library, but it is not excactly what i need. The glui was made for ease of use. I need to make glui windows for the controlls and i can’t place the buttons where i want.
I need something that allows me to create buttons in my main glut window, at a certain xy position of my choice. I also would like to be able to set the width and height.
Does anyone know of a way to do this (another library etc?).
Hmmmm the only one that comes to mind is MUI but its even older than GLUI, mostly undocumented and wwaaayyy outdated.
I think your options are:
a.) Modify the GLUT/GLUI sources so they do what you want.
b.) Do the buttons yourself.
In pseudocode it could look like this:
Render()
{
clear()
draw3dstuff()
glOrtho()
disableZbuffer()
drawCursor()
for all active buttons
{
drawbutton()
}
}
OnMouseClick(int x, int y)
{
for all active buttons
if point(x,y) is inside button
DoSomeButtonAction()
}