From c9a54e8bc3635716b221f921f0d025d02d78b684 Mon Sep 17 00:00:00 2001 From: Svjatoslav Agejenko Date: Wed, 29 Jan 2020 21:31:11 +0200 Subject: [PATCH] Updated document structure. --- doc/index.html | 22 ++++++++++++++-------- doc/index.org | 43 +++++++++++++++++++++---------------------- 2 files changed, 35 insertions(+), 30 deletions(-) diff --git a/doc/index.html b/doc/index.html index 21d631d..1adfdd5 100644 --- a/doc/index.html +++ b/doc/index.html @@ -2,7 +2,7 @@ Sixth 3D - 3D engine - + @@ -201,7 +201,7 @@ $(function() {

1 General

+
+
+

5.1 Render only visible polygons

+
  • This would significantly reduce RAM <-> CPU traffic.
  • @@ -477,8 +480,7 @@ becomes visible.
- - +
diff --git a/doc/index.org b/doc/index.org index fd1a856..dddde5a 100644 --- a/doc/index.org +++ b/doc/index.org @@ -11,7 +11,7 @@ #+HTML_HEAD: * General -- This is a subproject of [[https://www3.svjatoslav.eu/projects/sixth/][Sixth]] +- This is a subproject of parent project: [[https://www3.svjatoslav.eu/projects/sixth/][Sixth]]. - This program is free software: you can redistribute it and/or modify it under the terms of the [[https://www.gnu.org/licenses/lgpl.html][GNU Lesser General Public License]] as @@ -136,30 +136,29 @@ For API usage examples, see [[https://www3.svjatoslav.eu/projects/sixth-3d-demos + Antialiazing. Would improve text readability. If antialiazing is too expensive for every frame, it could be used only for last frame before animations become still and waiting for user input starts. +** Render only visible polygons ++ This would significantly reduce RAM <-> CPU traffic. -+ Render only visible polygons. - + This would significantly reduce RAM <-> CPU traffic. ++ General algorithm description: + + For each horizontal scanline: + + sort polygon edges from left to right + + while iterating and drawing pixels over screen X axis (left to + right) track next appearing/disappearing polygons. + + For each polygon edge update Z sorted active polygons list. + + Only draw pixel from the top-most polygon. + + Only if polygon area is transparent/half-transparent add + colors from the polygons below. - + General algorithm description: - + For each horizontal scanline: - + sort polygon edges from left to right - + while iterating and drawing pixels over screen X axis (left to - right) track next appearing/disappearing polygons. - + For each polygon edge update Z sorted active polygons list. - + Only draw pixel from the top-most polygon. - + Only if polygon area is transparent/half-transparent add - colors from the polygons below. ++ As a bonus, this would allow to track which polygons are really + visible in the final scene for each frame. - + As a bonus, this would allow to track which polygons are really - visible in the final scene for each frame. + + Such information allows further optimizations: - + Such information allows further optimizations: + + Dynamic geometry simplification: + + Dynamically detect and replace invisible objects from the + scene with simplified bounding box. - + Dynamic geometry simplification: - + Dynamically detect and replace invisible objects from the - scene with simplified bounding box. + + Dynamically replace boudnig box with actual object once it + becomes visible. - + Dynamically replace boudnig box with actual object once it - becomes visible. - - + Dynamically unload unused textures from RAM. + + Dynamically unload unused textures from RAM. -- 2.20.1