Page 2 of 2 FirstFirst 12
Results 11 to 16 of 16

Thread: thinBasic Beta 1.9.6.0

  1. #11
    Super Moderator Petr Schreiber's Avatar
    Join Date
    Aug 2005
    Location
    Brno - Czech Republic
    Posts
    7,128
    Rep Power
    732
    I am really curious how far the ThinBASIC embedding could be pushed. I consider this area very interesting.

    For random forum visitors - this release contains updated TBGL module with support for Drag&Drop. If you ever tried to do this using Win32 API, you are probably gray haired man now. With TBGL, it gets more simple:

    Step #1: Subscribe for receiving notification about files being dragged to your window
    ' -- The following enables programmer to handle dropping files to window
    ' -- The window is identified via hWnd handle
    ' -- Once the event occurs, the function Main_OnDropFiles will be launched
    TBGL_BindWindowEvent(hWnd, %TBGL_OnDropFiles, Main_OnDropFiles)
    
    Of course -the function does not need to be called Main_OnDropFiles, you are free to choose any other function name.

    Step #2: Handle the event
    ' -- Function fired thanks to previous bind using TBGL_BindWindowEvent
    Function Main_OnDropFiles()
      
      ' -- Retrieve number of files
      Long nFiles = TBGL_OnDropFiles_GetFileCount()
      Long i
    
      ' -- Iterate through all of them and list their names
      For i = 1 To nFiles
        MsgBox TBGL_CallingWindow, "File " + Format$(i) + " is " + TBGL_OnDropFiles_GetFileName(i)
      Next
    
    End Function
    

    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

  2. #12
    thinBasic MVPs
    Join Date
    Oct 2012
    Location
    Germany
    Age
    54
    Posts
    1,525
    Rep Power
    170
    Some nosy question here: I checked the inc/lib-folders for freeimage - there's none inside...haven't they been there before some time?


    so I downloaded from sourceforge and play around with the vb-wrapper in thinAir

    ... now there are a few things inside that let me wonder a little bit, a couple of very specific types and constants that become blue and bold... so is there some FreeImage-module or new wrapper planned? Or this just coincidences?
    for example this:
    %BLACKONWHITE  ' As Long = 1
    %WHITEONBLACK  'As Long = 2
    %COLORONCOLOR ' As Long = 3
    
    'or 
    Type RGBQuad
    Type RGBTriple
    
    become bold'n blue.
    might I just make seperate constants or take them as they are in tB? - Or should I stop playing around with that wrapper?
    Last edited by ReneMiner; 07-05-2013 at 14:35.
    I think there are missing some Forum-sections as beta-testing and support

  3. #13
    thinBasic author ErosOlmi's Avatar
    Join Date
    Sep 2004
    Location
    Milan - Italy
    Age
    57
    Posts
    8,777
    Rep Power
    10
    Yes, they are defined into UI module.

    Regarding FreeImage I had some ideas in the past but very little time to work on it.
    I wanted to create a thinBasic module.

    I have the attached INC file, quite old.
    Maybe it can help.
    Attached Files Attached Files
    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

  4. #14
    thinBasic MVPs
    Join Date
    Oct 2012
    Location
    Germany
    Age
    54
    Posts
    1,525
    Rep Power
    170
    Here's my answer - with yours up there and the one of Petr I was able to compare & find out about some variable-types & stuff- there's some small incompatibility with some types (dynamic UDT-subsets) - which I left in commented - also there are a few Functions wich await some
    "Optional Byval Value As Whatever = 123" - I'm not sure about them so I left the defaults commented near the function. But this needs new Version 3.15.4. of freeImage.dll which you'll find inside \Dist-Subfolder there.

    It's pretty much plain Basic since I took the vb6-wrapper as a base for this - and I tried to arrange it as clearly as possible to keep overview
    Attached Files Attached Files
    I think there are missing some Forum-sections as beta-testing and support

  5. #15
    Member
    Join Date
    Nov 2012
    Location
    Missouri, USA
    Posts
    113
    Rep Power
    29
    Hi, all,

    Of the two(2) FreeImage,zip's on this page, do either or both
    have anything to do with the FreeImage.dll that is in Rene's
    TBGL3dEd1.05b.zip?

    Bill

  6. #16
    thinBasic MVPs
    Join Date
    Oct 2012
    Location
    Germany
    Age
    54
    Posts
    1,525
    Rep Power
    170
    the one that is included in TBGL3dEd is an older version of freeImage.dll but serves to load common texture-files. The new version can load more different formats and also has a few changed and a couple of new functions.
    You should not use the inc-files posted here together with the freeImage.dll which is included in 3d-Ed-download.
    But you can use the new version (3.15.4. see links post above) of freeImage.dll together with 3d-Ed/ or replace the one in 3d-Ed-folder. All used functions still work the same way. Although the version 3.I.dunno something has only half the size and as long as I don't use any functions of the new freeImage.dll it will serve the purpose.
    Last edited by ReneMiner; 09-05-2013 at 04:23.
    I think there are missing some Forum-sections as beta-testing and support

Page 2 of 2 FirstFirst 12

Similar Threads

  1. thinBasic Beta 1.8.8.0
    By ErosOlmi in forum thinBasic Beta testing
    Replies: 14
    Last Post: 25-06-2011, 19:24
  2. thinBasic Beta 1.8.4.x
    By ErosOlmi in forum thinBasic Beta testing
    Replies: 8
    Last Post: 29-06-2010, 15:50
  3. thinBasic beta 1.7.10.3
    By ErosOlmi in forum thinBasic Beta testing
    Replies: 4
    Last Post: 27-02-2010, 01:44
  4. thinBasic beta 1.7.10.0
    By ErosOlmi in forum thinBasic Beta testing
    Replies: 147
    Last Post: 02-02-2010, 01:25
  5. thinBasic beta 1.7.9.0
    By ErosOlmi in forum thinBasic Beta testing
    Replies: 3
    Last Post: 25-08-2009, 13:58

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
  •