Results 1 to 9 of 9

Thread: TBGL Stars with twinkle

  1. #1
    Super Moderator Petr Schreiber's Avatar
    Join Date
    Aug 2005
    Location
    Brno - Czech Republic
    Posts
    7,153
    Rep Power
    736

    TBGL Stars with twinkle

    Here is very basic example on star flight.
    It is hardly revolutionary, but can show you how entity system can be used for this common task.

    Interesting to watch how much the twinkle improved the feeling of depth and masked reincarnating stars in the background.

    Attached Files Attached Files
    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

  2. #2

    Re: TBGL Stars with twinkle

    Hi Petr,

    Looks wonderfully serene. I am sure there are nebulae, galaxies and planetary systems forming in the background - perhaps they are made of dark matter.

    Charles

  3. #3
    Super Moderator Petr Schreiber's Avatar
    Join Date
    Aug 2005
    Location
    Brno - Czech Republic
    Posts
    7,153
    Rep Power
    736

    Re: TBGL Stars with twinkle

    Hi Charles,

    thanks
    That %eBox was problem on my side, that line should not be there
    I updated the download.


    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

  4. #4
    Member matthew's Avatar
    Join Date
    Mar 2007
    Location
    England
    Age
    47
    Posts
    489
    Rep Power
    66

    Re: TBGL Stars with twinkle

    It reminds me of something you'd probably see in Star Trek.
    Operating System: Windows 10 Home 64-bit
    CPU: Intel Celeron N4000 CPU @ 1.10GHz
    Memory: 4.00GB RAM
    Graphics: Intel UHD Graphics 600

  5. #5

    Re: TBGL Stars with twinkle

    This colors the stars using pseudo random numbers derived from the star iterator e.
    [code=thinbasic]
    ' -- Color change to simulate twinkle
    c = sin(gettickcount*0.01+e)*.25+1.75
    '
    'pseudorandom tints
    fr=(e*123) and msk
    fg=(e*571) and msk
    fb=(e*579) and msk
    '
    TBGL_EntitySetColor(%sScene, e, fr*c, fg*c, fb*c)
    [/code]


    Charles
    Attached Files Attached Files

  6. #6
    Super Moderator Petr Schreiber's Avatar
    Join Date
    Aug 2005
    Location
    Brno - Czech Republic
    Posts
    7,153
    Rep Power
    736

    Re: TBGL Stars with twinkle

    What a colourful Space :]
    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

  7. #7

    Re: TBGL Stars with twinkle

    A few purple stars hurtling past could be attributed to the Doppler effect when travelling near the speed of light. - unlike our red-shifted view from planet Earth.

    Charles

  8. #8
    Super Moderator Petr Schreiber's Avatar
    Join Date
    Aug 2005
    Location
    Brno - Czech Republic
    Posts
    7,153
    Rep Power
    736

    Re: TBGL Stars with twinkle

    That is nice interpretation

    At one point I was thinking whether to restrict maximum speed of tbgl entities to 299 792 458 m/s, then I realised I should take a rest
    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

  9. #9

    Re: TBGL Stars with twinkle


    When coding, my head spins so fast, time slows down relative to everybody elses.

    Ch a r l e s

Similar Threads

  1. You rate better than 4 stars
    By AMark in forum Who you are
    Replies: 6
    Last Post: 30-06-2011, 18:04
  2. Effects, stars, colors example :)
    By Lionheart008 in forum TBGL General
    Replies: 6
    Last Post: 09-12-2008, 21:37

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
  •