Skip to content

Commit

Permalink
fix: add missing enum formatters
Browse files Browse the repository at this point in the history
  • Loading branch information
Latios96 committed Feb 27, 2024
1 parent d12faa6 commit feb194e
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 0 deletions.
7 changes: 7 additions & 0 deletions src/crayg/src/intersectors/embree/EmbreeBvh.h
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,20 @@
#define CRAYG_SRC_CRAYG_SRC_INTERSECTORS_EMBREE_EMBREEBVH_H_

#include "utils/DtoUtils.h"
#include "utils/EnumUtils.h"
#include <embree3/rtcore.h>
#include <unordered_map>

namespace crayg {

enum EmbreePrimitiveType { TRIANGLE_MESH, SUBDIVISION_SURFACE_MESH, SPHERE };

}

CRAYG_FMT_ENUM_FORMATTER(crayg::EmbreePrimitiveType);

namespace crayg {

CRAYG_DTO_2(EmbreeMappingEntry, std::uint32_t, sceneObjectIndex, EmbreePrimitiveType, primitiveType)

typedef std::unordered_map<unsigned int, EmbreeMappingEntry> GeomToSceneObject;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,14 @@
#ifndef CRAYG_SRC_CRAYG_SRC_SCENE_PRIMITIVES_TRIANGLEMESH_PRIMVARS_PRIMVARTYPE_H_
#define CRAYG_SRC_CRAYG_SRC_SCENE_PRIMITIVES_TRIANGLEMESH_PRIMVARS_PRIMVARTYPE_H_

#include "utils/EnumUtils.h"

namespace crayg {

enum PrimVarType { PER_FACE, PER_POINT, PER_VERTEX };

}

CRAYG_FMT_ENUM_FORMATTER(crayg::PrimVarType);

#endif // CRAYG_SRC_CRAYG_SRC_SCENE_PRIMITIVES_TRIANGLEMESH_PRIMVARS_PRIMVARTYPE_H_

0 comments on commit feb194e

Please sign in to comment.