Search found 11 matches

by kandl
Wed Jan 23, 2013 6:56 pm
Forum: Feature Requests and Wishlists
Topic: Please allow OpenWindow inside threads
Replies: 49
Views: 17808

Re: Please allow OpenWindow inside threads

Thanks Bernd!

The debugger also disallows WaitWindowEvent() and WindowEvent() from executing from inside a thread.
by kandl
Tue Jan 22, 2013 10:19 pm
Forum: Feature Requests and Wishlists
Topic: Please allow OpenWindow inside threads
Replies: 49
Views: 17808

Please allow OpenWindow inside threads

HI

I have multiple projects that uses OpenWindow inside a thread. They function as background processes and have their independent message processing loop. One example is an OpenGL application that spawns a drawing thread separate from the main window, it opens another window in its own thread to ...
by kandl
Tue Jun 28, 2011 8:33 pm
Forum: Tricks 'n' Tips
Topic: Infinite Scroll Area Gadget w/maps demo
Replies: 3
Views: 2118

Infinite Scroll Area Gadget w/maps demo

I've created a canvas-like gadget, I've made a custom gadget that draws a scrolling area (for win32 only)

source code: http://burninglogic.net/static/scrollimg_demo.zip

I've also made a google maps look-alike that uses openstreetmap tiles and the scrollimg gadget

use mousewheel to zoom in and ...
by kandl
Wed Jan 19, 2011 7:05 pm
Forum: Coding Questions
Topic: How do I free the memory used up in loading a DLL?
Replies: 14
Views: 2401

Re: How do I free the memory used up in loading a DLL?

i dont think it's really a bug in PB, because you didn't really free the library; need to call FreeLibrary() in win32

just have to make your own FreeLibrary() procedure

Code: Select all

Procedure FreeLibrary(library_no)
  
  FreeLibrary_(LibraryID(library_no))
  
EndProcedure
by kandl
Wed Jan 19, 2011 6:52 pm
Forum: Coding Questions
Topic: How to obtain the address of a string variable?
Replies: 25
Views: 4783

Re: How to obtain the address of a string variable?

i dont know what you are trying to do with that but this is how i pass string to anther thread


Procedure.i StrCpy(string$)
ProcedureReturn DuplicateMemory(@string$, (Len(string$) + 1) * SizeOf(CHAR))
EndProcedure

; main program

; starting a new thread
Thread(@func(), StrCpy("what you want to ...
by kandl
Tue Sep 07, 2010 1:21 am
Forum: Tricks 'n' Tips
Topic: OpenStreetMap embedded in your application
Replies: 34
Views: 24137

Re: OpenStreetMap embedded in your application

OSM2.1_win32.zip

http://www.sendspace.com/file/r5eavm (10:18 AM 9/8/2010)


OSM2_win32.zip

http://www.megaupload.com/?d=FRVTYBQE (8:21 PM 9/6/2010)
http://www.sendspace.com/file/pcootd (11:47 AM 9/7/2010)
by kandl
Wed Sep 01, 2010 3:34 am
Forum: Tricks 'n' Tips
Topic: OpenStreetMap embedded in your application
Replies: 34
Views: 24137

Re: OpenStreetMap embedded in your application

http://rapidshare.com/files/416374955/OSM2_win32.zip (updated 12:23 AM 9/1/2010)

as the name implies, only works on win32 atm (PB 4.50 x86)

itc.pb - thread and inter-thread comm
curl.pb - uses dll instead of lib. incomplete import list, only loaded functions that i might use

sqlite db file is ...
by kandl
Tue Aug 31, 2010 5:48 pm
Forum: Tricks 'n' Tips
Topic: OpenStreetMap embedded in your application
Replies: 34
Views: 24137

Re: OpenStreetMap embedded in your application

http://vimeo.com/14579414


program based on (this) discussion:

http://purebasic.fr/english/viewtopic.p ... 217ca777be


but significantly modified:

multi-threaded
accelerated graphics
mouse control
by kandl
Sat Apr 18, 2009 4:31 am
Forum: Tricks 'n' Tips
Topic: A OOP class for dynamically implementing hash tables!
Replies: 32
Views: 12915

i don't know why no one commented on my thread but my hash function looks much cleaner (and more generic) than yours

http://www.purebasic.fr/english/viewtopic.php?t=37060



Structure hashtable_char
c.c
EndStructure

Procedure.i hastable_hashingfunction(string$)

*p.hashtable_char = @string$
s ...
by kandl
Sat Apr 11, 2009 7:21 am
Forum: Tricks 'n' Tips
Topic: hashtable (anyone still interested?) solution
Replies: 2
Views: 2136

hashtable (anyone still interested?) solution

a complete solution

didn't do any speed test but it works pretty well



;
; hashtable.pb
; provide associative strings storage
; global methods
; .i addmultimap(key$, value$, Array key$(1), Array value$(1), Array table.s_hashtable(1))
;
; desc: add value pair to respective arrays
; generate hash ...