Results 1 to 9 of 9

Thread: Uniformity to match TBGL with other Modules

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

    Uniformity to match TBGL with other Modules

    Thanks to Primo's test of my test noise dll, it brought up an important issue of different types.
    In studying Ken Perlin's code, he uses floats, doubles, integers. Since I am adapting his code for thinBasic's use,
    I need your input Petr on what types all things should be so that I can make them compatible with TBGL.

    I do already see that you need to add a tbgl_trgbaf type or similar, so that floating point color values can be used. And if doubles supported, then will need to add a type for that. Up to you, I will write the code for dll accordingly to keep things uniform.

    So in essence, what should I use. For instance, I don't see int32 in the help but you had mentioned it before?:
    Perlin TBGL Use
    Double Double Single?
    Float Single Single?
    Int Long ?
    uint dword ?
    Last edited by kryton9; 14-05-2017 at 21:13.
    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

  2. #2
    Super Moderator Petr Schreiber's Avatar
    Join Date
    Aug 2005
    Location
    Brno - Czech Republic
    Posts
    6,790
    Blog Entries
    3
    Rep Power
    693
    Hi Kent,

    Int32 is alias for Long, they are equivalent.

    Please use whatever precision you need, thinBasic & TBGL will convert to target automagically

    Using the *D functions ... believe me it makes no sense to use DOUBLE for color when we have displays, which have 8bits per color channel

    Just convert the number in 0..1 range to 0..255 range by multiplying by 255 and using the TBGL_Color.


    Petr
    Last edited by Petr Schreiber; 15-05-2017 at 09:04.
    Learn 3D graphics with ThinBASIC, learn TBGL!
    Windows 7 64bit - Intel Core 2 Duo T6600 @ 2.2GHz - 4 GB RAM - NVIDIA GeForce G210M 512MB
    Windows 8 64bit - Intel Core i5-3350P @ 3.1GHz - 8 GB RAM - NVIDIA GeForce GT640 3GB

  3. #3
    thinBasic MVPs kryton9's Avatar
    Join Date
    Nov 2006
    Location
    Naples, Florida & Duluth, Georgia
    Age
    61
    Posts
    3,869
    Rep Power
    397
    Perlin was using Doubles, that is what threw me off. I will work in floats(singles). Thanks.

    Is there a list of the numeric aliases anywhere in the help?
    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

  4. #4
    Super Moderator Petr Schreiber's Avatar
    Join Date
    Aug 2005
    Location
    Brno - Czech Republic
    Posts
    6,790
    Blog Entries
    3
    Rep Power
    693
    Hi Kent,

    the data types are briefly mentioned in change notes here:
    http://www.thinbasic.com/public/prod...on_1_8_0_0.htm

    For some time, I am thinking about community aided documentation for thinBASIC.
    Eros is using excellent tool for the help file, probably one of the best, but it has one catch - it is very expensive.



    Petr
    Learn 3D graphics with ThinBASIC, learn TBGL!
    Windows 7 64bit - Intel Core 2 Duo T6600 @ 2.2GHz - 4 GB RAM - NVIDIA GeForce G210M 512MB
    Windows 8 64bit - Intel Core i5-3350P @ 3.1GHz - 8 GB RAM - NVIDIA GeForce GT640 3GB

  5. #5
    thinBasic MVPs kryton9's Avatar
    Join Date
    Nov 2006
    Location
    Naples, Florida & Duluth, Georgia
    Age
    61
    Posts
    3,869
    Rep Power
    397
    Ahhh, I tried the help search online and offline and it doesn't apparently search the recent updates pages. If it searched those it would solve all the issues.
    I think opening up to the community could cause issues. I believe in benevolent dictators running languages to give a uniform style to the language
    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

  6. #6
    Super Moderator Petr Schreiber's Avatar
    Join Date
    Aug 2005
    Location
    Brno - Czech Republic
    Posts
    6,790
    Blog Entries
    3
    Rep Power
    693
    I was thinking about some pull-request based approach, to give dictators enough power


    Petr
    Learn 3D graphics with ThinBASIC, learn TBGL!
    Windows 7 64bit - Intel Core 2 Duo T6600 @ 2.2GHz - 4 GB RAM - NVIDIA GeForce G210M 512MB
    Windows 8 64bit - Intel Core i5-3350P @ 3.1GHz - 8 GB RAM - NVIDIA GeForce GT640 3GB

  7. #7
    thinBasic MVPs Michael Hartlef's Avatar
    Join Date
    Sep 2006
    Location
    Leverkusen, Germany
    Age
    51
    Posts
    3,278
    Blog Entries
    2
    Rep Power
    339
    Is "the opening of TB" about everything or just modules?
    Running Windows 7 Home, 64 bit, 8 GB ram, Athlon II X2 255, ATI Radeon HD 4200.

  8. #8
    thinBasic author ErosOlmi's Avatar
    Join Date
    Sep 2004
    Location
    Milan - Italy
    Age
    50
    Posts
    8,170
    Blog Entries
    2
    Rep Power
    10
    Numeric alias added to manual. Will be present in next release.

    I'm using Help & Manual version 5.6 (an old version but more than enough for my needs) for thinBasic manual: http://www.helpandmanual.com/products_hm_overview.html
    If you have something to add/amend/re-organize/whatever regarding manual please post a request into manual forum and I will try to do it: http://www.thinbasic.com/community/f...-Help-Material
    Some parts of the manual are poorly documented with no examples. If you want to contribute ... I will be happy to include contributions.

    @Michael
    "the opening of TB" is about almost all modules for the moment.
    I suppose thinAir will follows and also some tools like debugger and profiler
    thinCore (thinBasic Core engine) and thinBundling (build executables from thinBasic scripts) will not be open source.

    Last edited by ErosOlmi; 16-05-2017 at 11:19.
    www.thinbasic.com | www.thinbasic.com/community/ | psch.thinbasic.com
    Win10Pro 64bit - 8GB Ram - Intel i7 M620 2.67GHz - NVIDIA Quadro FX1800M 1GB

  9. #9
    thinBasic MVPs Michael Hartlef's Avatar
    Join Date
    Sep 2006
    Location
    Leverkusen, Germany
    Age
    51
    Posts
    3,278
    Blog Entries
    2
    Rep Power
    339
    @Eros: Thanks for the info.
    Running Windows 7 Home, 64 bit, 8 GB ram, Athlon II X2 255, ATI Radeon HD 4200.

Similar Threads

  1. Meteorite hits fan at cricket match
    By Charles Pegge in forum Shout Box Area
    Replies: 3
    Last Post: 26-07-2010, 22:21
  2. Tools and modules
    By Michael Hartlef in forum thinStudio
    Replies: 1
    Last Post: 19-09-2008, 01:06
  3. New modules in development?
    By Michael Hartlef in forum Shout Box Area
    Replies: 25
    Last Post: 12-10-2007, 14:19
  4. Connection to other modules?
    By Michael Hartlef in forum Module SDK (Power Basic version)
    Replies: 12
    Last Post: 11-08-2007, 11:12
  5. FTP (and other) modules
    By Paul_Johnson in forum thinBasic General
    Replies: 2
    Last Post: 23-06-2006, 15:26

Posting Permissions

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