Final Platform Layer » Forums » Feedback for FPL!
Finalspace
125 posts / 1 project

I am finalspace and do programming since more than 25 years, started on C64 and got serious with borland delphi. Nowadays i use C/C++ only.

#14974 Feedback for FPL!
6 months ago Edited by Finalspace on April 17, 2018, 11:09 a.m. Reason: Initial post

This thread is dedicated to any constructive feedback for FPL.
So if you got some ideas to make this library better in any way, you are welcome to post it here ;)
Thanks!
Marmot
Cairn
4 posts
#15412 Feedback for FPL!
4 months, 2 weeks ago

Hi, I think it would be useful to be able to resize the window without blocking. One way to this would be using fibers.
Per Vognsen does this in his platform layer for example:
https://gist.github.com/pervognse...0021b95c8d0a7b72#file-mu-cpp-L139
See also related tweet:
https://twitter.com/nothings/status/960730509985832961
Finalspace
125 posts / 1 project

I am finalspace and do programming since more than 25 years, started on C64 and got serious with borland delphi. Nowadays i use C/C++ only.

#15596 Feedback for FPL!
3 months, 3 weeks ago Edited by Finalspace on June 20, 2018, 3:37 p.m.

Marmot
Hi, I think it would be useful to be able to resize the window without blocking. One way to this would be using fibers.
Per Vognsen does this in his platform layer for example:
https://gist.github.com/pervognse...0021b95c8d0a7b72#file-mu-cpp-L139
See also related tweet:
https://twitter.com/nothings/status/960730509985832961


This is neat, thanks!

I never read or heard about fibers at all. But i will read things up and play around with it.
But looks like a fine way to move the window message processing into its own special separated thread.
mmozeiko
Mārtiņš Možeiko
1808 posts / 1 project
#15606 Feedback for FPL!
3 months, 3 weeks ago

Not thread. That's the point of fibers - they execute on same thread as "calling" code. You basically execute for a while and then "jump" to different place to execute. By "place" I mean you assign instruction pointer and all the other registers different values. Now you execute in "other place" for a while. And then "jump" back to original place.

This is how you implement coroutines. Like "await" keyword in Node.JS or Python or C#.