Results 1 to 8 of 8

Thread: Opengl viewer Demo

  1. #1

    Opengl viewer Demo

    At last!

    The latest Asmosphere contains an Opengl Demo, as well as the HelloWin.

    I've used this one before - it really put Asmosphere through its paces and resulted in a few more minor adjustments to the assembler.

    http://community.thinbasic.com/index.php?topic=1845.0

  2. #2
    thinBasic author ErosOlmi's Avatar
    Join Date
    Sep 2004
    Location
    Milan - Italy
    Age
    57
    Posts
    8,777
    Rep Power
    10

    Re: Opengl viewer Demo

    OMG
    this is something [wiki=NASA]NASA[/wiki] should have a look!
    Asmosphere code inside "Test_Opengl2.tbasic" script is very neat and a must to learn a lot on OS inside.

    Thanks a lot Charles!
    Attached Images Attached Images
    www.thinbasic.com | www.thinbasic.com/community/ | help.thinbasic.com
    Windows 10 Pro for Workstations 64bit - 32 GB - Intel(R) Xeon(R) W-10855M CPU @ 2.80GHz - NVIDIA Quadro RTX 3000

  3. #3

    Re: Opengl viewer Demo


    The original of this piece comes with Freebasic using GLFW. I translated it some time ago into pure Opengl for Freebasic and PB, when Patrice Terrier found that GLFW does not perform smoothly under Vista. I took the Freebasic version of this and converted most of it into inline ASM, I then took chunks of this and converted it to Asmosphere. This rather lengthy route enabled almost continuous testing during the translation process to catch errors as soon as they occur. But there were certain points where this kind of testing was not possible and these took exponentially longer to resolve. The lesson I draw from this is to write testable code wherever possible - the other stuff is very expensive

    I found a few bugs were getting through the traps so it was useful to find out where this was happening and plug the gaps. So it was a good exercise for Asmosphere.


  4. #4

    Re: Opengl viewer Demo

    Patrice Terrier found that GLFW does not perform smoothly under Vista.
    I have read that it flickers. Better to use SDK.

  5. #5
    Super Moderator Petr Schreiber's Avatar
    Join Date
    Aug 2005
    Location
    Brno - Czech Republic
    Posts
    7,128
    Rep Power
    732

    Re: Opengl viewer Demo

    Very impressive Charles!,

    I remember similar demo for GLUT, but it had window refresh problems. This has no problems at all.
    Very good!


    Petr
    Learn 3D graphics with ThinBASIC, learn TBGL!
    Windows 10 64bit - Intel Core i5-3350P @ 3.1GHz - 16 GB RAM - NVIDIA GeForce GTX 1050 Ti 4GB

  6. #6
    thinBasic MVPs kryton9's Avatar
    Join Date
    Nov 2006
    Location
    Naples, Florida & Duluth, Georgia
    Age
    67
    Posts
    3,869
    Rep Power
    404

    Re: Opengl viewer Demo

    Charles how in the world did you ever figure all of this out? I might as well have walked into an alien space ship and looked at a code printout from the off world programmer and not be anymore amazed!!
    Acer Notebook: Win 10 Home 64 Bit, Core i7-4702MQ @ 2.2Ghz, 12 GB RAM, nVidia GTX 760M and Intel HD 4600
    Raspberry Pi 3: Raspbian OS use for Home Samba Server and Test HTTP Server

  7. #7

    Re: Opengl viewer Demo


    Well I am a bottom-up coder and find that taking very small steps works well for me. My first program was 1 byte long: ret. then after accomplishing this without causing a GPF I got bolder and tried:

    nop
    ret


    and it just built up from there. Once you have a few proven building blocks it grows exponentially.

  8. #8
    thinBasic MVPs kryton9's Avatar
    Join Date
    Nov 2006
    Location
    Naples, Florida & Duluth, Georgia
    Age
    67
    Posts
    3,869
    Rep Power
    404

    Re: Opengl viewer Demo

    Hehehehe thanks for the tips, now only if my mind worked like yours!
    Acer Notebook: Win 10 Home 64 Bit, Core i7-4702MQ @ 2.2Ghz, 12 GB RAM, nVidia GTX 760M and Intel HD 4600
    Raspberry Pi 3: Raspbian OS use for Home Samba Server and Test HTTP Server

Similar Threads

  1. model viewer k9
    By kryton9 in forum TBGL Scripts and Projects
    Replies: 50
    Last Post: 18-05-2007, 20:48

Members who have read this thread: 0

There are no members to list at the moment.

Posting Permissions

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