Log In  
Sprite Rotation
by dsthilaire
RealTime Rendering
by dsthilaire
:: Unfold ::


I was wondering if there is an un-official features manual lying around somewhere. It seems like each release of pico 8 brings it's lots of new undocumented features and it's really hard to keep track when you don't use pico8 for some time...

So I was just hoping to have a manual extension lying around somewhere telling us about those and all the memory peek switches and such... Does it exists?


P#110474 2022-04-19 12:12

:: Unfold ::

Cart #rotate_sprite-0 | 2021-02-18 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA

I started working on a new project and was wondering how i could rotate sprites and came up with this. It's not very efficient but once the rotation is done, the rotated sprite is cached in the sprite sheet. Please use it with care :)

I hope this can be useful to someone else too! Happy coding!

P#87828 2021-02-18 04:06

:: Unfold ::

Cart #realtime_render-1 | 2021-02-15 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA

Hi! I've been working for the past two weeks in implementing a realtime rendering engine for pico-8. It really is just meant to be a tech demo. The performances when a lot of the screen pixels are filled are quite bad, but it works well if the objets are not too close to the camera :). I have simple directional lighting working at the moment and plan on adding more soon, starting with omni lights and spot lights.

Tell me what you think or if you have any optimization suggestions! :)

PS: I first started off as a usual rtr pipeline where all vertices were shaded, then used the vertex fragments into a rasterization pass, then processed the pixels fragments. The issue was that the memory cost for holding the pixel fragments was too great and the pico-8 would just run out of memory very quickly. By fully processing one triangle at a time, I ended up with much better cpu and mem performance.


edit: v1 Added render modes (triangle draw, pixel draw (old version), wiremesh. Also added point light support. The new triangle draw was inspired by other examples and the triangle draw method was borrowed from "cornell box" @freds72. The performances are now realtime, for real! :p

P#87494 2021-02-11 03:16 ( Edited 2021-02-15 03:45)

Follow Lexaloffle:          
Generated 2023-12-01 09:35:47 | 0.070s | Q:16