2015-04-20 8:38 GMT+02:00 Matthieu Lacaton <matthieu.laca...@gmail.com>:
> Hello, > > Thanks for your answers ! I have multiple remarks here : > > On my computer (which is probably not the fastest I must admit) running it > with a fork slows the whole operating system. > What you could do, add a wait time in your event proccessing loop stop := false. [ stop ] whileFalse: [ .... 20 milliSeconds wait. ]. So, it does not constantly checks for new events. The better, cleaner way of course is, don't use your own sdl event processing loop, but use OSWindow (as soon as this is working :) ) best nicolai Matthieu > > > 2015-04-20 1:57 GMT+02:00 Alexandre Bergel <alexandre.ber...@me.com>: > >> Hi Matthieu, >> >> This is important: Binding SDL with Pharo will help Roassal to get better. >> Please, let us know how it goes >> >> Alexandre >> >> >> > On Apr 9, 2015, at 12:54 PM, Matthieu Lacaton < >> matthieu.laca...@gmail.com> wrote: >> > >> > Hello everyone, >> > >> > I tried to use the SDL2 binding to Pharo to create a very basic 2D >> application (just some sprites and events) and it worked great. >> > The issue I have is that when I start my application, as long as I have >> an active SDL window, I can't use my Pharo image anymore (it freezes). >> > To solve this problem I tried opening my application in another thread >> by doing so : >> > [ (MyApplication new) start. ] forkAt: Processor lowestPriority. (If I >> don't chose a low priority it changes nothing) >> > >> > The problem is that even if it kind of works, it is really slow and it >> slows my whole operating system as well (I use windows XP) >> > >> > How can I fork more efficiently or open a SDL window without losing >> control of my image ? >> > >> > Thanks, >> > >> > Matthieu >> >> -- >> _,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;: >> Alexandre Bergel http://www.bergel.eu >> ^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;. >> >> >> >> >> >