Phil 1.18.12

8:30 – 4:30 FP

    • Asked Dong to look at setting up the first pass of the chart applet using the potatoland.org/gl code as a possible foundation, since it seems to be the best example of working text overlays.
    • Getting openGL running in FLTK, then porting the hand
    • Got the CubeView program compiling and linking. To do this, I pointed the “additional include directories” to point to C:/FLTK/branch1.3, which has FL/ underneath it. Then I pointed the “additional libraries directories” to C:/FLTK/branch1.3/lib. The last thing I had to do was point at the proper libraries (note that these are debug directories):
      • glu32.lib
      • fltkgl.lib
      • fltkd.lib
      • wsock32.lib
      • comctl32.lib
      • opengl32.lib
    • Once I got the system running, there were piles of “PDB” warning messages (i.e. “‘C:WindowsSysWOW64ntdll.dll’, Cannot find or open the PDB file “). You can fix these by getting the debug symbol tables from microsoft:
      •  tools->options…
        • Choose Debugging->Symbols from the list, then check “Microsoft Symbol Servers” then click OK and rebuild. Here’s a screenshot
    • Having an odd problem with setting the background color. I need to set the glClearColor() in the predraw, before every frame, otherwise it comes up as black. Not sure why.
      • Turns out that in FLTK GL windows, the graphics context is reset after things like a resize. THis means that the init code can’t be in the constructor, but rather needs to be in the draw function in the following way:
	drawUniverse(){
		if(!valid()){
			glEnv->init(w(), h()); 	// called when the context
						// has been (re)created
		}
		glEnv->predraw(w(), h());
		draw();
	}