I’m very new to Open GL, and I’m using an already existing Polygon-Drawing program (it draws a filled-in rectangle given hard-coded coordinates) and trying to modify it so that it will take user input-- the number of sides and the diameter, and then it is supposed to draw the polygon.
My question is, can OpenGL take user input from the command line using printf and scanf? The only place I can put this code is in the main method, but there seems to be no way to pass the parameters to the display method where the polygon will be drawn.
I also tried keyboard input, using processSpecialKeys, and processNormalKeys mnethods, but I’m not sure if that works with getting user info from the command line, and if not, how do I ask for what I want from the user? using those keyboard methods?
Thank you very much in advance for any information you can give.