• entries
201
88
• views
100360

# HAPPY NEW YEAR

69 views

First of all: HAPPY NEW YEAR TO ALL OF YOU!

Has been some time since my last journal entry and some things have happened.

1. I've ripped out a lot of #defines in my base classes of my engine which had me to alter all (!) files. Basically it was some function declaration defines. I ripped them out because I don't want to double my class declarations just to use tolua++...

2. which is the second new thing. I decided to give a shot at tolua++ because it seems to be quite easy to export anything to lua with that thing. Unfortunately the tolua compiler doesn't seem to resolve defines and includes "deeply" so that a define which lets me define a pure virtual function in an easy way will not be resolved and causes an compilation error.

Example:
#define ARMETHODCALLTYPE __stdcall#define DECLSPEC_NOVTABLE __declspec(novtable)#define ARINTERFACE struct#define DECLARE_ARINTERFACE_(iface) ARINTERFACE DECLSPEC_NOVTABLE iface#define ARMETHOD(type, m) virtual type ARMETHODCALLTYPE m = 0DECLARE_ARINTERFACE_(IBase){    ARMETHOD(ulong,		AddRef(void));    ARMETHOD(ulong,		Release(void));    ARMETHOD(IBase *,		GetInterface(STRID _id));    ARMETHOD(const STRID&,	GetSTRID() const);    ARMETHOD(bool,		IsExactly (const STRID& _id) const );    ARMETHOD(bool,		IsDerived (const STRID& _id) const );};

The above code would cause the tolua++ compiler to throw up compilation error when the code appears within a pkg file.

Well... a second effect of the elimination of those defines is that VisualAssist now displays the functions as expected in the function list. Before there were several ARMETHODIMP(bool) etc listed.

3. I started eliminating all Fixed Function Pipeline stuff from my renderkernel and adopt an all shader based system. Fortunately shaders were already supported until the latest version number for both vertex- and pixelshaders. Although, the engine doesn't really make any difference between vertex- and pixelshaders. After all, it's only shaders.

I improved the automagically parameter setting a bit. The engine is able to extract the constants, samplers etc from the shader. When setting an shader, the engine knows ie. which matrices are used (WorldView, Projection, ...) and sets them accordingly without me having to handle any shader stuff... I simply do a setTransformationMatrix call to the renderkernel.

4. I finally found the origin of my computer instabilities: It's the second gig of ram I put into my machine. memtest86+ did not show up any problem, but as soon as I ripped out the second gig, the machine went stable. Now, I have written an email to my hardware vendor to see if they would take back the "cheap" mem I have to sell me some higher quality rams. I'm not quite sure if the problem comes from the ram itself or the DIMM slots. I'm tempted to buy some corsair 1 gig dimms since they are listed within the manual as hardware compatible.

Well... that's all folks...

There are no comments to display.

## Create an account

Register a new account