Final Project - PowerPoint PPT Presentation

1 / 9
About This Presentation
Title:

Final Project

Description:

... to make a 3d ball game in which there is a room which has a bouncing ball and ... off depth buffer writing when drawing transparent objects, since we still want ... – PowerPoint PPT presentation

Number of Views:18
Avg rating:3.0/5.0
Slides: 10
Provided by: kaut
Category:
Tags: final | project

less

Transcript and Presenter's Notes

Title: Final Project


1
Final Project
  • Computer Graphics

Kautilya K Tyagi
2
3D BOUNCE GAME

Score 050 Time 59 Sec
Walls (Texture Mapping)
Bricks
Ball
Shadow
Striker
3
Introduction
  • Introduction
  • I am planning to make a 3d ball game in which
    there is a room which has a bouncing ball and a
    striker controlled by keyboard which is used
    prevent the ball from hitting the ground. The
    image on the previous slide gives a basic view
    model.

4
Objectives
  • Chapter 2
  • Use vertex arrays and buffer objects to store and
    access geometric data with fewer function calls.
  • Chapter 3
  • For specifying the position of the models in the
    scene and choosing a vantage point from which to
    view the scene besides using the default
    positioning and vantage point.
  • View a geometric model in any orientation by
    transforming it in three-dimensional space.
  • transformation for viewing and project the model
    onto the screen.
  • 3. Chapter 4
  • Use smooth shading to draw a single polygon with
    more than one color.
  • 4. Chapter 5
  • Render illuminated objects by defining the
    desired light sources and lighting model.
  • 5. Chapter 6
  • Blending - Blend colors to achieve such effects
    as making objects appear translucent.
  • 6. Chapter 7
  • Understand how display lists can be used along
    with commands in immediate mode to organize your
    data and improve performance.
  • 7. Chapter 8
  • Position and draw bitmapped data.
  • Read pixel data (bitmaps and images) from the
    frame-buffer into processor memory and from
    memory into the frame-buffer.
  • 8. Chapter 9
  • Understand what texture mapping can add to your
    scene.

5
Objectives - Implementation
  • Use vertex arrays and buffer objects to store and
    access geometric data with fewer function calls.
    Chapter 3 - 6 objectives.
  • vertex arrays lets you access a set of vertices
    and data by index.
  • Vertex arrays were intended to let the programmer
    to specify blocks of dynamic geometry data with
    as few function calls as possible.
  • View a geometric model in any orientation by
  • transforming it in three-dimensional space.
  • transformation for viewing and project the model
    onto the screen.
  • gluLookAt(x, y, z, lx, ly, lz,0.0f,1.0f,0.0f)

6
Objectives Contd.
  • Use smooth shading to draw a single polygon with
    more than one color.
  • Render illuminated objects by defining the
    desired light sources and lighting model
  • Different types of light
  • GLfloat LightAmbient 0.5f, 0.5f, 0.5f, 1.0f
    // Ambient Light Values ( NEW )
  • GLfloat LightDiffuse 1.0f, 1.0f, 1.0f, 1.0f
    // Diffuse Light Values ( NEW )
  • Positioning the light source
  • GLfloat LightPosition 0.0f, 0.0f, 2.0f,
    1.0f // Light Position ( NEW )
  • Setting up the light
  • glLightfv(GL_LIGHT1, GL_AMBIENT, LightAmbient)
    // Setup The Ambient Light
  • glLightfv(GL_LIGHT1, GL_DIFFUSE, LightDiffuse)
    // Setup The Diffuse Light
  • glLightfv(GL_LIGHT1, GL_POSITION,LightPosition)
    // Position The Light
  • glEnable(GL_LIGHT1) // Enable Light One
  • Blending - Blend colors to achieve such effects
    as making objects appear translucent
  • We enable blending just like everything else.
    Then we set the equation, and turn off depth
    buffer writing when drawing transparent objects,
    since we still want objects behind the
    translucent shapes to be drawn.

7
Objectives Contd.
  • Understand how display lists can be used along
    with commands in immediate mode to organize your
    data and improve performance
  • Creating display lists.
  • GLuint snowManDL
  • // Create the id for the list
  • snowManDL glGenLists(1)
  • // start list
  • glNewList(snowManDL,GL_COMPILE)
  • // call the function that contains
  • // the rendering commands
  • glBegin(GL_LINES)
  • .
  • .
  • glEnd()
  • // endList
  • glEndList()
  • RENDERING
  • glCallList(snowman_display_list)

8
Objectives Contd.
  • Position and draw bitmapped data.
  • Read pixel data (bitmaps and images) from the
    frame-buffer into processor memory and from
    memory into the frame-buffer
  • Understand what texture mapping can add to your
    scene
  • Control how a texture image is filtered as it's
    applied to a fragment.
  • Supply texture coordinates to indicate how the
    texture image shouldbe aligned with the objects
    in your scene.
  • Understand what buffers make up the frame-buffer
    and how they're used
  • Clear selected buffers and enable them for
    writing.

9
3D Bounce
Write a Comment
User Comments (0)
About PowerShow.com