Problems with interrogating wglStateGraphicsGuardian

I managed to get everything to compile by using a lot of #ifndef CPPPARSER. And then at the end I discovered that base.win.getGsg() was only giving me a base gsg not a wglGsg. So I can’t test my wglGsg extension without doing a lot more hacking. But I will assume that because everything compiled, what I did was correct :slight_smile:

Thanks David!

There two things that I’m still confused about,

  1. I don’t see an explicit definition to dtool/src/parser-inc/windows.h in Makepanda.py; A) Is interrogate always looking in this directory B) How does it know to look in the shadowed windows.h for things like HDC? Is it because wglGsg included <windows.h>? Or all of the shadowed .h files mashed to together to form a giant ghost list? C) In case of name clashes between several external libraries, how does interrogate discriminate between what to use? I guess in some sense it doesn’t matter if you’re just ghosting things, but then why not toss all of these typedefs into one giant file? Just purely organizational/logistical reasons?

2)To make the extension, I have to make an intermediate libwgl.in using

TargetAdd('libwgl.in', opts=OPTS, input=IGATEFILES)
  TargetAdd('libwgl.in', opts=['IMOD:pandagl', 'ILIB:libwgl', 'SRCDIR:panda/src/wgldisplay']) 

I’m not quite sure what IMOD:NAME and ILIB:NAME stands for exactly. I’m guess that IMOD:NAME always refers to the super dll libNAME.dll and ILIB:OTHER is referring to a temporary used to accumuluate submodules?

So several source files->ILIB
several ILIBS form a IMOD?