[Gambas-devel] A simplest component example

Benoit Minisini gambas at ...1...
Sat Sep 11 18:25:16 CEST 2004


On Saturday 04 September 2004 00:24, Marcio Roger Ferrari wrote:
> Thanks for the tips about components Minisini :-)
>
> Now, I have a job to do, but before this I would to talk a little bit more
> abou threads. As you said, there is no plans no Gambas suport threads and
> the interpreter was not design for this. However, when I talk about threads
> (and my desire to implement it - you were right: I didn't know that could
> be so difficult), I was think in one thing: Games and the SDL Gambas
> Component! I don't have many experience doing linux apps, but as I know (I
> can be wrong), timers does not offer the best performance. Some years ago
> (before discover Linux) I develop a small game using Directx and MFC (with
> VC++). And in MFC there is function named OnAppIdle, that can is called
> when the aplication is idle, or in other words, just waiting for events. So
> I could use this function to make all the game loop (read keys, joystick,
> move caracters of game, colision detection, etc) using lowlevel hardware
> access functions provided by DirectX ( as SDL probably works) with a good
> performance.
>
> Is there is a chance to implement it in Gambas 2.0 (of course if you
> doesn't have already a better plan) :-)
>
> Regards and thanks for provide for us a excellent IDE .
>
> Marcio Ferrari
>

SDL has its own event loop that is not yet managed by the SDL component.

But everything is ready for that in the interpreter. I mean, any component can 
have an event loop - But you can't use two components, each of one having an 
event loop.

Just a bit of developer time is missing.

Regards,

-- 
Benoit Minisini
mailto:gambas at ...1...




More information about the Devel mailing list