Skip to content

Commit

Permalink
no message
Browse files Browse the repository at this point in the history
  • Loading branch information
selimanac committed Sep 27, 2022
1 parent fd50817 commit 36fa6f9
Showing 1 changed file with 12 additions and 14 deletions.
26 changes: 12 additions & 14 deletions daabbcc/include/DynamicTree.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,10 @@
#include <dmsdk/dlib/log.h>

struct orderResultValues
{
int32 proxyID;
float32 distance;
};
{
int32 proxyID;
float32 distance;
};

class DynamicTree
{
Expand Down Expand Up @@ -45,33 +45,33 @@ class DynamicTree
float32 RayCastCallback(const b2RayCastInputAABB &input, int32 proxyId, int groupId);

// RayCast to AABB
void RayCast(int groupId, float start_x, float start_y, float end_x, float end_y);
void RayCast(int groupId, float start_x, float start_y, float end_x, float end_y);

void RayCastShort(int groupId, float start_x, float start_y, float end_x, float end_y);
void RayCastShort(int groupId, float start_x, float start_y, float end_x, float end_y);

// Query with AABB
void QueryAABB(int groupId, float x, float y, int w, int h);
void QueryAABB(int groupId, float x, float y, int w, int h);

// Query with ID
void QueryID(int groupId, int proxyID); // std::vector<int32> QueryID(int groupId, int proxyID);

// Query with ID - Distance Ordered
void QueryIDShort(int groupId, int proxyID);

void QueryAABBShort(int groupId, float x, float y, int w, int h);
void QueryAABBShort(int groupId, float x, float y, int w, int h);

// Query result
jc::Array<int32> result;

// Raycast result
jc::Array<int32> ray_result;

// Query order result
// Query order result
jc::Array<orderResultValues> orderResult;

// Assert
bool CheckGroup(int groupID);
bool isShorted = false;
bool isShorted = false;

private:
// Hashtable for Groups
Expand All @@ -81,8 +81,6 @@ class DynamicTree
};
typedef jc::HashTable<uint32_t, Groups> hashtable_t;



// Hashtable defaults
uint32_t numelements = 20; // The maximum number of entries to store
uint32_t load_factor = 50; // percent
Expand All @@ -107,10 +105,10 @@ class DynamicTree
int nodeProxyID;
b2Vec2 nodeProxyCenter;
b2Vec2 targetProxyCenter;

orderResultValues tmpOrder;
jc::Array<orderResultValues> tmpOrderResult;

// Reset class
void ResetTree();
};
Expand Down

0 comments on commit 36fa6f9

Please sign in to comment.