Skip to content

Commit

Permalink
Merge pull request assimp#4512 from umlaeute/aiTextureTypeToString
Browse files Browse the repository at this point in the history
Rename TextureTypeToString() to aiTextureTypeToString()
  • Loading branch information
kimkulling authored May 2, 2022
2 parents 4613709 + 1d3d5c4 commit e8abb0f
Show file tree
Hide file tree
Showing 7 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion code/AssetLib/Assxml/AssxmlFileWriter.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -365,7 +365,7 @@ static void WriteDump(const char *pFile, const char *cmd, const aiScene *scene,

ioprintf(io, "\t\t\t<MatProperty key=\"%s\" \n\t\t\ttype=\"%s\" tex_usage=\"%s\" tex_index=\"%u\"",
prop->mKey.data, sz,
::TextureTypeToString((aiTextureType)prop->mSemantic), prop->mIndex);
::aiTextureTypeToString((aiTextureType)prop->mSemantic), prop->mIndex);

if (prop->mType == aiPTI_Float) {
ioprintf(io, " size=\"%i\">\n\t\t\t\t",
Expand Down
2 changes: 1 addition & 1 deletion code/Common/material.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include <assimp/material.h>

// -------------------------------------------------------------------------------
const char *TextureTypeToString(aiTextureType in) {
const char *aiTextureTypeToString(aiTextureType in) {
switch (in) {
case aiTextureType_NONE:
return "n/a";
Expand Down
2 changes: 1 addition & 1 deletion code/Pbrt/PbrtExporter.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -590,7 +590,7 @@ void PbrtExporter::WriteMaterial(int m) {
for (int i = 1; i <= aiTextureType_UNKNOWN; i++) {
int count = material->GetTextureCount(aiTextureType(i));
if (count > 0)
mOutput << TextureTypeToString(aiTextureType(i)) << ": " << count << " ";
mOutput << aiTextureTypeToString(aiTextureType(i)) << ": " << count << " ";
}
mOutput << "\n";

Expand Down
2 changes: 1 addition & 1 deletion code/PostProcessing/ComputeUVMappingProcess.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -415,7 +415,7 @@ void ComputeUVMappingProcess::Execute( aiScene* pScene)
if (!DefaultLogger::isNullLogger())
{
ai_snprintf(buffer, 1024, "Found non-UV mapped texture (%s,%u). Mapping type: %s",
TextureTypeToString((aiTextureType)prop->mSemantic),prop->mIndex,
aiTextureTypeToString((aiTextureType)prop->mSemantic),prop->mIndex,
MappingTypeToString(mapping));

ASSIMP_LOG_INFO(buffer);
Expand Down
2 changes: 1 addition & 1 deletion code/PostProcessing/ValidateDataStructure.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -521,7 +521,7 @@ void ValidateDSProcess::Validate(const aiAnimation *pAnimation) {
// ------------------------------------------------------------------------------------------------
void ValidateDSProcess::SearchForInvalidTextures(const aiMaterial *pMaterial,
aiTextureType type) {
const char *szType = TextureTypeToString(type);
const char *szType = aiTextureTypeToString(type);

// ****************************************************************************
// Search all keys of the material ...
Expand Down
2 changes: 1 addition & 1 deletion include/assimp/material.h
Original file line number Diff line number Diff line change
Expand Up @@ -335,7 +335,7 @@ enum aiTextureType {

// -------------------------------------------------------------------------------
// Get a string for a given aiTextureType
ASSIMP_API const char *TextureTypeToString(enum aiTextureType in);
ASSIMP_API const char *aiTextureTypeToString(enum aiTextureType in);

// ---------------------------------------------------------------------------
/** @brief Defines all shading models supported by the library
Expand Down
2 changes: 1 addition & 1 deletion tools/assimp_cmd/Info.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -441,7 +441,7 @@ int Assimp_Info(const char *const *params, unsigned int num) {
prop->mKey.data,
prop->mIndex,
prop->mDataLength,
TextureTypeToString(textype));
aiTextureTypeToString(textype));
}
}
if (scene->mNumMaterials) {
Expand Down

0 comments on commit e8abb0f

Please sign in to comment.