Commit Graph

64 Commits

Author SHA1 Message Date
e7ebe1e243 Update dqn lib 2017-06-24 15:33:18 +10:00
54c6abd9d7 Update dqn with CPP api for memstacks 2017-06-23 19:03:36 +10:00
26e6892d64 Fix some dqn platform compile problems 2017-06-20 22:22:39 +10:00
08b2832436 Fix minor bugs in dqn 2017-06-20 19:36:58 +10:00
e1545c7977 Update DQN with work queue and minor changes 2017-06-20 18:37:35 +10:00
eeb773747a Improve assert with variadic macro for user msg 2017-06-20 15:31:44 +10:00
5397cdd9b9 Better assert(), move some Win32 functions to DQN
Asserts are now more defensive and diagnostic. Initially asserts provide a hard
break in the program, and the intention is to disable asserts for release.
Having experienced bugs in release mode due to optimisations with asserts off
there's little protection against errors that occur in release mode since all
asserts are off.

Now asserts can be used in release mode whilst still evaluating the expression,
and allowing user messages/diagnostics to console.
2017-06-20 02:13:03 +10:00
e860145e77 Lock pixels for multithread more granularly level 2017-06-19 18:22:02 +10:00
e660281211 Fix multithread bug causing invalid ptr references
Mesh rendering was not waiting until all jobs were complete before moving on
causing longer jobs to use old pointer references once the next frame started
rendering.
2017-06-19 14:14:13 +10:00
630522f8a3 Start multithreading mesh render 2017-06-18 23:07:49 +10:00
079e19b58b Make threading work queue platform abstracted 2017-06-18 20:25:57 +10:00
5a6564fa94 Start creating multithreading work queue 2017-06-17 22:25:29 +10:00
64fb913239 Add auto scoped memory regions 2017-06-17 17:57:06 +10:00
35bdbb65de Platform ability to query system (logical) cores 2017-06-17 16:20:35 +10:00
92953e9d7c Add documentation 2017-06-09 18:24:37 +10:00
58061786ff Cleanup and better parameterise mesh function args 2017-06-09 15:55:58 +10:00
d9f50d4581 Fix gaps on rendered mesh during rotation
Gaps caused by mistakenly calculating the transformation matrix per face loaded
in causing the matrix to continually update rotation prematurely.
2017-06-08 22:38:29 +10:00
285d3d2681 Add gouraud shading, can choose lighting options 2017-06-08 21:46:03 +10:00
ee31383906 Start moving model around in 3d space 2017-06-08 01:18:55 +10:00
4c5f8d43a0 Merge textured/non-textured tri rendering to one 2017-06-02 18:23:15 +10:00
e4913e5242 Merge triangle to textured triangle path 2017-06-02 14:12:50 +10:00
68616f3a8b Reorganise non/SIMD triangle rendering code 2017-06-02 02:45:37 +10:00
1c1ee6b5e3 Add better debug cycle diagnostics API 2017-06-01 21:07:44 +10:00
9b4072f5bc Start separating inline SIMD to own functions 2017-06-01 18:52:50 +10:00
6bcdb6d1fb Reorganise SIMD paths to reuse abit more code 2017-05-31 20:57:11 +10:00
47d606e297 Make tri rasterisation into SIMD/non-SIMD paths 2017-05-31 16:40:13 +10:00
bb5fc03bda SetPixel accelerated with SIMD 2017-05-30 18:46:04 +10:00
c1a5b41442 Process color with SIMD for textured triangle 2017-05-30 18:07:01 +10:00
49270a2826 Accelerate textured triangle rendering using SIMD 2017-05-30 17:41:05 +10:00
4d2a7a7c06 Improve allocation compactness and add DTRMesh 2017-05-26 22:25:09 +10:00
254d80749b Draft impl. of malloc to memstack for obj loading 2017-05-26 18:33:13 +10:00
96ac39724d Add asset array memory api stubs 2017-05-26 13:31:01 +10:00
f89b3ff706 STBImage now allocates from our memory 2017-05-26 02:39:16 +10:00
3874526a79 Reorganise asset files 2017-05-26 01:12:39 +10:00
4eb54c09b1 Fix zbuffer bug clipping at poly's behind 0, 0
Mistakenly use FLT_MIN as the largest negative number possible, where we should
be using -FLT_MAX.
2017-05-25 22:22:47 +10:00
a03de5de80 Start zbuffering pass of pixels for triangles 2017-05-24 00:04:18 +10:00
d42d6ef5bf Prepare triangle rendering for zbuffer support 2017-05-23 22:42:54 +10:00
e922efb897 Add temp fix for model gaps in tri rasterisation 2017-05-23 18:23:31 +10:00
237e73253a Fix incorrect indexing into vertex array for model
Wavefront model obj format indexes starting from 1, offset during load by -1 to
make all indexes be 0 based.
2017-05-22 20:54:34 +10:00
2c745d3571 Rename membuffer to memstack 2017-05-22 18:34:10 +10:00
8ce4221ad2 Minimal viable wavefront object parser completed 2017-05-22 15:54:44 +10:00
ce539d4903 Start parser for Wavefront 3D Object file format 2017-05-20 22:56:57 +10:00
a25b50c501 Fix color modulation alpha bug
Phasing color modulation over time would make bitmaps become transparent and
show layers underneath even if alpha was set to 1. This was caused by the
precomputed 1/255 calculation #defined in DTRRender which was missing the
precision required so floating point errors began to accumulate causing
erroneous colours.
2017-05-19 20:45:18 +10:00
b6daf43f33 Add profiling support using easy_profiler 2017-05-19 17:10:04 +10:00
1d0e9b8a07 All render paths go through srgb->linear pipeline 2017-05-19 02:21:44 +10:00
f040c377e9 Add gamma correction with SRGB<->Linear converting 2017-05-18 21:33:39 +10:00
e2ac14ffb7 Add bilinear filtering for bitmaps 2017-05-17 19:34:26 +10:00
ceb37ec4b0 Add proper bitmap rotation and 1:1 texture mapping 2017-05-17 16:18:03 +10:00
ce69de7aeb Add mem diagnostics, prepare for bitmap rotation 2017-05-17 02:49:33 +10:00
13860e4089 Organise functions to files 2017-05-16 22:53:28 +10:00