Wednesday, May 26, 2010

What to do with r0-r75 files you get from torrent ?

This is interesting, but once I downloaded Vampire Diaries episode from torrent and all I could get was these r0 files. I didn't know at that point what to do with and the uploader must be joking by uploading these junk files.

But few days back when I needed to install 3ds max on windows 7 machine. I downloaded it from torrent and I got r0 files. Then I searched it on net and found following solution, it is fairly simple !

You need a program called Winrar ( http://www.rarlab.com/download.htm ) or 7-Zip ( http://www.7-zip.org/download.html ) it is free.
After downloading and installing either of them, go to your downloaded r0 folder, right click the first one(r0 file) and select "Extract here".

Checklist before we begin

OpenGL:

OpenGL software is included as part of operating system. If you think your copy is somehow missing then you can download them from Microsoft .
OpenGL libraries and header files are
• opengl32.lib
• glu32.lib
• gl.h
• glu.h

GLUT:
In my previous post, I discussed how to install GLUT.

Use OpenGL and GLUT in your code:

You will need to include following files in your code
  • gl.h
  • glu.h
  • glut.h
Project settings for Visual Studio 2010:
In your Project Property Page, you need to go to
Linker>Input>Additional Directories

make sure following are present there:opengl32.lib, glut32.lib, glu32.lib.

In your Source Code:
Use the include file in your source code.

Tuesday, May 25, 2010

Installation of GLUT and Visual Studio 2010 settings

First thing which you need to do is install the GLUT library.

You can download it from here
http://www.xmission.com/~nate/glut/glut-3.7.6-bin.zip

In Future, there will be new version of the GLUT library, then you should be able to download the new ones from here.

Once you unzip it, you will get following files. Picture is attached below;







Now you need to copy some of these files to a different location as following:

I am using Visual Studio 2010 and Windows 7 for the development.

glut32.dll to C:\Windows\system
glut32.lib to C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\lib
glut.h to C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\include\GL

Note: there was no GL folder there, I had to create one.

Now Link your Project with opengl32.lib, glut32.lib, glu32.lib by doing following steps

Go To Project Property Page > Linker >Input >Additional

Picture Attached to give you a more fair idea.