freenode/#lisp - IRC Chatlog
Search
23:30:54
aeth
ebrasca: Virtual Reality is real time programming. Instead of thinking in terms of batches, you think in terms of actions done in a time interval. Instead of running foo in 1.4 seconds, you run tiny little pieces pieces of foo in 0.0005 seconds and need to leave room for every other tiny little piece that needs to be done that tick of time.
23:31:54
ebrasca
ACTION don't know what to make cl-vulkan triangle , btrfs/etx4/cache for mezzano ...
23:32:15
aeth
Unlike regular game programming you have three issues: (1) the ideal resolution is higher, (2) the ideal framerate is higher (the time to do things is 1/fps, so that means the time to do things, at least related to rendering, is smaller), and (3) missing a frame (by taking too long somewhere) is more problematic because you might make your user ill
23:34:35
aeth
pjb: Assuming you're correct (and you're not quite correct here) that game was in 30 FPS. (/ 30d0) => 0.03333...d0 so You had that much time to do your computations. (It probably did everything in the same framerate without logic independent of rendering.) For VR you're probably thinking in terms of at least (/ 90d0) => 0.01111...d0
23:36:01
aeth
Of course, modern games (should) do logic independently of the rendering framerate so your logic could e.g. be a constant 0.01 s even when you have 90 FPS or 144 FPS at the display, but there are some things that would have to run with the graphical tick even if your logic tick is every 10 FPS or so.
23:36:18
pjb
It can be as CL as you want it to be. The point is that you use CL to metaprogram and make your system generate the binary you need.
23:37:12
no-defun-allowed
Also, https://web.archive.org/web/20070127022728/http://lists.midnightryder.com/pipermail/sweng-gamedev-midnightryder.com/2005-August/003804.html
23:37:56
aeth
pjb: It's funny how you think that I'm ignorant of the topic, though. I'm writing the only Common Lisp game engine that focuses on high performance, high frame rate, and real time over convenience. So when I'm complete it will be the most likely to be usable on actual VR systems without first porting a RTGC to a CL implementation.
23:39:11
aeth
My provided part of the game loop is nonconsing which means the GC will only run when the user wants it to if that's a concern of the user. (Or the user can cons, which could trigger the GC at unexpected times, and it's up to the user, not the framework or engine, where to be on convenience vs. dependable performance.)
23:49:07
aeth
Although it's not really about being usable on $foo it's about how much you can safely do on $foo to stay within the time limitations
0:08:00
aeth
Not a lot of progress lately because it's a very big, fragile thing even though I've tried my hardest to be modular. The nature of the problem is kind of anti-modular. Takes a while to be able to dive into the code.
0:12:42
aeth
ebrasca: CEPL is an interactive graphics framework, Zombie Raptor is a game engine. So they both work on top of cl-opengl and probably both on top of cl-sdl2 (not sure about CEPL), but the abstractions are different. CEPL assumes you're in something like SLIME and wanting to edit graphics interactively. ZR assumes you're creating a game that's run by instantiating the game object with #'make-game
0:13:53
aeth
ZR doesn't do as many things 'live' (i.e. change the code and see the result immediately), but it probably could add some more of that by adding periodic checking for change (like once a second) or by having F5 see if shaders need to be reloaded, etc.
0:16:45
aeth
Jachy: Although I guess that's not quite true. I do have a chess GUI, as in, the user interface of a chess program... a chess engine is the AI part, and I use UCI for that, defaulting to running the "stockfish" command, but it should run any stockfish-like UCI-using chess engine. At the moment it's just AI vs AI because I haven't finalized the click-recognizing API.
0:17:28
aeth
Fun fact: my engine is entirely 3D, but that chess program is currently entirely 2D (using the free chess graphics from Wikipedia). The chess board is actually rendered on the 2D HUD.
0:18:28
pjb
It would be nice to make it 4D so that time is taken into account and movement in the 3D space be possible…
0:18:38
aeth
cl-chess doesn't do complete AI vs AI games yet. I need to be able to recognize checkmate and draws (mostly draws when the AI plays itself). My checkmate code was broken in edge cases so iirc I removed it.
0:21:18
Jachy
Can objects in the HUD have different z-orders, or is it mostly dependent on draw order?
0:21:38
aeth
Jachy: I suspect at the moment if you put two objects on top of each other you're going to get z-fighting.
0:22:00
aeth
Everything is very basic at the moment because you kind of have to do everything 70% of the way in order to get anything that's usable.
0:23:03
aeth
At the moment instead of moving chess piece sprites on top of a board sprite, I use 64 piece-on-board sprites (or blank) for the correct background color
0:27:12
aeth
Well, I don't really promote this engine because it's not really usable at the moment because I can and do break things dramatically. I even got some memory errors a while back in my older test programs when I revisted them because I switched to static-vectors and so it was trying to free CL arrays (there's no way to tell static-vectors arrays appart from CL arrays).
0:30:26
aeth
I had to switch to static-vectors for textures and 3D models to avoid copying from CL arrays to C arrays for use in OpenGL, which made my terrain test (not the one included in the engine, a different one) take several minutes to load instead of < 1 second.
1:08:54
nirved
verisimilitude: how would you write 9 bits to a file? AFAIK all fs are using bytes as smallest thing to write.
2:03:06
pjb
All FS I know are using blocks as the smallest thing they can write. Also, most random-access devices use sectors as the smallest thing they can write.
2:03:50
pjb
You will also observe that some FS will optimize reading and writing from hard disks by using the track or the cylinder as unit of read or write.
2:04:22
pjb
The idea of files as a sequence of bytes is a figment of the imagination of the POSIX standard.
2:05:45
pjb
Now, as for how one would write 9 bits to a file, well, basically what will occur ultimately, is that a sector is read from the hard disk and copied in a memory buffer, then you will modify 9 bits (or more) in that memory buffer, and then that memory buffer will be copied back to write a sector (possibly the same, often a new one).
2:06:37
pjb
Knowing that, how you use the POSIX file abstration to write 9 bits is rather irrelevant; several solutions are possible.
2:07:06
nirved
pjb: you can create an one byte file, so this is the smallest thing; internally there might be blocks, but this is not exposed
2:07:29
pjb
Or you can use the write and read (byte buffer) abstraction of POSIX, and spread the 9 bits over two bytes. Or 9 bytes as non-clisp implementations do.
2:09:28
pjb
nirved: notably, controller-less disk media (eg. Apple floppies), had just hardware to read the tracks as a sequence of bit. Mapping track bits to sectors of bytes was done by software.
2:32:19
nirved
pjb: files with element-type bit are really strange in clisp - there is a 4-byte file-length prefix at the beginning
2:33:52
no-defun-allowed
makes sense, you couldn't count bits just by file length without some information
2:35:04
aeth
Going back to both of the earlier topics of McCLIM and my game engine, I'm not going to be integrating McCLIM because that would go against my two goals of (1) leaving anything that could hurt performance to the user of the engine to do and (2) all-in-one binary distribution (my interpretation of McCLIM's LGPL license would mean that it should ship separately from a binary)...
2:35:15
aeth
...but what does it take to become a McCLIM backend? Because I suspect that there would be interest there.
2:37:47
pjb
With files with more than 1-bit bytes, you can reserve a header and update it to contain the total bit length header, or just the bit-offset in the last byte. Using just the bit-offset would be easier, since it takes only one byte to write.
2:38:32
aeth
pjb: re "The idea of files as a sequence of bytes is a figment of the imagination of the POSIX standard." it seems like it's more than just POSIX
2:39:44
aeth
Even in CL you see either bytes or characters, which are usually UTF-8 translated into the internal format (probably UTF-32) unless there's some configurable encoding support.
2:42:03
aeth
pjb: Well, yes, I'm aware that there's a lie there, I think that's why you have to 'safely remove' external hard drives.
2:42:53
pjb
and again, if you read above, I wouldn't have to repeat that to write a byte to a disk you have to first read a fucking whole sector!
2:44:23
pjb
There's also the case of networks. Both serial and Ethernet are bit-based transmission protocols (level 2).
2:45:29
aeth
pjb: And I don't think you mentioned solid state drives yet, which are afaik extremely elaborate internally.
2:47:36
pjb
Usual hardware UART let you configure the number of data bits and mark bits, and the presence of parity bit, but really, they just transmit bits. When you program a GPIO on raspberry you can send the bits yourself.
2:48:56
pjb
Actually, if POSIX specifies files as sequences of bytes, it's only because it's inspired from unix which was written in C. If it had been written in Lisp, we'd have variable length bytes just as in CL read-byte and write-byte.
2:51:43
pjb
I can't wait the singularity. We'll be able to ask the AI to evole a whole field such as computing, starting from different premices…
3:04:21
aeth
This is why it would be safer to augment human intelligence instead of developing superhuman artificial intelligence from scratch. You know humans will want to benefit humans (or at least themselves)
3:05:05
aeth
In a sense, tools like SLIME already do that, but things will really take off once we get a more efficient brain-computer interface than keyboards.
9:34:47
beach
The 300€ I offered to extract the Cleavir environment code is no longer available. I have almost finished the work myself.
9:38:36
phoe
I know beach and jackdaniel have some, there is the current CCL one for PLNs, and I know stylewarning also has some posted.
9:40:08
beach
Not for what I am proposing. I don't want any old person to apply. Then I would have to deal with explaining to them that they are unqualified, with looking at their existing code, etc, etc.
9:40:46
beach
Oh, and I would like the applicant to have the desire to learn things. Not just make money.
9:56:29
no-defun-allowed
There are libre software funding pages, a lisp presence on some would be interesting.
9:57:02
no-defun-allowed
Also, I have a very small bounty since websocket implementing is not the best use of my time.
9:58:32
no-defun-allowed
Such a client should have methods for reading and writing events, but the client only should pass data events to the user and raise conditions for disconnects.
9:58:34
beach
Posterdati: Maybe you don't know what "bounties" are. They are not employments. Just small amounts of money for specific tasks.
9:59:29
no-defun-allowed
Also, admittedly, I don't know if PayPal will let me use the $3.80 as I don't have a credit card. I think it should, hopefully.
10:01:39
beach
no-defun-allowed: That is a very small amount of money. I doubt you will have any takers.
10:03:31
no-defun-allowed
I do have a rough prototype for a websocket client like I describe, but most of the required features are missing.
10:04:38
beach
Posterdati: In the case of McCLIM, we get regular (monthly?) support from a bunch of contributors.
10:04:41
Posterdati
no-defun-allowed: why don't you read the UNIX Networking Programming manual and Network Programming in ANSI Common Lisp with IOLib?
10:05:21
Posterdati
beach: I see, I'm looking at the site you posted, I'm interested in usign McCLIM
10:05:40
no-defun-allowed
Cause I retch at seeing Unix documentation and streams are much more natural for CL.
10:07:16
Posterdati
no-defun-allowed: I did a client/server using iolib, not easy, but not impossible!
10:07:21
no-defun-allowed
Also, again, the less CFFI, the better. I'm sorry, but it'd give me more shit to maintain and deploy.
10:07:51
no-defun-allowed
CFFI won't work too well on Heroku, and I want to avoid it for everything other than SSL.
10:08:13
Posterdati
no-defun-allowed: since you have to use system libs I do not understand the CFFI problem...
10:09:37
no-defun-allowed
The only C library I want to pull in is SSL, since that's definitely going to be present, everything else is more work.
10:11:04
no-defun-allowed
Additionally, more C means more things that go wrong that I can't gracefully recover from. I'm terrible at prototyping and I've killed a few images from being stupid with CFFI.
10:13:33
no-defun-allowed
Yeah, I have to spawn two threads instead of one to get cl-decentralise talking to it too.
10:14:01
no-defun-allowed
But I suppose the synchronous requirement can be worked with, it's easy to hack on to the other.
10:14:31
no-defun-allowed
There was some kind of fast-io which used static vectors which used CFFI, which I can't disable.
10:16:02
no-defun-allowed
Maybe I need to update the buildpack, since there is an issue with a uiop macro from what I remember.
10:16:24
no-defun-allowed
>i got a very, very weird error using websocket-driver on heroku: https://pastebin.com/4XjhbYQ4
10:18:45
no-defun-allowed
Would that come with sbcl? I think asdf did and they're fairly related libraries.
10:20:25
no-defun-allowed
I don't know, honestly. Heroku does not let you get at a remote repl too easily.
10:21:20
phoe
Though by now I expect it to ship ASDF2 which is ancient as well and many modern libraries refuse to run on it.,
10:26:38
no-defun-allowed
I suppose the SBCL developers have forgotten to add the finewine(tm) program longevity improving libraries.
10:35:23
phoe
So, not SBCL's fault either. Complain to CFFI maintainers that they dropped support for earlier UIOP versions.