Results 1 to 5 of 5

Thread: OpenGL template

  1. #1

    OpenGL template

    I've written a basic OpenGL template with screenshot, font and console capabilities. Hopefully this will make my OpenGL experiments easier to design in future. You can download it from here:

    http://www.urbanaustralia.org/cragwo...emplate.tar.gz (64 kb)

    Tested with FPC v2.0.0 on Linux, and compiled with -Mobjfpc option.
    [size=10px]"In science one tries to tell people, in such a way as to be understood by everyone, something that no one ever knew before. But in poetry, it's the exact opposite." -- Paul Dirac[/size]

  2. #2

    OpenGL template

    Hi CW,
    which version of JEDI-SDL are you using? From looking at your project it looks like you are using v0.5. Is that correct?

    Are you aware that v1.0 has a simple windowing framework that should have creating either 2D or 3D contexts?
    <br /><br />There are a lot of people who are dead while they are still alive. I want to be alive until the day I die.<br />-= Paulo Coelho =-

  3. #3

    OpenGL template

    Quote Originally Posted by savage
    which version of JEDI-SDL are you using? From looking at your project it looks like you are using v0.5. Is that correct?
    No, I'm using v1.0. Is there something wrong in my code?

    Are you aware that v1.0 has a simple windowing framework that should have creating either 2D or 3D contexts?
    Yes, I know, but I prefer to roll my own.
    [size=10px]&quot;In science one tries to tell people, in such a way as to be understood by everyone, something that no one ever knew before. But in poetry, it&#39;s the exact opposite.&quot; -- Paul Dirac[/size]

  4. #4

    OpenGL template

    Quote Originally Posted by cragwolf
    No, I'm using v1.0. Is there something wrong in my code?
    Not wrong as such, but possibly less cross-platform. In v1.0 I changed all the SDL unit names to lowercase so that they would cause less hassle on Linux etc. So your unit clause should probably say something "sdl, gl, glu" if you plan to compile on Linux. Unless of course you have gone through and made all the units uppercase.
    <br /><br />There are a lot of people who are dead while they are still alive. I want to be alive until the day I die.<br />-= Paulo Coelho =-

  5. #5

    OpenGL template

    If the filename is lowercase, i.e. sdl.pas, then it makes no difference whether I use SDL or sdl in my uses clause. If the filename is uppercase, i.e. SDL.pas, then I need to use SDL in my uses clause (using sdl will return an error). So I'm glad you switched to lowercase for the filenames, so that silly duffers like me can not worry about these things.

    I might look through the FPC manuals to see if they mention this.
    [size=10px]&quot;In science one tries to tell people, in such a way as to be understood by everyone, something that no one ever knew before. But in poetry, it&#39;s the exact opposite.&quot; -- Paul Dirac[/size]

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •