Handle default case in switch
Added debugging support for GATHER4* opcodes.
Fixed sampler state setting in LD/SAMPLE opcodes when debugging non-vertex shaders.
Merge pull request #75 from valeriog-crytek/master

Added debugging support for GATHER4* opcodes.
Typo using wrong blend GLenum for source alpha
Serialise depth function as part of render state
Add IAT based hooking to allow hooking 64bit opengl32.dll

* Needs vigorous testing in as many situations as I can think of, not least
  32bit, 64bit, D3D11, D3D9, OpenGL, managed apps, different windows SDKs,
  delay loading dlls (not sure if these will work), statically linked libs,
  LoadLibrary + GetProcAddress
* Credit goes to jslutter for originally bringing it to my attention &
  suggesting it.
* References:
  http://msdn.microsoft.com/en-us/magazine/bb985992.aspx
  http://msdn.microsoft.com/en-us/magazine/cc301808.aspx
  http://www.codeproject.com/Articles/6265/Process-wide-API-spying-an-ultimate-hack
Ignore modules with a invalid DOS magic number

* Seen in the wild some HMODULEs come back pointing 2 bytes after the real
  module base address, and so without the magic number. I don't know why
  but I can't assume anything about the behaviour so I ignore these modules
  to avoid crashes.
Skip hooking fraps via IAT for compatibility reasons
Refresh module handle if NULL when hitting GetProcAddress

* This might be a more serious problem in future...
* We only hook all loaded modules once, at init time, in Win32_IAT_EndHooks
* If a LoadLibrary call afterwards implicitly loads some modules we don't
  see them. Potentially we should rehook all loaded modules again each time
  LoadLibrary is called but then there would be a lot of redundant work
  unless we tracked module unload/loads to see if a module has been hooked
  before or not. For now assume we don't need to hook these modules and
  get away with just updating module handles