Tuesday, December 16, 2008

Semi-Functional

Ok.  After a long day in the trenches I have the OSX version almost back to running and with all of the targeted improvements in place.  There is a good bit of glue code that still needs to be put in place (for key presses and mouse movements and such), but the fundamentals seem to be working.

The basic idea behind what I did is this:
  1. Move to a Document Type manager - using abstract factories, each document type (think Part, Assembly, Visualization, etc) registers themselves and passes a factory.  Then when anyone asks the Wildcat kernel (also a new class) for a document of a particular type it can then create it.
  2. Move to a core OpenGL context - when the kernel starts it creates its own OpenGL context which can then be used to see what the capabilities of the graphics card are much more easily.  This core context is now shared with each document thus greatly reducing document creation time and graphics memory overhead.  Big improvements should come from this.
  3. Building on 1 & 2 - once I moved to this new kernel arrangement I was able to clear a lot of cruft out and clean up the platform independent side of things.  This obviously has a direct impact on the platform specific code and that is what is going to take some clean up work.  But that is for tomorrow!
Hope some of this makes sense.  These are things I have wanted to do for a while and the nearly daily emails asking if such and such a graphics card is supported finally put me over the edge and I decided to just jump in and do it.

Check back in next week and hopefully things will be back up and running fully.
Cheers,
   Graham

Monday, December 15, 2008

I Think I Broke It

I decided to make some fundamental changes to the underlying way in which the Wildcat kernel interacts with OpenGL.  On the plus side it will make things much cleaner and clearer moving forward.  On the minus side: a) there is still much work to be done to get this working on any platform, and b) while it is in a running state on the OS X side, the Win32/WX side is quite horribly broken.

While I have not tried compiling the WX project, I can save you some time.  I am oh so certain that I broke many things all over the place.  I hope to wrap up the OS X work tomorrow and start working on the WX code just after that.  The downside is that I have a trip planned from Wednesday through Monday, so if I don't resurrect things by the time I leave it will be broken through at least the weekend.  Sorry!

I will try my best to post an update tomorrow.

G

Wednesday, December 3, 2008

Intersections and Testing

As you may have noticed, I am starting to check in some code for all of the outstanding geometric intersections.  There are nine that need to be tackled:
  • Surface-Point
  • Surface-Line
  • Surface-Curve
  • Surface-Surface
  • Trimmed Surface-Point
  • Trimmed Surface-Line
  • Trimmed Surface-Curve
  • Trimmed Surface-Surface
  • Trimmed Surface-Trimmed Surface
Some of these will be more challenging, some less.  In order to try out these routines I am also adding code to the Topological Union operation.  The goal is still full Boolean capabilities, but baby steps first.

Also, I have been playing around with some unit testing frameworks.  I would really like to get to the point where there is a nice automated unit testing suite for Wildcat.  Moving forward it will be necessary to regression test etc.  After spending some time looking at all of the open source unit testing frameworks out there I decided to adopt googletest.

There are a million and one testing frameworks out there.  My criteria were: simplicity, cross-platform, C++ support, and open source.  Googletest has most of the features I want with seemingly little overhead.  I should start checking in the initial tests I have written in the next few days.  They will be appearing under the Testing directory (makes sense huh?).

Cheers,
   Graham