e

  • 0 Posts
  • 52 Comments
Joined 3 years ago
cake
Cake day: June 15th, 2023

help-circle
  • As an amateur computer graphics person, the best way to draw accurate stars is to just pre render it onto a cubemap. But if you really need that subpixel worth of parallax to be completely accurate for every star, there are a couple ways I can think of off of the top of my head. With any you’d want to make sure you only store position, size, and color, since stars are all spheres anyways. With effort, you can be very flexible with how these are stored. (4 bits color temperature, 4 bits size, 3*32 bits coordinates maybe)

    • splat each star into the screen texture with atomics
    • some sort of tiled software rasterization thing, like in Gaussian Splatting

    Worse ideas:

    • instanced hardware rasterization
    • ray tracing

    This is not that well suited to most usual rendering techniques, because most stars are probably going to be much smaller than a pixel. Ray tracing would mean you need to just hit every star by chance (or artificially increase star size and then deal with having tons of transparency), hardware rasterization is basically the same and additionally is inefficient with small triangles. I guess you could just live with only hitting stars by chance and throw TAA at it, there’s enough stars that it doesn’t matter if you miss some. That would react badly to parallax though and defeats the purpose of rendering every star in the first place.

    It’s much more efficient to do a manual splatting thing, where for each star you look at what pixel(s) it will be in. You can also group stars together to cull out of view stars more efficiently. Subpixel occlusion will be wrong, but it probably doesn’t matter.

    This is all just for the viewport, though. Presumably there are other objects in the game besides stars, which need to have reflections on them of the stars. Then that becomes an entirely different problem.

    The real answer though is that you wouldn’t try to render all of the stars, even if you want parallax. Maybe some of the closer and larger ones as actual geometry, simplify a ton of stuff in the background, render things as volumes or 2d billboards, have a cubemap for the far distance, etc

    Edit: also ofc this presumes you know the position, scale, temperature of every star

    I also like the idea of baking all of the stars into a volume in spherical coordinates, centered around the origin



  • Are there any alternatives that are decently fast for large files? My computer and my phone both get at least 300 mbps from the router, and I have yet to find a local file transfer application that will be anywhere near that fast for large files (destiny, local send, kde connect, might have tried others, I don’t remember)















  • AdrianTheFrog@lemmy.worldtoMemes@lemmy.mlRAM
    link
    fedilink
    English
    arrow-up
    8
    ·
    edit-2
    9 months ago

    I have a laptop with 4gb ram that i’ve been using kde plasma on and fairly frequently it just freezes or I have to restart because I had like 6 tabs open in firefox

    Although I don’t remember having that problem as much when I was on xfce, but I also might not have been using it as heavily then

    I’ve never had a similar problem with chrome on chromeos with the same amount of ram, I think chrome+chromeos might be more aggressive with unloading tabs

    Sometimes it does actually kill firefox but sometimes it just becomes very slow (1-2 seconds per frame) or freezes entirely for several minutes when out of memory. Might be just because the swap is really slow, but there’s just 2gb of that, why would it freeze for several minutes? (One time this was happening was when I was trying to compile llvm on two threads, I ended up having to temporarily kill the desktop environment to save ram)



  • I recently switched to Android. IPhones work great, the hardware is all there, the software is probably more polished, etc… but on Android you can get the phone to do basically anything with a bit of effort. There’s an app that lets you easily install most linux packages, and one that can emulate most Windows apps and games. There’s a ton of open source software, and you can actually find apps that don’t shove in-app purchases in your face (because devs don’t have to pay $100 a year just to stay on the store)

    I got PrusaSlicer to work on my phone, through the Windows emulator, and sliced one relatively complex 3D model with it. For some reason it crashed every time I tried to start it after that, but it’s still pretty neat that it worked at all. PrusaSlicer has a linux build for ARM so whenever I find the time to set up one of those linux desktops on my phone I’ll probably try that.


  • Fedora and Arch both work pretty well on 4gb. Plasma and Gnome were surprisingly decent, and xfce was great but a little uglier. Blender, FreeCad, Minecraft (with performance mods), Celeste, for example all worked perfectly fine, with maybe a few browser tabs in the background as well. You couldn’t do anything too heavy, but it was pretty usable (I was using it as a travel laptop mostly). I’d say 2gb is where it becomes too little to live with.