mirror of
https://github.com/overte-org/overte.git
synced 2025-08-08 11:58:10 +02:00
moved code to set _textureContent to ModelBaker class
This commit is contained in:
parent
d7f2e21dca
commit
8d3f11a990
2 changed files with 1 additions and 7 deletions
|
@ -356,12 +356,6 @@ void FBXBaker::rewriteAndBakeSceneTextures() {
|
||||||
|
|
||||||
if (textureChild.name == "RelativeFilename") {
|
if (textureChild.name == "RelativeFilename") {
|
||||||
QString fbxTextureFileName { textureChild.properties.at(0).toByteArray() };
|
QString fbxTextureFileName { textureChild.properties.at(0).toByteArray() };
|
||||||
QFileInfo fbxTextureFileInfo { fbxTextureFileName.replace("\\", "/") };
|
|
||||||
|
|
||||||
QByteArray textureContent = "";
|
|
||||||
if (!fbxTextureFileInfo.filePath().isEmpty()) {
|
|
||||||
textureContent = _textureContent.value(fbxTextureFileName.toLocal8Bit());
|
|
||||||
}
|
|
||||||
|
|
||||||
// Callback to get texture type
|
// Callback to get texture type
|
||||||
getTextureTypeCallback textureTypeCallback = [=]() {
|
getTextureTypeCallback textureTypeCallback = [=]() {
|
||||||
|
|
|
@ -216,7 +216,7 @@ bool ModelBaker::compressMesh(FBXMesh& mesh, bool hasDeformers,FBXNode& dracoMes
|
||||||
|
|
||||||
QByteArray* ModelBaker::compressTexture(QString modelTextureFileName, getTextureTypeCallback textureTypeCallback) {
|
QByteArray* ModelBaker::compressTexture(QString modelTextureFileName, getTextureTypeCallback textureTypeCallback) {
|
||||||
static QByteArray textureChild;
|
static QByteArray textureChild;
|
||||||
QByteArray textureContent;
|
QByteArray textureContent = "";
|
||||||
image::TextureUsage::Type textureType;
|
image::TextureUsage::Type textureType;
|
||||||
|
|
||||||
if (textureTypeCallback) {
|
if (textureTypeCallback) {
|
||||||
|
|
Loading…
Reference in a new issue