flat assembler
Message board for the users of flat assembler.

Index > Linux > Smallest possible gui app?

Author
Thread Post new topic Reply to topic
vivik



Joined: 29 Oct 2016
Posts: 671
vivik 14 Apr 2018, 18:08
Can you write something like, window that displays a blue square on a black background, and this square moves when you press arrow keys?

Something with minimal use of libraries, and that even uses syscalls directly instead of using libc. Studying musl internals may help here.

I'm not sure what api you should use for this exactly, maybe x window system? Or maybe something like gtk/qt? Or framebuffer? What is most widespread, what is most lowlevel/fast?

I'm trying to do this for windows right now, would be nice if somebody would study this for linux in parallel. It's quite a fruitless job, the only advantage is being able to say that you know every byte in your program.
Post 14 Apr 2018, 18:08
View user's profile Send private message Reply with quote
vivik



Joined: 29 Oct 2016
Posts: 671
vivik 15 Apr 2018, 14:24
Post 15 Apr 2018, 14:24
View user's profile Send private message Reply with quote
donn



Joined: 05 Mar 2010
Posts: 321
donn 16 Apr 2018, 01:01
A long time ago, SDL was pretty common. It was cross-platform and I was able to get it to work pretty easily. It was also supposedly powerful, making it a candidate for 3D apps. I just looked at their website and I think they said Valve used it.

A more minimal approach may be with syscalls, curious what you end up picking. I looked up what NVidia's OpenCL samples used (my Linux setup is not very functional at the moment, so I can't really install them) and I think they mention:

Quote:
for many Linux distributions do not include the necessary OpenGL, GLUT, GLU, GLEW,
X11, Xi, Xlib, or Xmi headers or libraries
in the Linux variants. Vulkan's samples seem to use:

Quote:
Libraries that are not used by the SDK, but which may be useful for developers and which may be required for templates Currently, GLM and SDL are included
with their windowing also. Good luck...
Post 16 Apr 2018, 01:01
View user's profile Send private message Reply with quote
Display posts from previous:
Post new topic Reply to topic

Jump to:  


< Last Thread | Next Thread >
Forum Rules:
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Copyright © 1999-2024, Tomasz Grysztar. Also on GitHub, YouTube.

Website powered by rwasa.