summaryrefslogtreecommitdiff
path: root/camera.c
Commit message (Collapse)AuthorAgeFilesLines
* implement clipped drawing. take branching out of the upscaler loop.rodri2024-09-201-0/+1
| | | | | | the rasterizers now produce a bbox of used fragments/pixels that are unified at the end of every job/frame. we use that when drawing so only the part that was rasterized gets sent to devdraw.
* turn the camera rendering options into a bitmap.rodri2024-09-131-1/+1
|
* change the raster format to RGBA32. draw to any image format. clean up.rodri2024-09-111-1/+1
| | | | | | | | | | | | | | | | got rid of the bullshit dance between XRGB32 and RGBA32, now all rasters are RGBA32 and premultiply alpha before loading up an image and drawing over the destination. this lets the user compose their own scenes with correct transparency. no more mediocre clearcolor. as a consequence drawing got slower, but if i get the turbo drawing pool working properly that should go away. textures also take alpha pre-multiplied channels into account, dividing them when sampling, so loading transparent textures will show the correct colors.
* allocate renderjob times dynamically for the parallel stages.rodri2024-09-081-2/+2
|
* remove unnecessary copying. profile individual stage procs.rodri2024-09-071-14/+26
|
* unify shaders into a single interface.rodri2024-09-011-3/+3
|
* methods to add primitives and materials to a Model.rodri2024-08-231-3/+2
|
* unify drawing routines and add clipped fb drawing support.rodri2024-08-171-0/+4
| | | | | | now changing the viewport offset will correctly show the portion of the framebuffer that's visible, including support for upscaled views.
* fix FPINVAL error. knob for fb clear color. general improvements.rodri2024-08-111-3/+6
|
* experimental A-buffer implementation.rodri2024-08-101-0/+1
| | | | | | | | | very simple, without anti-aliasing, made for getting OIT (order independent transparency) rendering of arbitrary objects. also added switches for blending, depth testing and the A-buffer to the camera.
* reduce the volume of Camera.times records. clean up.rodri2024-07-201-0/+1
|
* fix stack overflow, skybox fov sensibility and scene duplication.rodri2024-07-151-7/+8
| | | | | | | | | putting the duplicate camera in a local variable turned out to be a bad idea. bring the dynamic version back. the skybox rendering was affected by the camera fov, which made it look like it was not really at infinity, so set it always to 90°.
* small improvements and a skybox bugfix.rodri2024-07-141-16/+13
|
* new camera interface.rodri2024-07-131-18/+65
|
* fix the geometry glitches when moving things around.rodri2024-07-131-28/+39
| | | | | | | | | | it's possible for interactive programs to keep updating the geometry of the scene during rendering, which caused primitives to look deformed or shattered in the final image. to avoid this we take a snapshot of the current state of things (scene and camera), and render based on that copy.
* texture nomenclature changes. fb format RGBA → XRGB.rodri2024-07-091-1/+1
| | | | | | we are still doing alpha blending, so we use the X chan internally, but we don't care about it when (mem)drawing to the screen.
* add cubemaps.rodri2024-06-061-1/+88
|
* render: add rasterizer init params and per-proc identification.rodri2024-04-241-2/+2
|
* add some instrumentation to measure pipeline stage time.rodri2024-04-151-0/+11
|
* simplify the job scheduler. correct two mistakes regarding the Viewport.rodri2024-04-051-1/+3
| | | | | | | | | | > They made two mistakes. they hanged the wrong man and they didn't finish the job. so Clint Eastwood came back to kick my ass. the mistakes in question were that the Viewport shouldn't know about double buffering, conceptually it has a framebuffer and that's it. the second one was passing it to the renderer, when the renderer couldn't care less about what a viewport is.
* pass a Viewport in the Renderjob instead of a fb.rodri2024-03-261-3/+1
| | | | | do the frame buffer clearing and swapping as part of the rendering process, not within shootcamera.
* implement a (partially) concurrent pipeline.rodri2024-03-251-2/+14
|
* use the new libgeometry berp routines. add a frame counter to the camstats.rodri2024-03-211-0/+1
|
* lay out the grounds for a scene renderer.rodri2024-02-131-3/+2
| | | | | | also fixed an issue with cliptriangle() where an entire tri would get discarded if all its vertices were outside the frustum.
* document part of the pipeline. prepare the grounds for triangle clipping.rodri2024-02-031-4/+1
|
* improve coordinate transformations and fix projections.rodri2024-01-311-5/+0
| | | | | also got rid of Deco. there's no point in having that, just deal with image(6) files.
* make the vertex shader process actual vertices.rodri2024-01-301-0/+1
|
* import the new renderer and clean things up.rodri2024-01-301-17/+40
| | | | | | | | | | | | i integrated the renderer i've been developing on the tinyrend repo and got rid of a bunch of stuff that's no longer necessary. also began structuring things to fit the new interface i have in mind. there are still some artifacts with the projection xforms that cause issues with clipping and division by zero.
* bring flat triangle rasterization back, with some goodies for future shading ↵rodri2020-06-291-1/+1
| | | | work. add uv coordinates to the vertex.
* standalone version release.rodri2020-04-171-0/+77