Elektrine lite

← Feed

Nikita Lisitsa

lisyarus@mastodon.gamedev.place

<p>He/him</p><p>I teach C++ &amp; computer graphics and make videogames</p><p>Working on a medieval village building game: <a href="https://youtube.com/playlist?list=PLSGI94QoFYJwGaieAkqw5_qfoupdppxHN&amp;cbrd=1" target="_blank" rel="nofollow noopener" translate="no"><span class="invisible">https://</span><span class="ellipsis">youtube.com/playlist?list=PLSG</span><span class="invisible">I94QoFYJwGaieAkqw5_qfoupdppxHN&amp;cbrd=1</span></a></p><p>Check out my cozy traffic simulator: <a href="https://store.steampowered.com/app/2403100/Costa_Verde_Transport_Department/" target="_blank" rel="nofollow noopener" translate="no"><span class="invisible">https://</span><span class="ellipsis">store.steampowered.com/app/240</span><span class="invisible">3100/Costa_Verde_Transport_Department/</span></a

Posts

  • Post #4174659

    TIL there&#39;s no unsigned 64-bit -&gt; floating-point 64-bit conversion in x86_64, so you have to build it up from other instructions. Here&#39;s the codegen by gcc-15.2 with -O3, it uses different code paths based on the highest bit of the input:

  • Post #4138314

    Currently the parser doesn&#39;t allow newlines before the opening curly brace {, which forces a certain formatting style. Not sure if I want to keep that or allow a different style, though... The first one looks nicer but the second one can be easier to read in more complex scenarios

  • Post #3256773

    New blog post! Kinda math-heavy this time, but I wanted to share about this weirdly fascinating things called quiver representations that generalize stuff from basic linear algebra to wild unsolvable problems 🀩 https://lisyarus.github.io/blog/posts/quivers-a-year-of-linear-algebra-by-drawing-arrows.html

  • Post #2098942

    You might remember that I was working on my own programming language a few months ago. I&#39;ve decided to write a blog post about what this language is, how it is implemented, and what are my future plans! #programming #pldev #compiler #arm64 https://lisyarus.github.io/blog/posts/making-your-own-programming-language.html

  • Post #2066565

    Experimenting with particle-based clouds driven by the wind velocity field. Particles use scaled boulder meshes for test. The plan is to splat these into a texture which will be used to generate the final mesh as before. #indiedev #gamedev #indiegames

  • Post #1983667

    New blog post! Tried making something interactive &amp;amp; fun this time :) It&amp;#39;s about my favourite animation trick I&amp;#39;ve been using for years. https://lisyarus.github.io/blog/programming/2023/02/21/exponential-smoothing.html

  • Post #1862369

    Just for fun, recorded a video travelling along one of the rivers from source to delta. Had to speed it up quite a lot, otherwise it was too long πŸ˜… #indiedev #gamedev #indiegames

  • Post #1862368

    River generation progress: fixed the &amp;quot;aqueducts&amp;quot; and weird mountain cutoffs, added occasional sand river banks. Still got a ton of issues to solve, though πŸ˜… #indiedev #gamedev #indiegames

  • Post #1862367

    Just a random screenshot, standing on a hill and looking at the shore and distant forests #indiedev #gamedev #indiegames

  • Post #1862365

    Oooph, fixed a bug in my wind field generation code, tweaked cloud density &amp;amp; spawning, and now they look and move soooo much better! 🀩 (this is sped up 256x, and I removed the day-night cycle for clarity; the video actually spans 14 in-game days) #indiedev #gamedev #indiegames

  • Post #1862364

    Having a flexible ECS engine underneath means I can debug clouds producing rain just by spawning rain &amp;quot;particles&amp;quot; (actually scaled &amp;amp; recolored boulders, lol) #indiedev #gamedev #indiegames

  • Post #1844344

    Improved river height interpolation using cubic splines, fixed some weirdness on river banks &amp;amp; deltas. Still hunting a few remaining discontinuities... #indiedev #gamedev #indiegames

  • Post #1669629

    Fun world generation: a river almost made a full circle, enclosing a hex-shaped forest patch 🀯 #indiedev #gamedev #indiegames #screenshotsaturday

  • Post #1488086

    By popular demand, figured how to properly put the sandy river banks (aka point bars) on the correct (inward) side of the river! Now the meandering looks even more realistic with no actual simulation 😎 #indiedev #gamedev #indiegames

  • Post #1438054

    This algorithm seems to be able to create insane meandering patterns with rivers stretching across the whole island, that&amp;#39;s so cool #indiedev #gamedev #indiegames #screenshotsaturday

  • Post #1170474

    New blog post! I really hope I&amp;#39;ll get a decent amount of people mad with this one 😈😈😈 It&amp;#39;s OK to compare floating-points for equality: https://lisyarus.github.io/blog/posts/its-ok-to-compare-floating-points-for-equality.html #programming #computing #floatingpoint #geometry

  • Post #1100869

    So my &amp;quot;take random vector field and solve Poisson eqn to make it div-free&amp;quot; is really dumb - I can instead just take a noise function and take its 2D curl: it&amp;#39;s div-free and looks much nicer! Just need to tweak a bit, humidity levels are way off rn #indiedev #gamedev #indiegames

  • Post #966028

    So, I&amp;#39;ve made a multi-threaded Monte-Carlo raytracer with diffuse, metallic, and transparent materials... ...in my own programming language πŸ€ͺ It&amp;#39;s all fairly basic (no BVH or MIS, the compiler is arm64 only &amp;amp; doesn&amp;#39;t optimize anything), but I&amp;#39;d still call it a huge success!

  • Post #883925

    Current state: writing a Monte-Carlo raytracer in my toy programming language. Fixed ~15 compiler bugs, introduced a few new features, faced function stack size limit (4Kb, larger needs special care due to arm64 weirdness), but still can&amp;#39;t figure out why this box is black 😭

  • Post #820220

    I think I&amp;#39;ve finished the first version of this thing! 🀩 Meet πŸ”·PolyhedriaπŸ”·: a tiny in-browser sandbox that allows you to build funny stuff by joining together various (mostly-)uniform polyhedra! https://lisyarus.github.io/webgl/polyhedria/

  • Post #777523

    Rewriting my toy language aarch64 compiler using the new IR as an input. The compiler code decreased in half (1.5k -&amp;gt; 700 loc), and its logic got way simpler. Still not an optimizing compiler, though, and lacking structs, arrays &amp;amp; pointers πŸ˜… Left: test program Right: IR output

  • Post #777522

    I have the first proper UB in my toy language 🀩 Knowing the stack layout, using pointer manipulation I can change the value of an immutable variable 🀩 (yes, pointer arithmetic works with byte offsets rn, will fix that soon)

  • Post #777521

    Since I have pointers in my toy language compiler, I can finally do some file i/o through C FFI! Even with some nice wrappers and basic type safety 🀩 The plan is to implement structs and then write a blog post about how all this works. Would also be fun to try it on e.g. some project euler tasks!

  • Post #572748

    Pretty sure you really wanted to see all the 14 uniform polyhedra with only regular 3, 4, 6 or 8-gons as faces today

  • Post #446451

    Aaaaalmost finished with the water stuff. Right now debugging why frustum culling, while working perfectly for the terrain chunks, fails for the water chunks... #indiedev #gamedev #indiegames

  • Post #369901

    So I&amp;#39;ve finished a huge refactoring and everything works exactly as it did before and everything looks completely normal #indiedev #gamedev #indiegames

  • Post #369900

    I&amp;#39;m trying something with the entities rendering and somehow I messed things up really bad and now random objects get random textures which creates these cornflower ghosts #indiedev #gamedev #indiegames

  • Post #369899

    I&amp;#39;ve &amp;quot;optimized&amp;quot; my entity rendering to batch instances of the same mesh (still using just one multi-draw-indirect call), going from ~17k to just 115 draw commands for this shot. Somehow it gains 0.2ms without shadow maps but loses 7ms with shadows enabled πŸ₯²

  • Post #369898

    So by manually poking around I&amp;#39;ve found that disabling texture read (needed for discard alpha testing) in shadow passes makes them about 50-75% faster. Making all draw calls read the same texcoord also works, though the gains are smaller. Am I actually texture bandwidth bound? 😭

  • Post #298502

    Oh no how will I survive without the extremely valuable opinion of *checks notes* one of the most deranged crackpots on the planet Anyway...