Results 1 to 7 of 7

Thread: JEDI-SDL in Lazarus throwing a compile error in SDL_AddPixel

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    The problem is this line:
    Code:
    PUInt8( Addr )^ := R or G or B;
    Addr is declared as:
    Code:
    Addr         : cardinal;
    And cardinal is a 32bit, which isn't going to work on a 64bit OS

    Overall looking sdlutils.pas reveals some pretty bad code(bad in the sense it shouldn't be used for crossplatform use). Cardinal is used all over for pointer arithmetic. Unless it's given a large overhaul it won't work on anything but 32bit platforms
    Peregrinus, expectavi pedes meos in cymbalis
    Nullus norvegicorum sole urinat

  2. #2
    Thanks Guys.
    There's totally some bad code in sdlutils, I wrote some of it LOL.

    Yes it's Windows. The Mac is lovely, but all of my dev work is on Windows these days.

    Unfortunately, My CBCFoundation engine uses it extensively (for better or for worse).

    I'll download the 32bit version of Lazarus to see if that helps.

    I should probably dump the CBCFoundation anyway in favour of an OpenGL based one - I'm too old to be writing Engines these days.

    Thanks again.

  3. #3
    PGD Staff code_glitch's Avatar
    Join Date
    Oct 2009
    Location
    UK (England, the bigger bit)
    Posts
    933
    Blog Entries
    45
    Yes it's Windows
    Sorry, but I have to post a quick OUCH. I read you were using OpenGl, I'd watch some of it. Depending on the age of the setup you may find MS prefers D3D over OGL and it does show...
    I once tried to change the world. But they wouldn't give me the source code. Damned evil cunning.

  4. #4
    Co-Founder / PGD Elder WILL's Avatar
    Join Date
    Apr 2003
    Location
    Canada
    Posts
    6,107
    Blog Entries
    25
    Quote Originally Posted by code_glitch View Post
    Sorry, but I have to post a quick OUCH. I read you were using OpenGl, I'd watch some of it. Depending on the age of the setup you may find MS prefers D3D over OGL and it does show...
    Easy doom-sayer. That would only be if they were using crappy drivers.
    Jason McMillen
    Pascal Game Development
    Co-Founder





  5. #5
    PGD Staff code_glitch's Avatar
    Join Date
    Oct 2009
    Location
    UK (England, the bigger bit)
    Posts
    933
    Blog Entries
    45
    But seriously, although I may not have had a total fail I cannot help noticing a 10fps speed difference on windows nonetheless so there is some truth to it in just about all instances unfortunately.
    I once tried to change the world. But they wouldn't give me the source code. Damned evil cunning.

Tags for this Thread

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
  •