mirror of
https://github.com/TheRedShip/RT_GPU.git
synced 2025-09-27 18:48:36 +02:00
+ | New topbvh stats
This commit is contained in:
@ -19,6 +19,13 @@ struct GPUBvhData;
|
|||||||
struct GPUTopBvh;
|
struct GPUTopBvh;
|
||||||
struct AABB;
|
struct AABB;
|
||||||
|
|
||||||
|
struct TopBVHStats
|
||||||
|
{
|
||||||
|
int min_bvh;
|
||||||
|
int max_bvh;
|
||||||
|
float average_bvh;
|
||||||
|
};
|
||||||
|
|
||||||
class TopBVH
|
class TopBVH
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
@ -30,16 +37,12 @@ class TopBVH
|
|||||||
float evaluateSah(std::vector<GPUBvhData> &bvhs_data, std::vector<GPUBvh> &bvhs, int axis, float pos);
|
float evaluateSah(std::vector<GPUBvhData> &bvhs_data, std::vector<GPUBvh> &bvhs, int axis, float pos);
|
||||||
|
|
||||||
int getSize();
|
int getSize();
|
||||||
// int getLeaves();
|
int getLeaves();
|
||||||
|
|
||||||
// void flatten(std::vector<GPUTopBvh> &TopBVHs, int ¤tIndex);
|
|
||||||
// GPUTopBvh toGPUTopBvh();
|
|
||||||
std::vector<GPUTopBvh> getGPUTopBvhs();
|
std::vector<GPUTopBvh> getGPUTopBvhs();
|
||||||
void flatten(std::vector<GPUTopBvh> &top_bvhs, int ¤tIndex);
|
void flatten(std::vector<GPUTopBvh> &top_bvhs, int ¤tIndex);
|
||||||
|
|
||||||
// const AABB &getAABB() const;
|
TopBVHStats analyzeBVHLeaves();
|
||||||
// std::vector<GPUTopBvh> getGPUTopBvhs();
|
|
||||||
|
|
||||||
|
|
||||||
private:
|
private:
|
||||||
AABB _aabb;
|
AABB _aabb;
|
||||||
|
@ -24,18 +24,8 @@ pl 0 -2 0 0 1 0 2 // floor
|
|||||||
|
|
||||||
qu -1 1.999 -1 2 0 0 0 0 2 6
|
qu -1 1.999 -1 2 0 0 0 0 2 6
|
||||||
|
|
||||||
OBJ scenes/obj/Dragon_80K.obj -0.5 0 0.55 5 0 0 0
|
OBJ obj/Dragon_80K.obj -0.5 0 0.55 1 0 90 0
|
||||||
OBJ scenes/obj/Dragon_80K.obj 0.5 0 -0.55 1 0 0 0
|
OBJ obj/Dragon_80K.obj 0.5 0 -0.55 1 0 -90 0
|
||||||
|
|
||||||
OBJ scenes/obj/Dragon_80K.obj -1.5 0 1.5 1 0 0 0
|
|
||||||
OBJ scenes/obj/Dragon_80K.obj 1.5 0 -1.5 1 0 0 0
|
|
||||||
|
|
||||||
OBJ scenes/obj/Dragon_80K.obj -0.5 1 0.55 1 0 0 0
|
|
||||||
OBJ scenes/obj/Dragon_80K.obj 0.5 1 -0.55 1 0 0 0
|
|
||||||
|
|
||||||
OBJ scenes/obj/Dragon_80K.obj -3.5 3 3.5 1 0 0 0
|
|
||||||
OBJ scenes/obj/Dragon_80K.obj 3.5 3 -3.5 1 0 0 0
|
|
||||||
|
|
||||||
|
|
||||||
# OBJ obj/Model.obj
|
# OBJ obj/Model.obj
|
||||||
|
|
||||||
|
2226
scenes/test.rt
2226
scenes/test.rt
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user