Fatal Error LNK 1104: Cannont Open File 'glut32.lib'

  • Permalink
  • submit to reddit
  • Email
  • Follow


Hi all,
I have Visual C++.NET 2003 in my Windows XP Pro PC. I executed the attached 
OpenGL program "POINTSZ" and I got a fatal error  LNK 1104: Cannont Open 
File 'glut32.lib'.  Please help and advise me
 how to solve this problem.
Thanks in advance,
Scott Chang
//////---POINTSZ.C---//////
// Pointsz.c

// OpenGL SuperBible, Chapter 4

// Demonstrates OpenGL Primative GL_POINTS with point size

// Program by Richard S. Wright Jr.

#include "../../Common/OpenGLSB.h" // System and OpenGL Stuff

#include <math.h>



// Define a constant for the value of PI

#define GL_PI 3.1415f

// Rotation amounts

static GLfloat xRot = 0.0f;

static GLfloat yRot = 0.0f;



// Called to draw scene

void RenderScene(void)

{

GLfloat x,y,z,angle; // Storeage for coordinates and angles

GLfloat sizes[2]; // Store supported point size range

GLfloat step; // Store supported point size increments

GLfloat curSize; // Store current size

// Clear the window with current clearing color

glClear(GL_COLOR_BUFFER_BIT);

// Save matrix state and do the rotation

glPushMatrix();

glRotatef(xRot, 1.0f, 0.0f, 0.0f);

glRotatef(yRot, 0.0f, 1.0f, 0.0f);

// Get supported point size range and step size

glGetFloatv(GL_POINT_SIZE_RANGE,sizes);

glGetFloatv(GL_POINT_SIZE_GRANULARITY,&step);


// Set the initial point size

curSize = sizes[0];

// Set beginning z coordinate

z = -50.0f;

// Loop around in a circle three times

for(angle = 0.0f; angle <= (2.0f*3.1415f)*3.0f; angle += 0.1f)

{

// Calculate x and y values on the circle

x = 50.0f*sin(angle);

y = 50.0f*cos(angle);


// Specify the point size before the primative is specified

glPointSize(curSize);

// Draw the point

glBegin(GL_POINTS);

glVertex3f(x, y, z);

glEnd();

// Bump up the z value and the point size

z += 0.5f;

curSize += step;

}

// Restore matrix state

glPopMatrix();

// Flush drawing commands

glutSwapBuffers();

}

// This function does any needed initialization on the rendering

// context.

void SetupRC()

{

// Black background

glClearColor(0.0f, 0.0f, 0.0f, 1.0f );

// Set drawing color to green

glColor3f(0.0f, 1.0f, 0.0f);

}

void SpecialKeys(int key, int x, int y)

{

if(key == GLUT_KEY_UP)

xRot-= 5.0f;

if(key == GLUT_KEY_DOWN)

xRot += 5.0f;

if(key == GLUT_KEY_LEFT)

yRot -= 5.0f;

if(key == GLUT_KEY_RIGHT)

yRot += 5.0f;

if(key > 356.0f)

xRot = 0.0f;

if(key < -1.0f)

xRot = 355.0f;

if(key > 356.0f)

yRot = 0.0f;

if(key < -1.0f)

yRot = 355.0f;

// Refresh the Window

glutPostRedisplay();

}



void ChangeSize(int w, int h)

{

GLfloat nRange = 100.0f;

// Prevent a divide by zero

if(h == 0)

h = 1;

// Set Viewport to window dimensions

glViewport(0, 0, w, h);

// Reset projection matrix stack

glMatrixMode(GL_PROJECTION);

glLoadIdentity();

// Establish clipping volume (left, right, bottom, top, near, far)

if (w <= h)

glOrtho (-nRange, nRange, -nRange*h/w, nRange*h/w, -nRange, nRange);

else

glOrtho (-nRange*w/h, nRange*w/h, -nRange, nRange, -nRange, nRange);

// Reset Model view matrix stack

glMatrixMode(GL_MODELVIEW);

glLoadIdentity();

}

int main(int argc, char* argv[])

{

glutInit(&argc, argv);

glutInitDisplayMode(GLUT_DOUBLE | GLUT_RGB | GLUT_DEPTH);

glutCreateWindow("Points Size Example");

glutReshapeFunc(ChangeSize);

glutSpecialFunc(SpecialKeys);

glutDisplayFunc(RenderScene);

SetupRC();

glutMainLoop();

return 0;

}

 


