Skip to content

Commit b436d14

Browse files
committed
Inline BVH box comparison generic function
1 parent 445b965 commit b436d14

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

books/RayTracingTheNextWeek.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -814,7 +814,7 @@
814814
function.
815815

816816
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ C++
817-
bool box_compare(const hittable* a, const hittable* b, int axis) {
817+
inline bool box_compare(const hittable* a, const hittable* b, int axis) {
818818
aabb box_a;
819819
aabb box_b;
820820

src/TheNextWeek/bvh.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ class bvh_node : public hittable {
3535
};
3636

3737

38-
bool box_compare(const hittable* a, const hittable* b, int axis) {
38+
inline bool box_compare(const hittable* a, const hittable* b, int axis) {
3939
aabb box_a;
4040
aabb box_b;
4141

src/TheRestOfYourLife/bvh.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ class bvh_node : public hittable {
3535
};
3636

3737

38-
bool box_compare(const hittable *a, const hittable *b, int axis) {
38+
inline bool box_compare(const hittable *a, const hittable *b, int axis) {
3939
aabb box_a;
4040
aabb box_b;
4141

0 commit comments

Comments
 (0)