Pokitto is on the way, what games should I make?


#442

I have some basic, not yet finished triangle rasterization, using a sligh modification of Bresenham line algorithm, so that I can keep everything integer only. This is SDL for now:

image

What you see may remind you of any OpenGL 101 tutorial, because these colored triangles are the very basics of any realtime 3D engine. The colors gradually blending indicate one important concept: interpolation by Barycentric coordinates. In OpenGL (and Direct3D and eventually my library as well) you can assign any number of values to each vertex – these can be a color (as seen here) or a texture coordinate, or transparency, or anything – in the rendering pipeline these are then automatically smoothly interpolated for each pixel inside the triangle – hence the smooth transitions. Pretty elegant design.

Eventually this interpolation will have to also take into account the Z coordinate for the perspective correction. This final equation is quite complex and is what I fear for the performance, since it’s a per-pixel operation. Anyway, I simply have to try and see if it’s possible to run on some reasonable FPS. I believe there are optimizations hiding around somewhere – most likely a lot of stuff will be precomputable at the start of rendering of each triangle, to relieve the upcoming per-pixel operations.


#443

textured triangle on Pokitto:

out

EDIT: library sauce


#444

Testing perspective, so far with no rotations.

out


#445

It’s only a matter of matrix after that :smiley: great work


#446

Now with rotation :slight_smile:

out

Yep, this is without matrices so far, but I think it’s time to put them in for efficiency.


#447

Possible pokitto Star Fox clone :heart:?


#448

Would be lovely to have one of those oldschool cartoony low-poly games, like Crash Bandicoot or Spyro.


#449

We should have something more that just :heart: when we like something so spectacular.


#450

:heart::heart::heart: ? Agreed. Some Kind of Kudo Stars would be appropriate


#451

I now have matrix transforms in place, all working great. Now I’ll move to visibility determination – my idea is to have a number of drawing strategies to choose from, possibly separate for drawing a model (overlapping triangles) and drawing the scene (overlapping models). So, you can for example say:

  • Draw everything using depth-buffer (good for PC with a lot of memory).
  • Draw everything with painter’s algorithm – i.e. from back to front (good when you’re short on memory, but potentially more intense on CPU and inaccurate).
  • Draw my model triangles in any order (good if you know triangles can’t overlap, e.g. for a sphere, supposing backface culling), and models from front to back with stencil buffer (a mid-ground between previous two approaches – stencil buffer is a lot smaller and front to back drawing doesn’t waste time by computing pixels that can be overwritten – but this can still be inaccurate and requires sorting).

#452

Meanwhile let me also throw this idea here:

ScummVM allows to play many old adventures and is extremely portable:

Windows, Linux, Mac OS X, Dreamcast, PocketPC, PalmOS, AmigaOS, BeOS, OS/2, PSP, PS2, SymbianOS and many more…

Anyone thought of porting it?


#453

I would love to see that ported over… But the resolution might be an issue maybe?


#454

Most probably:

Most games supported by ScummVM were designed to be played at a screen resolution of 320x200 using rectangular pixels (higher than they were wide)


#455

Yeah :confused: We’d need a 1/3 scaledown. What if each third column is interlaced vertically with the next one? I wonder what that would look like.

EDIT:

left: interlace, right: just drop the columns


#456

That could work…


#457

I understand SCUMM needs a fair bit of memory


#458

That may be possible, I haven’t been looking at these requirements. Will do.

EDIT:

There’s a backend for limited-resource devices also offering downscalers and virtual keyboard. Still the lowest specs devices I’ve seen (old symbian S60 phones, looked only briefly though) have at least megabytes of RAM, so it may be out of question :confused:


#459

I would still be happy with a Zork Trilogy with your PokiPad :wink:


#460

until the ram expansion hat arrives cheeky :smiling_imp:


#461

Is this a real thing that’s happening???