0
Reply Scott 8/19/2005 7:25:39 PM

See related articles to this posting


Scott Chang wrote:

> Hi all,
> I have Visual C++.NET 2003 in my Windows XP Pro PC. I executed the attached 
> OpenGL program "POINTSZ" and I got a fatal error  LNK 1104: Cannont Open 
> File 'glut32.lib'.  Please help and advise me
>  how to solve this problem.
> Thanks in advance,
> Scott Chang
<snip long code sample that does not help at all!>

Boy, there are a lot of new OpenGL programmers lately. This is GOOD, but it is a 
slight pain...

Anyway, to the problem: This is a compiler problem, and it is telling you 
EXACTLY what the problem is: it cannot find the glut32.lib library. Did you 
download and install it? If you did install it, then you need to tell your 
compiler WHERE it can find it. To make things simple, I copied the GLUT headers 
and library directly to my MSVC include and library folders, and the glut32.dll 
file to my Windows system32 folder.

-- 
Phil Frisbie, Jr.
Hawk Software
http://www.hawksoft.com
0
Reply Phil 8/19/2005 9:38:54 PM

Scott Chang wrote:
> Hi all,
> I have Visual C++.NET 2003 in my Windows XP Pro PC. I executed the attached 
> OpenGL program "POINTSZ" and I got a fatal error  LNK 1104: Cannont Open 
> File 'glut32.lib'.  Please help and advise me
>  

You might need to install GLUT (it isn't really part
of OpenGL).

http://www.opengl.org/resources/libraries/glut.html


-- 
<\___/>
/ O O \
\_____/  FTB.    For email, remove my socks.

In science it often happens that scientists say, 'You know
that's a really good argument; my position is mistaken,'
and then they actually change their minds and you never
hear that old view from them again.  They really do it.
It doesn't happen as often as it should, because scientists
are human and change is sometimes painful.  But it happens
every day.  I cannot recall the last time something like
that happened in politics or religion.

- Carl Sagan, 1987 CSICOP keynote address

0
Reply fungus 8/20/2005 11:19:55 AM
comp.graphics.api.opengl 7097 articles. 24 followers. Post

2 Replies
4843 Views

Similar Articles

[PageSpeed] 41


  • Permalink
  • submit to reddit
  • Email
  • Follow


Reply:

Similar Artilces:

Fatal Error LNK 1104: Cannont Open File 'glut32.lib'
Hi all, I have Visual C++.NET 2003 in my Windows XP Pro PC. I executed the attached OpenGL program "POINTSZ" and I got a fatal error LNK 1104: Cannont Open File 'glut32.lib'. Please help and advise me how to solve this problem. Thanks in advance, Scott Chang //////---POINTSZ.C---////// // Pointsz.c // OpenGL SuperBible, Chapter 4 // Demonstrates OpenGL Primative GL_POINTS with point size // Program by Richard S. Wright Jr. #include "../../Common/OpenGLSB.h" // System and OpenGL Stuff #include <math.h> // Define a constant for the value of PI #def...

Fatal error LNK1104: cannot open file "nafxcwd.lib"
Hi all, I'm a C newbie in a desperate need of help. My background isn't programming but engineering, so my programming skills are somewhat limited (I am able to write simple single-threaded progs in C, but hardly more than that). It just happened that my work requires me to take a program and strip it off all kind of GUI, make it just a simple command prompt thingie. And so I did, more or the less. Now, I didn't remove any includes or anything of a kind, but my stripped proggie consistently refuses to link (compiling is OK) and the error I get ts the one in the subject. I searched...

LINK : fatal error LNK1104: cannot open file "dfor.lib"
Greetings, I have a mixed language project which I am trying to build using NMAKE. I opened the MS Visual Studio 6.0 workspace and exported the make file. I am using Compaq Digital Fortran ver 6.6 and the OS is Windows 2000 Professional. Whenever I build the project using Visual Studio everything links with no problem, however when I try to use NMake with the exported make file I get the following error. LINK : fatal error LNK1104: cannot open file "dfor.lib" NMAKE : fatal error U1077: 'link.exe' : return code '0x450' Does anyone know how to fix this? All help ...

