-
Notifications
You must be signed in to change notification settings - Fork 13
CAD DTM Rendering #186
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
Erfan-Ahmadi
wants to merge
169
commits into
master
Choose a base branch
from
dtm
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
CAD DTM Rendering #186
Changes from 8 commits
Commits
Show all changes
169 commits
Select commit
Hold shift + click to select a range
f098335
DTM setup
Przemog1 8058cff
Simple triangle draw
Przemog1 03faeed
Merge branch 'master' of github.com:Devsh-Graphics-Programming/Nabla-…
Przemog1 2b07a42
Barycentrics
Przemog1 0232ee8
Drawing triangle sdf
Przemog1 83d8de4
Added dtmSettingsBuff
Przemog1 d4647d5
Added `finalizeDTMSettingsCopiesToGPU` function
Przemog1 16951a3
Stippled outline
Przemog1 a215f45
Contour drawing setup
Przemog1 8900f9c
Implemented height shading
Przemog1 5a87097
Fixes
Przemog1 3237e4b
Implemented transparent height shading
Przemog1 78c716c
Fixes
Przemog1 10791e9
Implemented anty aliasing between height shading sections
Przemog1 1d9e6d0
switch from dtm to good'ol linework
Erfan-Ahmadi ad43e20
[WIP] putting all data into a single buffer and addressing with BDA
Erfan-Ahmadi cf63282
[WIP] save work
Erfan-Ahmadi d776d24
[WIP] add getMinimumRequiredResourcesBufferSize function, still not c…
Erfan-Ahmadi 4dc28d5
[WIP] more drawResource auto-submission logic fixes
Erfan-Ahmadi 2abd6b9
compiles but probably has runtime errors
Erfan-Ahmadi ab8f303
[62.CAD] compile error fix
Erfan-Ahmadi 8f2ae9c
small shader fixes
Erfan-Ahmadi 97b1693
more fixes
Erfan-Ahmadi 7636062
fixes to cad example
Erfan-Ahmadi eec41cb
fixed hatches and polyline connector's auto submission logic
Erfan-Ahmadi 692df5f
fix glyph and image auto-submission logic
Erfan-Ahmadi cf05dca
Fix ClipProjectionIndices reset
Erfan-Ahmadi 3304cde
auto-submission more mature, corrects resource references on the go b…
Erfan-Ahmadi e7b63ee
small fix
Erfan-Ahmadi 468dab1
another small fix
Erfan-Ahmadi bb793be
[temp] lower mem to test auto-submit
Erfan-Ahmadi bcb5fa3
fixed linestyle index fetching
Erfan-Ahmadi da76699
fixed acquireMainObjectIndex
Erfan-Ahmadi ed920b0
Fix DTM Rendering
Erfan-Ahmadi 9d23afd
Fixed auto-submission bug with self-blending in a beautiful and simpl…
Erfan-Ahmadi 126afa8
updates to comments regarding auto-submit
Erfan-Ahmadi 6830c08
update TODO, need to handle it, after figuring out compute stages and…
Erfan-Ahmadi 416d7b3
Saving work
Przemog1 b4f941a
Merge pull request #189 from Devsh-Graphics-Programming/gpu_driven_cad
Przemog1 06f72c5
Fixed anti aliasing
Przemog1 e4e7f1e
multiple draw calls to allow dtms and linework simultaneously.
Erfan-Ahmadi 2528e75
Implemented anti aliasing
Przemog1 fd4e576
Triangle dilation
Przemog1 6c907e4
Added few todos
Przemog1 f173c71
Refactor
Przemog1 1db627c
Fix DISCRETE_FIXED_LENGTH_INTERVALS + Refactors
Erfan-Ahmadi 432b931
clear function for Mesh
Erfan-Ahmadi 88dcf44
Fixed non-stippled lines
Przemog1 9064439
getIntervalHeightAndColor small fix
Erfan-Ahmadi 9707b33
Separated DTMSettingsInfo struct
Przemog1 fdbf20c
Fixes
Przemog1 c865357
Saving work
Przemog1 95ed1ad
apply inverse gamma on colors
Erfan-Ahmadi 244b0d0
screenToWorldRatio doesn't need to be double, only used to transform …
Erfan-Ahmadi b36e702
cleanups and setup work for multiple contours
Erfan-Ahmadi 2462d0a
multiple contours in fragment shader
Erfan-Ahmadi 287688e
Small example 62 update
Przemog1 4346a60
Merge branch 'master' of github.com:Devsh-Graphics-Programming/Nabla-…
Przemog1 daa51f6
Refactor
Przemog1 8a771a6
Fixed blending
Przemog1 fa5d7f1
Added `line_style.hlsl` file
Przemog1 9ddaa81
emulated float64 bug repro
Erfan-Ahmadi 12f3d84
grid dtm tasks
Erfan-Ahmadi 3e1cd3e
Fix and separate custom clip projection
Erfan-Ahmadi 6e27153
small example edit
Erfan-Ahmadi 496cec4
Merge branch 'grid_dtm' into dtm
Erfan-Ahmadi 6706df6
plus should be drawn, emulated fp64 bug
Erfan-Ahmadi c9d2abf
Fixed Geometry and Fixed Screenspace sized polylines handle
Erfan-Ahmadi 7381460
drawFixedGeometryPolyline add case to example
Erfan-Ahmadi 1db6e04
small fixes on transformation type
Erfan-Ahmadi 7521f57
fix vtx shader typo
Erfan-Ahmadi 7ab6f5d
small example edit
Erfan-Ahmadi f88f6b6
Preparation work for backing up and restoring draw resources cache (f…
Erfan-Ahmadi 4ec4938
CacheAndReplay Feature
Erfan-Ahmadi 8677f1f
sync with builtin-shaders work
Erfan-Ahmadi 8b56599
Small Fix to avoid msdf evictions of glyphs that were re-used
Erfan-Ahmadi 48b3125
small typo fix, oops
Erfan-Ahmadi daf6810
Support for StaticImages [VRAM Limitation Eviction Untested] + MSDF I…
Erfan-Ahmadi ce29c74
[WIP] Images.h and ImagesMemorySubAllocator, TODO: postDestroyCleanup…
Erfan-Ahmadi bd9ee8e
Better Image Test + PostCleanup free + Fixing command buffer usage af…
Erfan-Ahmadi fcff2ac
Small edits and refactor
Erfan-Ahmadi 093099f
Test and verify overflow submit works with images bound to non dedica…
Erfan-Ahmadi fc20a29
Grid DTM fundamentals
Przemog1 dc3ec8c
Resolved conflicts, merged dtm
Przemog1 8a8ff67
Merge branch 'master' of github.com:Devsh-Graphics-Programming/Nabla-…
Przemog1 0b010ea
Updated media submodule
Przemog1 ab6dd2e
Corrections
Przemog1 34a61a3
Fix overflow submits in a beautiful way
Erfan-Ahmadi ada9c8b
Cache&Replay with static images
Erfan-Ahmadi 2632c3a
use OrientedBoundingBox2D for images
Erfan-Ahmadi e2fef3a
start Georeferenced Images work and refactoring similar functionality…
Erfan-Ahmadi a714352
small fix
Erfan-Ahmadi 596751c
small fix2
Erfan-Ahmadi 2cbc2b0
[Untested] more work on Georeferenced images creation and recreating/…
Erfan-Ahmadi f1fb1b5
Adds Cache iteration test
Fletterio 3f40b92
small comment
Erfan-Ahmadi fccbcb2
addGeoreferencedImage, and image cache heavy refactors (Image States)
Erfan-Ahmadi 42ab873
streamed image copy
Erfan-Ahmadi b3dd409
static images improvements, promoting from the get-go
Erfan-Ahmadi 65fe2ab
work on internal `streamedImageCopies`
Erfan-Ahmadi 9d0d57d
small fixes
Erfan-Ahmadi 723506e
Implemented grid DTM rendering
Przemog1 e18d8bb
Resolved conflicts, merged dtm
Przemog1 f335b28
Improved phase shift calculation
Przemog1 43f4dd6
Added a todo comment
Przemog1 5fec9bc
Merge branch 'master' of github.com:Devsh-Graphics-Programming/Nabla-…
Przemog1 81a5c43
Add test for cache copy
Fletterio 6999e36
ensure multiple static images availability
Erfan-Ahmadi 48864b7
forgot to push function rename
Erfan-Ahmadi 96cc801
documentation for `ensureMultipleStaticImagesAvailability`
Erfan-Ahmadi 280d119
Fixes to images cache regarding georeferenced image resize
Erfan-Ahmadi 0b69363
edits after LRUCache Improvement
Erfan-Ahmadi 4b71781
Merge branch 'dtm' of github.com:Devsh-Graphics-Programming/Nabla-Exa…
Przemog1 d33f32e
Corrections
Przemog1 2f743b5
Implemented height map
Przemog1 a1c6dd1
forceUpdate in ensureStaticImageAvailability
Erfan-Ahmadi 3ccb6f9
Implemented nan height value handling
Przemog1 52d5670
Added test polyline draw
Przemog1 8a4fde3
Merge branch 'dtm' of github.com:Devsh-Graphics-Programming/Nabla-Exa…
Przemog1 f72a308
Fixed vertex shader so it now compiles with emulated float
Przemog1 5d139c4
Updated media
Przemog1 7762984
Updated media
Przemog1 00a1a1d
GRID DTM Small Fixes
Erfan-Ahmadi cd802d6
fixed memcmp in DtmSettings ==
Erfan-Ahmadi 6340d2f
logging in DrawResourcesFiller
Erfan-Ahmadi 9e0448c
Saving work
Przemog1 8d50e3e
Resolved conflicts, merged dtm
Przemog1 27cd66f
Implemented grid dilation
Przemog1 d1a4e8e
Added diagonal mode info to grid DTM height map
Przemog1 47dec6d
IUtilities constructor to static create function
Erfan-Ahmadi 0777434
allocateDrawResourcesWithinAvailableVRAM
Erfan-Ahmadi 307f7f9
un-premultiply alpha
Erfan-Ahmadi f0c2d5e
Fixed DTM diagonal info flushing
Przemog1 55b8313
Merge branch 'dtm' of github.com:Devsh-Graphics-Programming/Nabla-Exa…
Przemog1 fbf6740
Bringing Francisco's changes to DrawResourcesFiller
Erfan-Ahmadi 3866e2d
Saving work
Przemog1 9ed92e5
Fixed Geometry Fixes
Erfan-Ahmadi c111500
Added option to draw grid without height texture provided
Przemog1 1ee11d2
Merge branch 'dtm' of github.com:Devsh-Graphics-Programming/Nabla-Exa…
Przemog1 a7cfeeb
Fix
Przemog1 9f5da5c
Fixed warnings
Przemog1 8df4f58
Initial neighbouring cells drawing
Przemog1 ef865e7
Small change
Erfan-Ahmadi 8b89fa2
WIP Grid DTM Work
Erfan-Ahmadi de1ccfa
WIP contours in grid dtms
Erfan-Ahmadi 1b8135b
Grid Outlines SDF with Correct Dilation Logic
Erfan-Ahmadi b397df5
small fix
Erfan-Ahmadi 73c5652
comment
Erfan-Ahmadi 792f539
Small fixes with DTMS
Erfan-Ahmadi 3cf8194
Auto-Submit for Triangle DTMS
Erfan-Ahmadi 8a0043b
small fix
Erfan-Ahmadi e4c3f8b
Fix reindexing in auto submit triangle dtms
Erfan-Ahmadi d54bd98
Reimplemented height shading
Przemog1 7d2d282
Merge branch 'dtm' of github.com:Devsh-Graphics-Programming/Nabla-Exa…
Przemog1 91de837
outline phaseShift
Erfan-Ahmadi 1a61230
Forgot to actually set the phaseshift
Erfan-Ahmadi ed437eb
DTM Contour Fixes and GRID DTM refactor
Erfan-Ahmadi 71a41f3
small revert
Erfan-Ahmadi 3a7b90d
Small Fix
Erfan-Ahmadi 7d4e1f4
Shader Fixes and Improvements
Erfan-Ahmadi d3590dd
shader fixes and improvements on dtm
Erfan-Ahmadi f23411e
adding rotation to viewport
Erfan-Ahmadi 82c0d90
Moved grid only calculations from screen to grid space
Przemog1 050a201
Moved grid DTM color calculation from screen to grid space
Przemog1 5e4180c
Fixed out of bounds height map array access
Przemog1 710e2f7
Fixed emulated float compilation errors
Przemog1 e6417f4
Renamed CASE_BUG after bug fix
Przemog1 ea00599
Fixed compilation errors
Przemog1 06d839d
Enabled grid DTM height map view format validation
Przemog1 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
#include "CTriangleMesh.h" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,66 @@ | ||
#pragma once | ||
|
||
#include <nabla.h> | ||
#include <nbl/builtin/hlsl/cpp_compat.hlsl> | ||
#include "shaders/globals.hlsl" | ||
|
||
using namespace nbl; | ||
|
||
struct DTMSettingsInfo | ||
{ | ||
LineStyleInfo outlineLineStyleInfo; | ||
LineStyleInfo contourLineStyleInfo; | ||
// TODO: heights | ||
|
||
|
||
}; | ||
|
||
class CTriangleMesh final | ||
{ | ||
public: | ||
using index_t = uint32_t; | ||
using vertex_t = TriangleMeshVertex; | ||
|
||
struct DrawData | ||
{ | ||
PushConstants pushConstants; | ||
uint64_t indexBufferOffset; | ||
uint64_t indexCount; | ||
}; | ||
|
||
inline void setVertices(core::vector<vertex_t>&& vertices) | ||
{ | ||
m_vertices = std::move(vertices); | ||
} | ||
inline void setIndices(core::vector<uint32_t>&& indices) | ||
{ | ||
m_indices = std::move(indices); | ||
} | ||
|
||
inline const core::vector<vertex_t>& getVertices() const | ||
{ | ||
return m_vertices; | ||
} | ||
inline const core::vector<uint32_t>& getIndices() const | ||
{ | ||
return m_indices; | ||
} | ||
|
||
inline size_t getVtxBuffByteSize() const | ||
{ | ||
return sizeof(vertex_t) * m_vertices.size(); | ||
} | ||
inline size_t getIdxBuffByteSize() const | ||
{ | ||
return sizeof(index_t) * m_indices.size(); | ||
} | ||
inline size_t getIdxCnt() const | ||
{ | ||
return m_indices.size(); | ||
} | ||
|
||
|
||
private: | ||
core::vector<vertex_t> m_vertices; | ||
core::vector<index_t> m_indices; | ||
}; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.