Find Jobs
Hire Freelancers

470263 Introduction to OpenGL

N/A

Suoritettu
Julkaistu yli 13 vuotta sitten

N/A

Maksettu toimituksen yhteydessä
I have attached a word document explaining all of the details. Also I am using Microsoft Visual 2005 This is what needs to be done, Modify the OpenGL application as follows: • Put your name in the title bar of the application with the following lines of code after the ShowWindow call in WinMain (in [login to view URL]) : char str[32]; sprintf(str, "%s", "your name goes here"); SetWindowText(HDialog, str); Be sure to include the header file for the sprintf function at the top of [login to view URL], if not included: #include <stdio.h> • Change the OpenGL window's background color to light blue or grey by changing the call to the glClearColor function in CGfxOpenGL.cpp. i.e. change the following line of code near the beginning of bool CGfxOpenGL::Init() : glClearColor(0.0, 0.5, 0.0, 0.0); //green background • Change the color of the sphere to red using glColor3f(1, 0, 0); just before the sphere is drawn. It is done before the sphere is made because the glColor3f command presets the color state, before drawing. Note: The sphere of radius 1 centered at the origin (0,0,0) is then drawn with the function gluSphere(quadric, 1.0f, 20, 20). It has 20 slices (similar to lines of longitude) and 20 stacks (similar to lines of latitude) when drawn. • Add a second, different colored sphere to the scene. Place this second sphere in a different location by calling glTranslatef(15, 0, 0); before drawing the sphere with gluSphere. It is done before the sphere is made because the glTranslatef command moves the drawing state, before drawing. Thus, this last part has a total of three commands: change the color using glColor3f, then translate the scene using glTranslatef, and then draw the new sphere using gluSphere. Build and run the modified project. The output should look something like this:
Projektin tunnus (ID): 2216164

Tietoa projektista

1 ehdotus
Etäprojekti
Aktiivinen 12 vuotta sitten

Haluatko ansaita rahaa?

Freelancerin tarjouskilpailun edut

Aseta budjettisi ja aikataulu
Saa maksu työstäsi
Kuvaile ehdotustasi
Rekisteröinti ja töihin tarjoaminen on ilmaista
Myönnetty käyttäjälle:
Käyttäjän avatar
I have it done already :) very easy. Please contact me!
$23 USD 0 päivässä
5,0 (11 arvostelua)
2,9
2,9

Tietoja asiakkaasta

Maan UNITED STATES lippu
Chicago, United States
4,7
26
Liittynyt tammik. 30, 2011

Asiakkaan vahvistus

Kiitos! Olemme lähettäneet sinulle sähköpostitse linkin, jolla voit lunastaa ilmaisen krediittisi.
Jotain meni pieleen lähetettäessä sähköpostiasi. Yritä uudelleen.
Rekisteröitynyttä käyttäjää Ilmoitettua työtä yhteensä
Freelancer ® is a registered Trademark of Freelancer Technology Pty Limited (ACN 142 189 759)
Copyright © 2024 Freelancer Technology Pty Limited (ACN 142 189 759)
Ladataan esikatselua
Lupa myönnetty Geolocation.
Kirjautumisistuntosi on vanhentunut ja sinut on kirjattu ulos. Kirjaudu uudelleen sisään.