[1/2] Here is a demo of a simple, completely unoptimized terminal renderer I wrote over a few days. Supports scrollback, line wrapping, Unicode combining, RTL-over-LTR, multicolor fonts, changing fonts on the fly, etc. It runs at several thousand FPS.https://youtu.be/hxM8QmyZXtg
-
Show this thread
-
Replying to @cmuratori
I have to do stdout in its own thread in my game engine cause it like fucking 5x my game's loading time if I output the handful of debug messages I print on the main thread instead. it's truly ridiculous
2 replies 0 retweets 23 likes -
Replying to @TylerGlaiel @cmuratori
In a similar story, I've had debug output to the windows console break online multiplayer in a game I'm making because it would slow down so much it would mess up the packet timings. Granted, the protocol should handle that, but it always worked perfectly fine on Linux.
1 reply 0 retweets 0 likes -
Replying to @boigahs @TylerGlaiel
Possible pro-tip from my recent discoveries in refterm in collaboration with
@mmozeiko: have you tried setting the mode of the stream to binary? _setmode(fileno(stdout), _O_BINARY);1 reply 1 retweet 5 likes -
Replying to @cmuratori @boigahs and
Because as I started to do profiling on refterm I noticed some very strange behavior of conhost, and
@mmozeiko looked into it and found that text-mode CR/LF translation resulted in different write patterns that slow conhost down dramatically.2 replies 0 retweets 3 likes -
I just assumed it was the glyph rendering that was taking time like the console wasn't threaded and would render immediately after putting a newline on it or something. everything goes through my threaded console class right now which works and I don't want to change it
1 reply 0 retweets 0 likes -
That may also be the case. Both things are slow, so it depends which are slowing you down :)
1 reply 0 retweets 1 like -
yeah I mean I'm doing puts and not printf, under the impression that puts is about as fast as you could be there. threaded console does a shitload of dumb std::string concats for debug messages and then slaps them in a nonblocking queue, dumb as possible, but its still instant
2 replies 0 retweets 0 likes -
Replying to @TylerGlaiel @cmuratori and
i should see what happens if I print them to my in game console instead of std::out and just see how fast it is in comparison (my in-game text stuff is absolutely not optimized for that case, but its probably still *significantly* faster)
1 reply 0 retweets 2 likes
Well as the refterm testing showed, it is fairly straightforward to get 100x speed improvement over Windows Terminal even with unoptimized code, and Windows Terminal is faster than the cmd.exe built-in to Windows...
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.