Results 1 to 2 of 2

Thread: Texture Mapping

  1. #1
    Senior Member Regular Contributor
    Join Date
    Sep 2005
    Location
    Dayton
    Posts
    148

    Texture Mapping

    I am having problems understanding how texture mapping works? I have a 2-D screen and am taking a pgm file and creating it into a 3-D scene. I want to add a texture map of the pgm file to my 3-D scene, but I am having problems understanding how to do this. And I cannot find any good sources online to help me with this, so I thought maybe someone would know of a good example I could look at for this. I have the red book and superbible, but I don't quite follow these since most of the examples seem to use a bmp file. Thanks for your help!

  2. #2
    Super Moderator OpenGL Guru imported_dorbie's Avatar
    Join Date
    Jul 2000
    Location
    Bay Area, CA, USA
    Posts
    3,966

    Re: Texture Mapping

    You create a texture, select a texture environment mode, enable texturing and supply texture coordinates for each vertex.

    If you consider your texture image as a rubber sheet then the numbers 0.0 - 1.0 in x and y plot points on the image. The image is stretched between vertices of triangles using the locations you supply for each vertex.

Similar Threads

  1. Texture mapping ::: 3D Face Mapping
    By 3render3 in forum OpenGL: General
    Replies: 2
    Last Post: 03-24-2013, 06:49 PM
  2. projective texture mapping and shadow mapping
    By phoenix_gl in forum OpenGL: Advanced Coding
    Replies: 1
    Last Post: 10-08-2012, 08:00 PM
  3. Replies: 0
    Last Post: 01-09-2005, 05:53 PM
  4. Replies: 1
    Last Post: 01-09-2005, 05:50 PM
  5. Texture Mapping / Environmental Mapping.
    By imported_Andrew in forum OpenGL: Basic Coding
    Replies: 1
    Last Post: 12-09-2000, 01:20 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Proudly hosted by Digital Ocean