Skip to content
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

Mesh shaders and SW meslet rendering #122

Merged
merged 124 commits into from
Jun 9, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
124 commits
Select commit Hold shift + click to select a range
4138e34
Update meshoptimizer
godlikepanos Oct 17, 2023
b99519e
Fix Android compilation
godlikepanos Oct 18, 2023
647bbe0
Optimize SPD for Mali
PanagiotisChristopoulosCharitos-ARM Oct 18, 2023
6951c19
Add the new mesh format that contains meshlets
godlikepanos Oct 23, 2023
118bd4d
Minor refactoring
godlikepanos Oct 24, 2023
e664d1a
Try to fix the thread job manager hangs
godlikepanos Oct 25, 2023
fc11f00
Try to fix some hangs
godlikepanos Oct 26, 2023
6056b35
Another attempt to fix the stupid hangs
godlikepanos Oct 26, 2023
8f60114
Add meshlet code up to the scene
godlikepanos Oct 26, 2023
70a2f31
Add the code of the task and mesh shaders in the GBufferGeneric shader
godlikepanos Oct 30, 2023
d1cb889
Add the simple mesh shader drawing. Not working yet
godlikepanos Nov 2, 2023
4df117c
Fix bugs. Now mesh shading appears to be working
godlikepanos Nov 2, 2023
2eba858
Optimize for nvidia
godlikepanos Nov 3, 2023
8da63ff
Don't enable validation when only debug markers are on
godlikepanos Nov 8, 2023
eb24220
Minor improvements
godlikepanos Nov 8, 2023
516d406
Increase meshlet size
godlikepanos Nov 9, 2023
b6fa2cf
Fix shadow vetting
godlikepanos Nov 9, 2023
f8fc2df
Decrease task payload size even further
godlikepanos Nov 10, 2023
52c8a4f
Calculate the tangent in the fragment shader
godlikepanos Nov 12, 2023
401d54a
Add an additional visibility test that helps probe generation
godlikepanos Nov 13, 2023
c6434ef
Sort the render batches when drawing for optimal performance
godlikepanos Nov 13, 2023
20d828f
Add pipeline stats query support in GR
godlikepanos Nov 15, 2023
7d83420
Enable primitive queries in the drawer
godlikepanos Nov 15, 2023
cc4e44c
Fix a bug in tangent calculation. Add some code for backface culling …
godlikepanos Nov 16, 2023
59a3ea9
Fix 2 bugs with mesh shading
godlikepanos Nov 16, 2023
6f85986
Fix meshlet backface culling
godlikepanos Nov 17, 2023
31aeb10
Optimize GPU visibility a bit and fix a bug in shader reflection
godlikepanos Nov 19, 2023
cd12381
Add all culling tests to task shader
godlikepanos Nov 19, 2023
a999db0
Enable per primitive culling
godlikepanos Nov 20, 2023
f1789b0
Remove spec consts from Bloom
godlikepanos Nov 21, 2023
655f66f
Remove the remaining spec consts from the shaders
godlikepanos Nov 23, 2023
075a9eb
Fix per-primitive culling
godlikepanos Nov 23, 2023
7711f07
Importer changes
godlikepanos Nov 24, 2023
fc7bb86
Add some new capabilities to the resource filesystem
godlikepanos Dec 7, 2023
2d82c5f
Fix some validation errors
godlikepanos Dec 7, 2023
a24df59
Re-design the shader programs and change the shader binary
godlikepanos Dec 8, 2023
a47a8ac
Remove shader reflection code
godlikepanos Dec 8, 2023
bb0c91c
Merge a few RT shaders
godlikepanos Dec 9, 2023
9546d08
Merge compute and raster versions of shaders into the same ankiprog file
godlikepanos Dec 9, 2023
6b5e512
Add functionality to decrease shader compilation times
godlikepanos Dec 10, 2023
5f862b6
Update DXC
PanagiotisChristopoulosCharitos-ARM Dec 13, 2023
75b815f
Fix the headless build
PanagiotisChristopoulosCharitos-ARM Dec 13, 2023
6cf37b8
Implement GTAO and remove SSGI
godlikepanos Dec 19, 2023
9395f9c
Optimize SSAO for mobile
godlikepanos Dec 19, 2023
e2aff97
Combine roughness and metalness into the same texture
godlikepanos Dec 20, 2023
154b477
Refactor shader program loading to accept arbitary combinations of te…
godlikepanos Dec 21, 2023
4b182a2
Optimize mesh shaders a bit
godlikepanos Dec 21, 2023
a997686
Add barycentrics support
godlikepanos Dec 21, 2023
3fcc9b5
Split the meshlet into 2 structs
godlikepanos Dec 23, 2023
7873f26
Minor refactoring
godlikepanos Dec 23, 2023
353d223
Change the max primitive count for meshlets
godlikepanos Dec 24, 2023
a3da05b
Refactor SSR
godlikepanos Dec 30, 2023
e768c4d
Minor SSR optimizations
godlikepanos Dec 31, 2023
7709bd8
Use downscale blur's result on SSR
godlikepanos Jan 1, 2024
eadb7f9
Break GI probes and reflection probe generation into multiple passes
godlikepanos Jan 4, 2024
e553c63
Split shadow mapping into multiple passes. This will help reduce memo…
godlikepanos Jan 4, 2024
ff2a300
Make GPU visibility memory persistent
godlikepanos Jan 6, 2024
3224bfe
Re-arrange shadow passes to increase pipelining
godlikepanos Jan 7, 2024
5e08cc3
Move GpuMeshLod to a separate structured buffer
godlikepanos Jan 9, 2024
5648601
Add the code for task/mesh S/W path
godlikepanos Jan 10, 2024
9dadc44
Add the S/W mesh shading in the GPU tests and the drawer
godlikepanos Jan 13, 2024
e43b429
Make the firstInstance of MDI drawcalls smaller
godlikepanos Jan 13, 2024
a566493
Implement SW meshlet culling
godlikepanos Jan 17, 2024
b7ef6e7
Decrease the GPU vis memory a bit but that adds more loads in vertex …
godlikepanos Jan 18, 2024
bae79bb
Fixes
godlikepanos Jan 19, 2024
b5042ec
Reduce the loads inside the vert shaders
godlikepanos Jan 20, 2024
ee33432
Optimize the vertex count on SW meshlet rendering
godlikepanos Jan 22, 2024
bf74976
Revise how meshlet memory allocation works
godlikepanos Jan 31, 2024
3d05475
Add streamline annotation library
godlikepanos Feb 2, 2024
0b6bcd2
Add streamline annotations to the tracer
godlikepanos Feb 3, 2024
2f61de9
Add scale and bias to the env maps in the component
godlikepanos Feb 5, 2024
9624b6f
Replace pre C++20 hacks and start using requires() where appropriate
godlikepanos Feb 5, 2024
310d225
GLTF importer additions
godlikepanos Feb 9, 2024
b75ad68
Minor visualization
godlikepanos Feb 9, 2024
1f8e1b3
Nuke dynamic uniform and storage buffers from the Vulkan backend
godlikepanos Feb 14, 2024
a99b6b9
Fix motion vector calculation. Improve SSAO denoising
godlikepanos Feb 19, 2024
2787205
Fix compiler warnings
godlikepanos Feb 21, 2024
2c1bb66
Minor changes
godlikepanos Feb 21, 2024
ed771f4
Add non-uniform scalling to Mat
godlikepanos Feb 26, 2024
17cb366
Fix the build and the mesh shaders test
godlikepanos Mar 1, 2024
12e84bc
Make scales non-uniform and fix a lot of bugs
godlikepanos Mar 3, 2024
dfcbd4d
Add bent normals
godlikepanos Mar 8, 2024
20b46cb
Optimize the part of reading indices in the SW meshlet rendering
godlikepanos Mar 11, 2024
a47d177
Remove the insane ammount of GPU jobs required to render point lights
godlikepanos Mar 12, 2024
408268e
Sort passes in rendergraph batches. Fix non-uniform access issues on AMD
godlikepanos Mar 13, 2024
6f419cc
Make buffer barriers more conservative
godlikepanos Mar 14, 2024
9846731
Add sky rendering
godlikepanos Mar 18, 2024
23b0919
Change the sun color based on transmitrance
godlikepanos Mar 21, 2024
f2ab329
Remove one more byte address buffer load
godlikepanos Mar 22, 2024
c127b78
Shader refactoring
godlikepanos Mar 26, 2024
4136b81
Nuke GL and add the skeleton for DX12
godlikepanos Mar 26, 2024
2be8eea
Some Vulkan refactoring
godlikepanos Mar 28, 2024
dd1836a
Command buffer submit refactoring
godlikepanos Mar 28, 2024
64160ca
Nuke secondary command buffers
godlikepanos Mar 30, 2024
c9c2e7c
Add DX12 device creation
godlikepanos Mar 30, 2024
4c010d2
Make vertex bindings just semantics
godlikepanos Apr 6, 2024
17f7777
Rename back to Vulkan terminology
godlikepanos Apr 7, 2024
210af1c
Switch to KHR_dynamic_rendering
godlikepanos Apr 14, 2024
bda873f
Fix a potential bug
godlikepanos Apr 16, 2024
e7925f7
Some more DX12 code
godlikepanos Apr 17, 2024
3b54294
Some refactoring
godlikepanos Apr 18, 2024
4b1af03
Some refactoring and some D3D code
godlikepanos Apr 20, 2024
fd50601
Add the notion of buffer views
godlikepanos Apr 24, 2024
c74690b
Some renaming
godlikepanos Apr 24, 2024
de64330
Remove the TextureView and replace it with something more simple
godlikepanos Apr 30, 2024
0f609fe
Fix bugs
godlikepanos Apr 30, 2024
b76a5ff
Add more D3D12 code
godlikepanos May 3, 2024
01fcf70
Clear screen test works on D3D12
godlikepanos May 5, 2024
111f22a
Enable DXIL compilation
godlikepanos May 9, 2024
4d5d13e
More D3D compiler work
godlikepanos May 10, 2024
06276b7
More D3D work: Buffers, descriptors, compute
godlikepanos May 16, 2024
85efdcf
Finalize D3D descriptor stuff
godlikepanos May 22, 2024
54818b8
Some renaming
godlikepanos May 23, 2024
97734ab
Move Vulkan to the new binding model
godlikepanos Jun 1, 2024
000f620
Add PSO handling to D3D
godlikepanos Jun 5, 2024
11350bb
Implement indirect calls in D3D
godlikepanos Jun 6, 2024
f92ee48
Add D3D timestamp queries support
godlikepanos Jun 7, 2024
4e2bb0c
D3D: Add debug markers
godlikepanos Jun 7, 2024
1d48d9b
D3D: Finalize queries
godlikepanos Jun 8, 2024
2f1a26a
D3D: Add texture and buffer enhanced barriers
godlikepanos Jun 8, 2024
d8df01f
Fix validation errors
godlikepanos Jun 9, 2024
1c34bfc
Fix the vulkan build
godlikepanos Jun 9, 2024
30dd292
Update Linux DXC
godlikepanos Jun 9, 2024
f8b3556
Try to fix the Linux build
godlikepanos Jun 9, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
2 changes: 1 addition & 1 deletion .clang-format-hlsl
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@ SpacesInParentheses: false
SpacesInSquareBrackets: false
SpaceBeforeSquareBrackets: false
BitFieldColonSpacing: Both
Standard: Latest
Standard: Cpp03
StatementAttributeLikeMacros:
- Q_EMIT
StatementMacros:
Expand Down
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,5 @@ out/*
CMakeSettings.json
*.TMP
AndroidProject_*
*.diff
*.patch
14 changes: 9 additions & 5 deletions AnKi/Collision/Aabb.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -15,13 +15,17 @@ Aabb Aabb::getTransformed(const Transform& trf) const
absM[i] = absolute(trf.getRotation()[i]);
}

Vec4 center = (m_min + m_max) * 0.5f;
Vec4 extend = (m_max - m_min) * 0.5f;
const Vec4 center = (m_min + m_max) * 0.5f;
const Vec4 extend = (m_max - m_min) * 0.5f;

Vec4 newC = trf.transform(center);
Vec4 newE = Vec4(absM * (extend * trf.getScale()), 0.0f);
const Vec4 newC = trf.transform(center);
const Vec4 newE = Vec4(absM * (extend * trf.getScale()), 0.0f);

return Aabb(newC - newE, newC + newE + Vec4(kEpsilonf, kEpsilonf, kEpsilonf, 0.0f));
const Vec4 min = newC - newE;
const Vec4 max = newC + newE;

const F32 epsilon = kEpsilonf * 100.0f;
return Aabb(min, max + Vec4(epsilon, epsilon, epsilon, 0.0f));
}

Aabb Aabb::getCompoundShape(const Aabb& b) const
Expand Down
3 changes: 2 additions & 1 deletion AnKi/Collision/Cone.h
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,8 @@ class Cone
Cone out;
out.m_origin = transform.transform(m_origin);
out.m_dir = (transform.getRotation() * m_dir.xyz0()).xyz0();
out.m_length *= transform.getScale();
ANKI_ASSERT(transform.hasUniformScale());
out.m_length *= transform.getScale().x();
return out;
}

Expand Down
5 changes: 4 additions & 1 deletion AnKi/Collision/Functions.h
Original file line number Diff line number Diff line change
Expand Up @@ -229,7 +229,10 @@ void extractClipPlane(const Mat4& mvp, FrustumPlaneType id, Plane& plane);
void computeEdgesOfFrustum(F32 far, F32 fovX, F32 fovY, Vec3 points[4]);

/// Welzl's algorithm that computes a compact bounding sphere given a point cloud.
Sphere computeBoundingSphere(ConstWeakArray<Vec3> points);
ANKI_PURE Sphere computeBoundingSphere(const Vec3* firstPoint, U32 pointCount, PtrSize stride);

/// Computes an AABB given a point cloud.
ANKI_PURE Aabb computeBoundingAabb(const Vec3* firstPoint, U32 pointCount, PtrSize stride);

/// @}

Expand Down
121 changes: 79 additions & 42 deletions AnKi/Collision/FunctionsMisc.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -66,56 +66,69 @@ void computeEdgesOfFrustum(F32 far, F32 fovX, F32 fovY, Vec3 points[4])
points[3] = Vec3(x, -y, z); // bot right
}

static Vec4 computeBoundingSphere2(const Vec3 O, const Vec3 A)
{
const Vec3 a = A - O;

const Vec3 o = 0.5f * a;

const F32 radius = o.getLength() + kEpsilonf;
const Vec3 center = O + o;

return Vec4(center, radius);
}

static Vec4 computeBoundingSphere3(const Vec3 O, const Vec3 A, const Vec3 B)
{
const Vec3 a = A - O;
const Vec3 b = B - O;

const Vec3 acrossb = a.cross(b);
const F32 denominator = 2.0f * (acrossb.dot(acrossb));

if(denominator == 0.0f) [[unlikely]]
{
// A pair in A,B,O are the same point or they are in the same line

if(a.getLengthSquared() > b.getLengthSquared())
{
return computeBoundingSphere2(O, A);
}
else
{
return computeBoundingSphere2(O, B);
}
}

Vec3 o = b.dot(b) * acrossb.cross(a);
o += a.dot(a) * b.cross(acrossb);
o /= denominator;

const F32 radius = o.getLength() + kEpsilonf;
const Vec3 center = O + o;

return Vec4(center, radius);
}

Vec4 computeBoundingSphereRecursive(WeakArray<const Vec3*> pPoints, U32 begin, U32 p, U32 b)
{
Vec4 sphere;

switch(b)
{
case 0:
sphere = Vec4(0.0f, 0.0f, 0.0f, -1.0f);
sphere = Vec4(0.0f, 0.0f, 0.0f, 0.0f);
break;
case 1:
sphere = Vec4(*pPoints[begin - 1], kEpsilonf);
break;
case 2:
{
const Vec3 O = *pPoints[begin - 1];
const Vec3 A = *pPoints[begin - 2];

const Vec3 a = A - O;

const Vec3 o = 0.5f * a;

const F32 radius = o.getLength() + kEpsilonf;
const Vec3 center = O + o;

sphere = Vec4(center, radius);
sphere = computeBoundingSphere2(*pPoints[begin - 1], *pPoints[begin - 2]);
break;
}
case 3:
{
const Vec3 O = *pPoints[begin - 1];
const Vec3 A = *pPoints[begin - 2];
const Vec3 B = *pPoints[begin - 3];

const Vec3 a = A - O;
const Vec3 b = B - O;

const Vec3 acrossb = a.cross(b);
const F32 denominator = 2.0f * (acrossb.dot(acrossb));

Vec3 o = b.dot(b) * acrossb.cross(a);
o += a.dot(a) * b.cross(acrossb);
o /= denominator;

const F32 radius = o.getLength() + kEpsilonf;
const Vec3 center = O + o;

sphere = Vec4(center, radius);

sphere = computeBoundingSphere3(*pPoints[begin - 1], *pPoints[begin - 2], *pPoints[begin - 3]);
return sphere;
}
break;
#if 0
// There is this case as well but it fails if points are coplanar so avoid it
case 4:
Expand Down Expand Up @@ -173,32 +186,56 @@ Vec4 computeBoundingSphereRecursive(WeakArray<const Vec3*> pPoints, U32 begin, U
return sphere;
}

Sphere computeBoundingSphere(ConstWeakArray<Vec3> points)
Sphere computeBoundingSphere(const Vec3* firstPoint, U32 pointCount, PtrSize stride)
{
ANKI_ASSERT(points.getSize() >= 3);
ANKI_ASSERT(firstPoint);
ANKI_ASSERT(pointCount >= 3);
ANKI_ASSERT(stride >= sizeof(Vec3));

DynamicArray<const Vec3*> pPointsDyn;
Array<const Vec3*, 8> pPointsArr;
WeakArray<const Vec3*> pPoints;

if(points.getSize() > pPointsArr.getSize())
if(pointCount > pPointsArr.getSize())
{
pPointsDyn.resize(points.getSize());
pPointsDyn.resize(pointCount);
pPoints = pPointsDyn;
}
else
{
pPoints = {&pPointsArr[0], points.getSize()};
pPoints = {&pPointsArr[0], pointCount};
}

for(U32 i = 0; i < points.getSize(); ++i)
for(U32 i = 0; i < pointCount; ++i)
{
pPoints[i] = &points[i];
pPoints[i] = reinterpret_cast<const Vec3*>(ptrToNumber(firstPoint) + i * stride);
}

const Vec4 sphere = computeBoundingSphereRecursive(pPoints, 0, pPoints.getSize(), 0);

return Sphere(sphere.xyz(), sphere.w());
}

Aabb computeBoundingAabb(const Vec3* firstPoint, U32 pointCount, PtrSize stride)
{
ANKI_ASSERT(firstPoint);
ANKI_ASSERT(pointCount >= 3);
ANKI_ASSERT(stride >= sizeof(Vec3));

Vec3 min(kMaxF32);
Vec3 max(kMinF32);

for(U32 i = 0; i < pointCount; ++i)
{
const Vec3& point = *reinterpret_cast<const Vec3*>(ptrToNumber(firstPoint) + i * stride);

min = min.min(point);
max = max.max(point);
}

max += 10.0f * kEpsilonf;

return Aabb(min, max);
}

} // end namespace anki
3 changes: 2 additions & 1 deletion AnKi/Collision/Plane.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,8 @@ Plane Plane::getTransformed(const Transform& trf) const
Mat3x4 rot = trf.getRotation();
rot.transposeRotationPart();
Vec4 newTrans(rot * trf.getOrigin(), 0.0f);
plane.m_offset = m_offset * trf.getScale() + newTrans.dot(m_normal);
ANKI_ASSERT(trf.hasUniformScale());
plane.m_offset = m_offset * trf.getScale().x() + newTrans.dot(m_normal);

return plane;
}
Expand Down
4 changes: 3 additions & 1 deletion AnKi/Collision/Sphere.h
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,7 @@ class Sphere

void setRadius(const F32 x)
{
ANKI_ASSERT(x > 0.0f);
m_radius = x;
}

Expand All @@ -95,7 +96,8 @@ class Sphere
check();
Sphere out;
out.m_center = transform.transform(m_center);
out.m_radius = m_radius * transform.getScale();
ANKI_ASSERT(transform.hasUniformScale());
out.m_radius = m_radius * transform.getScale().x();
return out;
}

Expand Down
11 changes: 8 additions & 3 deletions AnKi/Config.h.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -143,8 +143,13 @@
#endif

// Graphics backend
#define ANKI_GR_BACKEND_GL 0
#define ANKI_GR_BACKEND_VULKAN 1
#if ${_ANKI_GR_BACKEND} == 0
# define ANKI_GR_BACKEND_VULKAN 1
# define ANKI_GR_BACKEND_DIRECT3D 0
#else
# define ANKI_GR_BACKEND_VULKAN 0
# define ANKI_GR_BACKEND_DIRECT3D 1
#endif

// Windowing system
#if ${_ANKI_WINDOWING_SYSTEM} == 0
Expand All @@ -162,7 +167,7 @@
#endif

// Mobile or not
#define ANKI_PLATFORM_MOBILE (ANKI_CPU_ARCH_ARM)
#define ANKI_PLATFORM_MOBILE ${_ANKI_PLATFORM_MOBILE}

// Some compiler attributes
#if ANKI_COMPILER_GCC_COMPATIBLE
Expand Down
25 changes: 13 additions & 12 deletions AnKi/Core/App.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,7 @@ BoolCVar g_verboseLogCVar(CVarSubsystem::kCore, "VerboseLog", false, "Verbose lo
BoolCVar g_benchmarkModeCVar(CVarSubsystem::kCore, "BenchmarkMode", false, "Run in a benchmark mode. Fixed timestep, unlimited target FPS");
NumericCVar<U32> g_benchmarkModeFrameCountCVar(CVarSubsystem::kCore, "BenchmarkModeFrameCount", 60 * 60 * 2, 1, kMaxU32,
"How many frames the benchmark will run before it quits");
BoolCVar g_meshletRenderingCVar(CVarSubsystem::kCore, "MeshletRendering", false, "Do meshlet culling and rendering");

#if ANKI_PLATFORM_MOBILE
static StatCounter g_maliGpuActiveStatVar(StatCategory::kGpuMisc, "Mali active cycles", StatFlag::kMainThreadUpdates);
Expand Down Expand Up @@ -222,13 +223,11 @@ Error App::initInternal()
"NOT built with tracing";
#endif

ANKI_CORE_LOGI("Initializing application ("
"version %u.%u, "
"%s, "
"compiler %s, "
"build date %s, "
"commit %s)",
ANKI_VERSION_MAJOR, ANKI_VERSION_MINOR, buildType, ANKI_COMPILER_STR, __DATE__, ANKI_REVISION);
ANKI_CORE_LOGI("Initializing application");
ANKI_CORE_LOGI("\tBuild type %s", buildType);
ANKI_CORE_LOGI("\tBuild time %s %s", __DATE__, __TIME__);
ANKI_CORE_LOGI("\tCompiler %s", ANKI_COMPILER_STR);
ANKI_CORE_LOGI("\tCommit %s", ANKI_REVISION);

// Check SIMD support
#if ANKI_SIMD_SSE && ANKI_COMPILER_GCC_COMPATIBLE
Expand Down Expand Up @@ -323,11 +322,13 @@ Error App::initInternal()
String executableFname;
ANKI_CHECK(getApplicationPath(executableFname));
ANKI_CORE_LOGI("Executable path is: %s", executableFname.cstr());
String shadersPath;
getParentFilepath(executableFname, shadersPath);
shadersPath += ":";
shadersPath += g_dataPathsCVar.get();
g_dataPathsCVar.set(shadersPath);
String extraPaths;
getParentFilepath(executableFname, extraPaths);
extraPaths += "|ankiprogbin"; // Shaders
extraPaths += ":" ANKI_SOURCE_DIRECTORY "|EngineAssets,!AndroidProject"; // EngineAssets
extraPaths += ":";
extraPaths += g_dataPathsCVar.get();
g_dataPathsCVar.set(extraPaths);
#endif

ANKI_CHECK(ResourceManager::allocateSingleton().init(allocCb, allocCbUserData));
Expand Down
1 change: 1 addition & 0 deletions AnKi/Core/App.h
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ extern NumericCVar<U32> g_windowHeightCVar;
extern NumericCVar<U32> g_windowFullscreenCVar;
extern NumericCVar<U32> g_targetFpsCVar;
extern NumericCVar<U32> g_displayStatsCVar;
extern BoolCVar g_meshletRenderingCVar;
extern StatCounter g_cpuTotalTimeStatVar;
extern StatCounter g_rendererGpuTimeStatVar;

Expand Down
3 changes: 2 additions & 1 deletion AnKi/Core/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,8 @@ set(sources
GpuMemory/UnifiedGeometryBuffer.cpp
GpuMemory/GpuSceneBuffer.cpp
GpuMemory/RebarTransientMemoryPool.cpp
GpuMemory/GpuReadbackMemoryPool.cpp)
GpuMemory/GpuReadbackMemoryPool.cpp
GpuMemory/GpuVisibleTransientMemoryPool.cpp)

set(headers
App.h
Expand Down
5 changes: 3 additions & 2 deletions AnKi/Core/CVarSet.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ Error CVarSet::setFromCommandLineArguments(U32 cmdLineArgsCount, char* cmdLineAr
{
if(foundCVar)
{
ANKI_CORE_LOGW("Command line arg %s has ambiguous name", varName.cstr());
ANKI_CORE_LOGE("Command line arg %s has ambiguous name. Skipping", varName.cstr());
}
else
{
Expand Down Expand Up @@ -102,6 +102,7 @@ Error CVarSet::setFromCommandLineArguments(U32 cmdLineArgsCount, char* cmdLineAr
break;
}
ANKI_CVAR_NUMERIC_SET(U8)
ANKI_CVAR_NUMERIC_SET(U16)
ANKI_CVAR_NUMERIC_SET(U32)
ANKI_CVAR_NUMERIC_SET(PtrSize)
ANKI_CVAR_NUMERIC_SET(F32)
Expand All @@ -117,7 +118,7 @@ Error CVarSet::setFromCommandLineArguments(U32 cmdLineArgsCount, char* cmdLineAr
}
else
{
ANKI_CORE_LOGW("Can't recognize command line argument: %s. Skipping", varName.cstr());
ANKI_CORE_LOGE("Can't recognize command line argument: %s. Skipping", varName.cstr());
}
}

Expand Down
2 changes: 2 additions & 0 deletions AnKi/Core/CVarSet.h
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@ class CVar : public IntrusiveListEnabled<CVar>
kString,
kBool,
kNumericU8,
kNumericU16,
kNumericU32,
kNumericPtrSize,
kNumericF32
Expand Down Expand Up @@ -122,6 +123,7 @@ class NumericCVar : public CVar
}

ANKI_CVAR_NUMERIC_TYPE(U8)
ANKI_CVAR_NUMERIC_TYPE(U16)
ANKI_CVAR_NUMERIC_TYPE(U32)
ANKI_CVAR_NUMERIC_TYPE(PtrSize)
ANKI_CVAR_NUMERIC_TYPE(F32)
Expand Down
Loading
Loading