# hxRender Libraries Fail to Link

This topic is 4740 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

## Recommended Posts

In my project, whenever I try to use hx blit functions (hxuBlitSimple, hxBlitSurface), I get the following error: hxRender.lib(hxrender.obj) : fatal error LNK1103: debugging information corrupt; recompile module -or- hxUtility.lib(hxutility.obj) : fatal error LNK1103: debugging information corrupt; recompile module I'm using Microsoft Visual C++ 6.0 Professional Edition and the Win32 port of hxRender, if that helps any.

##### Share on other sites
You need to either rebuild the libraries your self, or upgrade to visual studio.net

A quick fix for now is just to copy all the files from the source directory and copy them to your build directory and add them all to your project, you will have to change some of the paths of the headerfiles though.

##### Share on other sites
Thanks! I included the files to build and now there are no errors. Unfortunately, I can't seem to blit without freezing up my application. I'll look into it and see what I can do, for now.

EDIT: Well, now it doesn't crash the app, but it doesn't want to blit. Hmmm...

[Edited by - NeoMaster on May 31, 2005 2:23:43 PM]

##### Share on other sites
post some code, and I will see what I can do.

##### Share on other sites
I'm simply trying to draw an 800 x 600 square of white (from a .png with SDL) at (0,0). Ok, here we go:

int main(int argc, char *argv[]){	bool initfull = 0;  //Start fullscreen?	FILE *dataread;  //Reads in certain options	dataread = fopen("Data\\data.ini", "r");	if(!feof(dataread))		fscanf(dataread, "%d", &initfull);		if ( SDL_Init(SDL_INIT_AUDIO|SDL_INIT_VIDEO) < 0 )  //Initialize SDL here	{		printf("Unable to init SDL: %s\n", SDL_GetError());  //Error?		exit(1);	}	atexit(SDL_Quit);  //Tells to quit SDL on exit.	TTF_Init();	atexit(TTF_Quit);  //Teklls to quit SDL_ttf on exit.	InitIcon();  //Initialize the icon so it sets correctly	SDL_WM_SetCaption("SonicNext","icon");  //Set window caption and icon	SDL_WM_SetIcon(icon,NULL);  //Make sure the icon shows	screen=SDL_SetVideoMode(800,600,32,SDL_SWSURFACE|SDL_HWACCEL|SDL_RLEACCEL|SDL_ASYNCBLIT);  	if ( screen == NULL )	{		printf("Unable to set 800x600 video: %s\n", SDL_GetError());  //Is there an error?		exit(1);	}	if(initfull == 1)	{		o1choice = 1;		ToggleFullscreen();  //Go fullscreen!	}	fclose(dataread);	hxSetupWindow(800, 600);	camera.x=0;	camera.y=0;	camera.w=800;	camera.h=600;	hxSetCameraView(camera);	screenfmt = screen->format;  //Set the common pixel format	InitImages();  //Initialize the images	DrawIMG(white,0,0);		return 0;}void DrawIMG(SDL_Surface *img, int x, int y)  //First draw function.  Takes 3 parameters{	int q = 0, w = 0, e=0;	hxSurface *image;	hxRect dest;	hxRect dest2;	image = hxsCopySDL(img);	dest.x = 0;	dest.y = 0;	dest.w = image->w;	dest.h = image->h;	dest2.x = x;	dest2.y = y;	dest2.w = image->w;	dest2.h = image->h;	q = SDL_GetTicks();	while(e < 5000)	{		w = SDL_GetTicks();		e = w-q;		hxBlitSurface(image, dest, dest2);	}}

##### Share on other sites
biggest thing, you will never see the image because you never call hxsUpdateWindow.

second of all, where is your event loop! no offense, but between that and the timing function being called internaly from your image blitting routine, your code makes me cringe.

no offense, i'm sure you are new at all this, with much to learn. But I hope this helped.

##### Share on other sites
Well, I looked through the documentation a few times for an update screen surface/window and even though it was right there, I missed it! I tried that (hxsUpdateWindow), but I'm still getting a black screen and that's all. I'm going to start a new workspace to try different things that won't be screwed up by other dependencies on specific SDL stuff in my project.

Oh, and about the code, no worries. In the WORKING SDL version of my project, I have an event loop and timing is handled there. I just isolated my blit function and internalized all of the timing to get it working with hxRender first in the code sample above. I only have about a year of C/CPP under my belt, but I know the basics pretty well. [smile]

##### Share on other sites
mavdisk.mnsu.edu/longaj/rotdemo.zip

try this. It may be from an older version of hxRender, but you should be able to get it going.

##### Share on other sites
Houston, we have blitting. Over. Thanks so much for the help. I set up a new workspace and started from scratch. I'll be porting my project over to the new workspace. I'll finally be able to blit at a good framerate on older computers [smile].

##### Share on other sites
um... older computers? like how old? FYI, I can barely get it to run at all on my voodoo3. The textures have to be less than 256x256, otherwise they will just be white blocks.

• 9
• 9
• 13
• 41
• 15