In my program there is a function to load a BMP as follow:
AUX_RGBImageRec LoadBMP(LPCTSTR Filename)
{
FILE *File = NULL;
if ( !Filename ) {
return NULL;
};
File = fopen( Filename,“r” );
if ( File ) {
fclose( File );
return auxDIBImageLoad( Filename );
};
return NULL;
}
The compiling message:
Compiling…
EarthSatsCtl.cpp
Linking…
Creating library Debug/EarthSats.lib and object Debug/EarthSats.exp
EarthSatsCtl.obj : error LNK2001: unresolved external symbol _auxDIBImageLoadA@4
Debug/EarthSats.ocx : fatal error LNK1120: 1 unresolved externals
Error executing link.exe.
EarthSats.ocx - 2 error(s), 0 warning(s)
I don’t know how to correct ,erger for your help.
Originally posted by jiangerlai:
[b]In my program there is a function to load a BMP as follow:
AUX_RGBImageRec LoadBMP(LPCTSTR Filename)
{
FILE *File = NULL;
if ( !Filename ) {
return NULL;
};
File = fopen( Filename,“r” );
if ( File ) {
fclose( File );
return auxDIBImageLoad( Filename );
};
return NULL;
}
The compiling message:
Compiling…
EarthSatsCtl.cpp
Linking…
Creating library Debug/EarthSats.lib and object Debug/EarthSats.exp
EarthSatsCtl.obj : error LNK2001: unresolved external symbol _auxDIBImageLoadA@4
Debug/EarthSats.ocx : fatal error LNK1120: 1 unresolved externals
Error executing link.exe.
EarthSats.ocx - 2 error(s), 0 warning(s)
I don’t know how to correct ,erger for your help.[/b]
check if you #include <gl/glaux> & <stdio.h>
I am programming in Visual c++ 6.0
#include “stdafx.h”
#include <gl/gl.h>
#include <gl/glu.h>
#include <gl/glaux.h>
#include <gl/glut.h>
I guess it is due to the file GLAUX.LIB or glaux.h. Does anyone agree with me and help me
you need to link to the glaux.lib library
#pragma comment (lib, “glaux.lib”)
should do the job, but you should find a better solution then glaux, it is a buggy library that is no longer supported