dsthilaire [Lexaloffle Blog Feed]https://www.lexaloffle.com/bbs/?uid=51115 Floating point format <p>Hi! I was wondering if there is a way to format floats when printing them out like you would to with the good old <code>printf(&quot;%2f&quot;, float{2});</code> in c++.</p> <p>Thanks!</p> https://www.lexaloffle.com/bbs/?tid=141430 https://www.lexaloffle.com/bbs/?tid=141430 Thu, 04 Apr 2024 01:24:12 UTC Undocumented features list? <p>Hi! </p> <p>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...</p> <p>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> <p>Thanks!</p> https://www.lexaloffle.com/bbs/?tid=47445 https://www.lexaloffle.com/bbs/?tid=47445 Tue, 19 Apr 2022 12:12:56 UTC Sprite Rotation <p> <table><tr><td> <a href="/bbs/?pid=87828#p"> <img src="/bbs/thumbs/pico8_rotate_sprite-0.png" style="height:256px"></a> </td><td width=10></td><td valign=top> <a href="/bbs/?pid=87828#p"> rotate_sprite</a><br><br> by <a href="/bbs/?uid=51115"> dsthilaire</a> <br><br><br> <a href="/bbs/?pid=87828#p"> [Click to Play]</a> </td></tr></table> </p> <p>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 :)</p> <p>I hope this can be useful to someone else too! Happy coding!</p> https://www.lexaloffle.com/bbs/?tid=41632 https://www.lexaloffle.com/bbs/?tid=41632 Thu, 18 Feb 2021 04:06:30 UTC RealTime Rendering <p> <table><tr><td> <a href="/bbs/?pid=87494#p"> <img src="/bbs/thumbs/pico8_realtime_render-1.png" style="height:256px"></a> </td><td width=10></td><td valign=top> <a href="/bbs/?pid=87494#p"> realtime_render</a><br><br> by <a href="/bbs/?uid=51115"> dsthilaire</a> <br><br><br> <a href="/bbs/?pid=87494#p"> [Click to Play]</a> </td></tr></table> </p> <p>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.</p> <p>Tell me what you think or if you have any optimization suggestions! :)</p> <p>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.</p> <p>Cheers!</p> <p>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 &quot;cornell box&quot; <a href="https://www.lexaloffle.com/bbs/?uid=25532"> @freds72</a>. The performances are now realtime, for real! :p</p> https://www.lexaloffle.com/bbs/?tid=41510 https://www.lexaloffle.com/bbs/?tid=41510 Thu, 11 Feb 2021 03:16:13 UTC