[DGD] DGD Kernel function prototypes

Jared Maddox absinthdraco at gmail.com
Tue May 3 03:06:15 CEST 2011


I'm writing a kernel extension to allow DGD to create SDL windows.
I've gotten much of the work for the display and window functions
complete (which is more of a starting point than anything), but I
don't know the format for the kernel function's prototypes, so I can't
complete this initial work. I grabbed this out of extra.c (and renamed
it):
char pt_gui[] =
{
	C_TYPECHECKED | C_STATIC, /* Function traits. */
	2,
	1,
	0,
	9,
	T_MIXED,
	T_STRING,
	T_STRING,
	T_STRING
};
But I don't really know how to interpret it. Is the T_MIXED the return
type? Is the return type the next-to-last T_STRING (I'm mostly certain
that the very last isn't the return type)? What are the numeric values
about? In short, how do I figure out the meaning of the fields in the
prototype description so that I can specify them correctly?

Additionally, is there any reason why DGD's main function would need
to be in the main thread? Some OS's (Apple, mostly) require all Gui
operations to occur in the main thread, so I'm going to have a
compiler flag that shifts the main DGD function into another thread,
but I need to know whether this is likely to cause problems (I don't
think so, but just in case...).



More information about the DGD mailing list