mirror of
https://git.coom.tech/drummyfish/small3dlib.git
synced 2024-11-26 21:30:17 +01:00
82 lines
2.5 KiB
Text
82 lines
2.5 KiB
Text
features:
|
|
|
|
- presets that can be optionally selected and will configure other constants
|
|
(e.g. a "low memory sort strategy" will turn z-buffer off and turn
|
|
back-to-front sorting on).
|
|
|
|
- Helper functions for e.g. retrieving and caching UV coords etc. Maybe these
|
|
should be in a separate file?
|
|
|
|
- function for computing normals and lighting
|
|
|
|
- triangle sorting:
|
|
- back-to-front (slower, better memory efficiency) DONE
|
|
- front-to-back (faster, but needs 1bit stencil buffer) DONE
|
|
|
|
- function to set/clear stencil buffer -- can be useful
|
|
|
|
- function to map one point in 3D space to screen, along with size (for mapping
|
|
billboards/sprites etc.) DONE
|
|
|
|
- Optimize persp. correction!
|
|
|
|
- Create and use the same function for determining CW/CCW AND left/right vertex
|
|
determination in triangle drawing.
|
|
|
|
- Check (and possibly fix) if any barycentric coord ever exceeds the range
|
|
<0,255> due to rounding errors etc.
|
|
|
|
- dithered barycentric interpolation function that is faster than normal
|
|
interpolation -- it will randomly picky one of three values, with greater
|
|
probabilities at greater coords
|
|
|
|
- option to disable baycentric coordinates computing DONE
|
|
|
|
- Z-buffer:
|
|
- full DONE
|
|
- reduced (resolution and precision) DONE
|
|
- more reduced (4-bit)
|
|
|
|
- MipMapping? Add triangle size to pixelInfo. DONE
|
|
|
|
- perspective correction modes:
|
|
- none DONE
|
|
- full DONE
|
|
- approximate DONE
|
|
|
|
- predefined 3D shapes:
|
|
- cube DONE
|
|
- sphere
|
|
- cylinder
|
|
- pyramid
|
|
- plane
|
|
|
|
- Depth computation during rasterization -- this should be an optional thing,
|
|
specified with a define (S3L_COMPUTE_DEPTH), which may be turned on
|
|
automatically for some modes (e.g. Z-buffer). It should be computed by the
|
|
fast lerp and passed in the PixelInfo struct. DONE
|
|
|
|
- Python tool to convert obj to C array DONE
|
|
|
|
- Python tool to convert texture images to C array DONE
|
|
|
|
- create demos:
|
|
- model viewer DONE
|
|
- game-like demo (GTA-style, Quake style etc.)
|
|
- offline HQ (lerp texuring, normal mapping, reflections, ...) rendering
|
|
to PPM image file
|
|
|
|
- drawModel: create an option that would use a cache to not transform the same
|
|
point twice
|
|
|
|
- Optional rendering stats (FPS, rendered triangles, ...).
|
|
|
|
- profiling functions for optimization
|
|
|
|
bugs:
|
|
|
|
repeated:
|
|
|
|
- valgrind (and similar) checks
|
|
- optimize
|
|
- write tests/benchmarks
|