47 explicit ModelData(medialoader::ModelScene
scene, std::string
uri =
"",
bool uvFlipped =
false);
56 int getMeshCount()
const;
58 int getMaterialCount()
const;
61 int getVertexCount(
int meshIndex)
const;
64 int getFaceCount(
int meshIndex)
const;
66 float getVertexPosition(
int meshIndex,
int vertexIndex,
int component)
const;
70 float getVertexNormal(
int meshIndex,
int vertexIndex,
int component)
const;
85 [[nodiscard]]
eve::Result<void> setVertexNormal(
int meshIndex,
int vertexIndex,
float x,
float y,
112 float originX,
float originY,
float originZ);
128 int meshIndex,
int width,
int height,
int uvChannel = 0, std::string_view space =
"tangent")
const;
130 int getFaceVertexIndex(
int meshIndex,
int triangleIndex,
int corner)
const;
136 bool hasTexCoords(
int meshIndex)
const;
138 int getTexCoordChannelCount(
int meshIndex)
const;
140 bool hasTexCoordChannel(
int meshIndex,
int channel)
const;
142 float getTexCoord(
int meshIndex,
int channel,
int vertexIndex,
int component)
const;
156 int meshIndex,
int triangleIndex,
float localX,
float localY,
float localZ,
157 int channel = 0)
const;
159 bool hasTangents(
int meshIndex)
const;
161 float getTangent(
int meshIndex,
int vertexIndex,
int component)
const;
163 float getBitangent(
int meshIndex,
int vertexIndex,
int component)
const;
165 int getVertexColorChannelCount(
int meshIndex)
const;
167 bool hasVertexColorChannel(
int meshIndex,
int channel)
const;
169 float getVertexColor(
int meshIndex,
int channel,
int vertexIndex,
int component)
const;
173 int getMaterialIndex(
int meshIndex)
const;
175 std::string getMaterialName(
int matIndex)
const;
177 float getMaterialBaseColorR(
int matIndex)
const;
179 float getMaterialBaseColorG(
int matIndex)
const;
181 float getMaterialBaseColorB(
int matIndex)
const;
183 float getMaterialBaseColorA(
int matIndex)
const;
185 float getMaterialMetallicFactor(
int matIndex)
const;
187 float getMaterialRoughnessFactor(
int matIndex)
const;
189 float getMaterialOpacity(
int matIndex)
const;
191 bool getMaterialTwoSided(
int matIndex)
const;
193 std::string getMaterialAlphaMode(
int matIndex)
const;
195 float getMaterialAlphaCutoff(
int matIndex)
const;
202 int getMaterialTextureSlotCount(
int matIndex,
const std::string &
type)
const;
204 std::string getMaterialTexturePath(
int matIndex,
const std::string &
type,
int slot = 0)
const;
206 int getMaterialTextureEmbeddedIndex(
int matIndex,
const std::string &
type,
int slot = 0)
const;
210 int getEmbeddedTextureCount()
const;
212 std::string getEmbeddedTextureName(
int idx)
const;
214 int getEmbeddedTextureWidth(
int idx)
const;
216 int getEmbeddedTextureHeight(
int idx)
const;
226 int getMorphTargetCount(
int meshIndex)
const;
228 std::string getMorphTargetName(
int meshIndex,
int morphIndex)
const;
231 bool hasBones(
int meshIndex)
const;
233 int getBoneCount(
int meshIndex)
const;
235 std::string getBoneName(
int meshIndex,
int boneIndex)
const;
237 float getInverseBindMatrixElement(
int meshIndex,
int boneIndex,
int elementIndex)
const;
239 int getBoneWeightCount(
int meshIndex,
int boneIndex)
const;
241 int getBoneWeightVertex(
int meshIndex,
int boneIndex,
int weightIndex)
const;
243 float getBoneWeightValue(
int meshIndex,
int boneIndex,
int weightIndex)
const;
246 int getAnimationCount()
const;
248 std::string getAnimationName(
int animIndex)
const;
251 const aiScene *getScene()
const;
253 const aiMesh *getMesh(
int meshIndex)
const;
260 const aiMesh *meshAt(
int meshIndex)
const;
267 aiMesh *meshAtMutable(
int meshIndex);
268 const aiMaterial *materialAt(
int matIndex)
const;
270 medialoader::ModelScene
scene;
271 bool uvFlipped_ =
false;