RES files
Recently, I installed it again, and wondered what else can I dive deep into. After a few soruce code and documentation readings I finally got it - I'll extract the res files!
As you may or may not know, pretty much every executable in DR5 comes with its res file (for example you get both calc.exe and calc.res). A quick look into one of the samples that have its source code included, it's not hard to see how it came to be (I use ppdemo, as it's fairly simple and not too cluttered).
Code: Select all
ppdemo.res: ppdemo.rc ppdemo.ico
rc ppdemo.rc
Code: Select all
ppdemo icon ppdemo.ico
ppdemo cursor normal.cur
ppdemo it
BEGIN
Options
StdChars
Definitions
Mouse-Button1 = 256
MouseMove = 257 MouseCoords
END
Code: Select all
/* get the resource file info: cursor, icon, it table */
if(hPPDemoRF = OpenResourceFile((LPSTR)"ppdemo.res"))
{
pPPDemoClass->hClsCursor = CursorLoad(hPPDemoRF, (LPSTR)"ppdemo");
pPPDemoClass->hClsIconId = IconLoad(hPPDemoRF,(LPSTR)"ppdemo");
pPPDemoClass->hClsItTable = ItLoad(hPPDemoRF,(LPSTR)"ppdemo");
CloseResourceFile(hPPDemoRF);
}
The hidden fruit
So was this worth anything? I believe it was, as I was able to find 2 icons and one cursor in the windows.res that I believe are unused (if you can find them used I'll give you a cookie).
More precisely they are:
bomb.ico
trash.ico
uparrow.cur
(sample.ico is also probably unused, but who cares about an empty square with black borders... click here if you're one of them)
You want more? Well, there's one other thing I didn't notice before (and you don't even have to extract the res files to see it). Check the SAMPLE.ICO (not the one in windows.res, but the one used in sample.exe, which was compiled from sample.c, but is actually iniside sample.res, which was made from sample.rc... get it?)