LINK : fatal error LNK1104: cannot open file 'wxmsw28ud_stc.lib'
Hi, I'm newbie wxWidgets on windows. How to solving this problem, I try building pgAdmin3 source from MSVC 2008 IDE. And got the error message: LINK : fatal error LNK1104: cannot open file 'wxmsw28ud_stc.lib'. The file wxmsw28ud_stc is not in the my source directory. I hope someone can help me many thanks before Hidayat __________________________________________________ Apakah Anda Yahoo!? Lelah menerima spam? Surat Yahoo! memiliki perlindungan terbaik terhadap spam http://id.mail.yahoo.com dayat wrote: > Hi, I'm newbie wxWidgets on windows. How ...

LINK : fatal error LNK1104: cannot open file 'z.lib'
I use cmake to create makefiles for a C++ project. One of the target links is just called 'z': TARGET_LINK_LIBRARIES(z ... When I try to compile the code I get: LINK : fatal error LNK1104: cannot open file 'z.lib' I have tried to download zlib for windows and point to the zlib .lib files from VS 2008 but that is not what it want. What is 'z'? mlt wrote: > I use cmake to create makefiles for a C++ project. If you have a problem with cmake, why not ask the cmake folks? There's a mailing list, from what I gather at http://www.cmake.org/ma...

[ace-bugs] fatal error LNK1181: cannot open input file 'Test_Output.lib'
--001a11c37b3c6e64fa04da44c5e6 Content-Type: text/plain; charset=ISO-8859-1 ACE VERSION: 6.1.8 OPERATING SYSTEM: Windows 7 COMPILER NAME: Visual Studio 2012 AREA/CLASS/EXAMPLE AFFECTED: DOES THE PROBLEM AFFECT: The problem affects linking. SYNOPSIS: Half will compile, and the other half will fail because of a link error: "fatal error LNK1181: cannot open input file 'Test_Output.lib'" DESCRIPTION: REPEAT BY: 1. download the latest version of ACE 2. create the config.h fi...

sendmail works from the command line, from the GUI, but not from web link. error: ld.so.1: /usr/lib/sendmail: fatal: libgcc_s.so.1: open failed: No such file or directory
I just installed sendmail 8.12.10 on a Solaris 7 (sparc) system. It works fine from the command line and from the GUI-based (dt) email, but won't run from our web server (linked via Perl Script). I keep getting the following error message: ld.so.1: /usr/lib/sendmail: fatal: libgcc_s.so.1: open failed: No such file or directory I checked, and the libgcc_s.so.1 library IS on the LD_LIBRARY_PATH, and sendmail is on the PATH. Do you have any idea why it wouldn't work form a web link? The Perl link is from a web form (which worked fine until 8.12.10 was installed). The call to sendma...

fatal error C1083: Cannot open include file: 'simstruc.h': No such file or directory
Hi I am new to Matlab and I am trying to mex .c files for the ADM1 model. I have the 64bit program and installed the Visio compiler. I did the mex -setup successfully but when I try to mex the .c files I get the following error message: >> mex adm1_DAE1.c adm1_DAE1.c adm1_DAE1.c(19) : fatal error C1083: Cannot open include file: 'simstruc.h': No such file or directory C:\PROGRA~1\MATLAB\R2010B\BIN\MEX.PL: Error: Compile of 'adm1_DAE1.c' failed. ??? Error using ==> mex at 208 Unable to complete successfully. Anyone have any ideas what the pro...

Fatal error C1083: Cannot open include file 'afxsock.h': No such file or directory
Hi there, I am porting my windows project from my desktop and my laptop. At my desktop, I can compile and run my project/application without any problem, while at my laptop, I got the following compilation error: Fatal error C1083: Cannot open include file 'afxsock.h': No such file or directory Visual C++ 2008 Express Edition is used for both cases. The two computers have virtually the same settings: My desktop runs Windows Vista Home Premium (2007), SP2 My laptop runs Windows Vista Ultimate (2007), SP2 Any idea for the fatal error? Thank you! --- news://fr...

: fatal error C1083: Cannot open include file: 'simstruc.h': No such file or directory
Dear All I am trying to import AMESim model in Simulink as S Function. But doing so, I am getting the following error: AMEcompile110.bat does a 64 bit setup Setting environment for using Microsoft Visual Studio 2008 Beta2 x64 tools. Setting environment for using Microsoft Visual Studio 2008 Beta2 x64 tools. Microsoft (R) Program Maintenance Utility Version 9.00.21022.08 Copyright (C) Microsoft Corporation. All rights reserved. cl.exe -c -DWIN32 -DAMESIMULINK -I"C:\Programs\MATLAB/extern/include" -I"C:\Programs\MATLAB/simulink/include" -I"C:\AMESim\v1110...

fatal error C1083: Cannot open include file: 'windows.h': No such file or directory
Why is building via command line in VC++ 2005 is so difficult? My project builds fine from within the IDE. However, when I attempt to build it from the command line: vcbuild myproj.sln "Debug|Win32" I get the following error: fatal error C1083: Cannot open include file: 'windows.h': No such file or directory Now... I know about the INCLUDE env var, installing the PSDK etc. In fact, I verified that windows.h is alive and kicking in: C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include And checked the env var: C:\Program Files...

fatal error C1083: Cannot open include file: 'hidsdi.h': No such file or directory
I have copied somebodies code into my program, edited it and such so that I can try and read any device connected to the computer via usb, find if it has a generic or advanced driver and then load the driver for the input device. All in all its so that a usb device such as a joystick or 'other' can control an external piece of hardware. I'm getting the above error. I have tried an awful lot of things to resolve it. Please throw me suggestions, so that I can try them all out! Thanks! Code: #include <hidsdi.h> Solution one: Added the DDK folder to Project Prope...

fatal error C1083: Cannot open include file: 'ace/config-all.h': No such file or directory
ACE VERSION: 5.4.8 - HOST MACHINE and OPERATING SYSTEM: Windows XP Pro. Unknown version of winsock. - TARGET MACHINE and OPERATING SYSTEM, Windows XP Pro. - COMPILER NAME AND VERSION (AND PATCHLEVEL): MSVC++ 7.1. CONTENTS OF $ACE_ROOT/ace/config.h: $ACE_ROOT/ace/config.h has been created and it has the include file of conifg-win32.h. AREA/CLASS/EXAMPLE AFFECTED: The file "config-all.h" doesn't compile. The line #include "ace/config.h" Generates the error message: .../ace/config-al...

Error Installing 'termios' [ld: fatal: file crt1.o: open failed: No such file or directory]
I would greately appreciate any insite that can be provided: gem install termios Attempting local installation of 'termios' Local gem file not found: termios*.gem Attempting remote installation of 'termios' Building native extensions. This could take a while... /apps/ruby/lib/ruby/site_ruby/1.8/rubygems/installer.rb:290: warning: Insecure world writable dir /apps/ruby, mode 040777 /apps/ruby/lib/ruby/site_ruby/1.8/rubygems/installer.rb:301: warning: Insecure world writable dir /apps/ruby, mode 040777 ld: fatal: file crt1.o: open failed: No such file or directory collect2: ld...

[ace-users] Re: fatal error C1083: Cannot open include file: 'ace/config-all.h': No such file or directory
Hi, Make sure you set ACE_ROOT to the location of ACE (for example c:\ace\ace_wrappers) and then restart the IDE, the IDE caches all environment variables after being started. Regards, Johnny Willemsen Remedy IT Postbus 101 2650 AC Berkel en Rodenrijs The Netherlands www.theaceorb.nl / www.remedy.nl "Samer S. Issa" <issa.samer@gmail.com> wrote in message news:<1138270579.069801.255530@z14g2000cwz.googlegroups.com>... > ACE VERSION: 5.4.8 > > - HOST MACHINE and OPERATING SYSTEM: > Windows XP Pro. Unknown version of winsock....

Fatal error when opening an image file
Hi all! I'm running IDL 7.1 on Linux (KDE version: 3.5.4-25.el5_4.1 Red Hat) and I = cannot even open a single *.jpg file. When I try to open a single image fil= e I'm getting an error: "Fatal error: IDL has encountered a fatal error and= will now exit.". I have no idea what to do. Please be tolerant because I'm= new to Linux and IDL so it's quite challenging for me.=20 Thanks for your help in advance. PS. I've already found this topic https://groups.google.com/d/topic/comp.la= ng.idl-pvwave/eWjc0OUoVvw/discussion. Creating new workspace didn't help. I= do...

Fatal error: main(): Failed opening required 'DB.php' (include_path='.:/usr/lib/php:/usr/local/lib/php')
I installed PEAR HTTP_Upload to my new server and now im getting this error when runnign the script. any help? Maximus wrote: > I installed PEAR HTTP_Upload to my new server > and now im getting this error when runnign the script. > > > any help? > permissions problem? where is DB.php located? does DB.php reside in the include_path directories? The message is self explanatory. -- Michael Austin. DBA Consultant Donations welcomed. Http://www.firstdbasource.com/donations.html :) Try on your command line as root: >pear install DB Alex http://prepared-stateme...

c:\wx\include\wx\platform.h(85): fatal error C1083: Cannot open include file: 'wx/setup.h': No such file or directory
Hi, I can compile the SAMPLES find after my VC .NET converts the .DSW over. I'm going to compile a hello world at http://wiki.wxwidgets.org/wiki.pl?Hello_World It worked the first time. I screwed up the project settings and now I get this error? c:\wx\include\wx\platform.h(85): fatal error C1083: Cannot open include file: 'wx/setup.h': No such file or directory Any good links for me better understand all those project settings? -Thanks! John Doe schrieb: > Hi, > > I can compile the SAMPLES find after my VC .NET converts the .DSW over. > I&...

Fatal Error[Pe005]: could not open source file
I am testing MAXQ7667 eval kit with IAR MAX evaluation software. it is showing *** Fatal Error[Pe005]: could not open source file "iomacro.h" *** when i build the program. please help me to solve this problem. Thanks Vamsi --------------------------------------- Posted through http://www.EmbeddedRelated.com ...

fatal error message at opening m file
Hi, when I open the first file in a Matlab session /Matlab R2008a (7.6.0.324) /, I get the message: [Fatal Error] :-1:-1: Premature end of file. However, the file is loaded and executed normally, and the whole Matlab works properly, with the exception of giving the above message. Subsequently loaded files do not cause any error message. Does anybody know what the cause of the error message is and how it can be eradicated? Thanks, vladimir "Vladimir Stanojevic" <NOSPAM.v.stanojevic@imperial.ac.uk> wrote in message news:hge3ko$1s9$1@fred.mathworks.com... &g...

LINK : fatal error LNK1104: cannot open file
Matlab 2010b crashed on me when I was trying to compile a mex file using Visual C++ 2010 Express edition. Now when I try to compile I get the above error unless I move the code to a local directory from a network location on my machine which has no spaces in the path (I used C:\temp). Searching on the web all I came up with was this: http://www.mathworks.com/support/solutions/en/data/1-9DJ5R3/index.html?product=ML&solution=1-9DJ5R3 I work in a large institution and I don't think our computer support people want me to mess around with the TEMP and TMP enviromental variables (althoug...

LINK : fatal error LNK1104: cannot open file
I am trying to create a dll file using the following command: cl -IC:\j2sdk1.4.2_05\include -IC:\j2sdk1.4.2_05\include\win32 -LD helloworldimp.c -Fehello.dll Everytime I run cl from the command line I get this error from the linker. C:/Perl/lib,C:/Perl/site/lib,. LINK : fatal error LNK1104: cannot open file "C:/Perl/lib,C:/Perl/site/lib,." I have no idea why it is looking for these PERL directories. I have checked all of my ENV variables and they all look correct. Any thoughts on how I can get the linker to quit trying to load these files? Thanks, Abby ...

When the interpreter hits a fatal error, what happens to open file handles
Hi, I've always assumed, but would like to make sure, that when the interpreter hits a fatal error, such as a command doesn't get enough arguments, any open file handles are flushed and closed. However, this has always been an assumption on my part. Is this true, or would any data still left in a buffer be lost? Andy Andrew Falanga wrote: > I've always assumed, but would like to make sure, that when the > interpreter hits a fatal error, such as a command doesn't get enough > arguments, any open file handles are flushed and closed. However, > this has always b...

[ace-users] Re: fatal error C1083: Cannot open include file:
Hi Samer, Thanks very much for your email. Please make sure to send all questions related to TAO or ACE to the ACE mailing list or ACE+TAO newsgroup, rather than to me directly since I travel frequently and often don't have ready access to email. > Well this is how I'm learning, and this how > Istarted my small application. But Idon't understand why it is > giving me this error, it is a little bit wierd to me. I have all the > environment varaible right. If the ACE+TAO examples are working fine for you, but your application projec...

fatal error C1083: Cannot open include file: 'complex.h'
Hi, I'm trying to compile C code in matlab 7.7.0 R2008b on a Vista 64 bit system using Visual Studio C++ 2008 Express edition. And I'm getting the error: C:\PROGRA~1\MATLAB\R2008B\TOOLBOX\PACKAG~1\EMDS\SRC\cemdc.c(19) : fatal error C1083: Cannot open include file: 'complex.h': No such file or directory If I go looking for this file in my Visual Studio include folder I can not find it. I only see a file named complex. I have already tried to rename it too complex.h, but than I get a bunch of cmath errors like the ones below: C:\Program Files (x86)\Microsoft Visual Studio 9....