Results 1 to 2 of 2

Thread: Coordinate System

  1. #1
    Guest

    Coordinate System

    Hi!

    I am a very beginner in programming OpenGL applications.
    The problem is that how to change the default coordinate system. The default is
    (-1,1;1,-1) as I suppose.
    But I want
    (-8;8;8;-.
    How to change the default coordinate system?

    And one more thing: why can't I use glVertex2d function? glVertex3f and glVertex2i functions work just fine. Maybe you know where is the trick.

    Thanks, bye!

  2. #2
    Senior Member OpenGL Guru
    Join Date
    Jun 2000
    Location
    Gastonia, NC, USA
    Posts
    2,068

    Re: Coordinate System

    Do you mean the window corrdinates?
    You set that when setting the viewing area.
    glViewport() and glortho2d().


    The vertex qestion:
    glvertex2f has to be a float (0.0, -1.0, 1.0)
    glvertex2i has to be an int(0,1, 5, 100)
    glvertex2d has to be a double.

    When you use the glvertex2d do you use a variable that is a double?

    Originally posted by Anvar:
    Hi!

    I am a very beginner in programming OpenGL applications.
    The problem is that how to change the default coordinate system. The default is
    (-1,1;1,-1) as I suppose.
    But I want
    (-8;8;8;-.
    How to change the default coordinate system?

    And one more thing: why can't I use glVertex2d function? glVertex3f and glVertex2i functions work just fine. Maybe you know where is the trick.

    Thanks, bye!

Similar Threads

  1. Add system coordinate
    By sckeedo in forum OpenGL: Basic Coding
    Replies: 0
    Last Post: 05-26-2014, 10:29 AM
  2. what about coordinate system?
    By beloni in forum OpenGL: Basic Coding
    Replies: 4
    Last Post: 03-16-2007, 12:21 PM
  3. 3D coordinate system
    By woodstock in forum OpenGL: Basic Coding
    Replies: 3
    Last Post: 03-11-2005, 04:16 AM
  4. GDI Coordinate system
    By DVazanias in forum OpenGL: Advanced Coding
    Replies: 3
    Last Post: 03-05-2002, 06:18 AM
  5. Coordinate .... system...
    By Akash in forum OpenGL: Basic Coding
    Replies: 2
    Last Post: 08-12-2001, 06:23 AM

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