mirror of
https://github.com/JulianGro/overte.git
synced 2025-04-25 18:55:01 +02:00
snapshot referenced locally, won't work on OS
This commit is contained in:
parent
cc4bafb46f
commit
f71d9e4d6a
7 changed files with 10 additions and 7 deletions
|
@ -183,7 +183,7 @@ Windows.ScrollingWindow {
|
|||
|
||||
if (defaultURL.endsWith(".jpg") || defaultURL.endsWith(".png")) {
|
||||
var name = assetProxyModel.data(treeView.selection.currentIndex);
|
||||
var modelURL = "https://hifi-content.s3.amazonaws.com/elisalj/image_entity/snapshot.fbx";
|
||||
var modelURL = "qrc:///snapshot/snapshot.fbx";
|
||||
var textures = JSON.stringify({ "tex.picture": defaultURL});
|
||||
var shapeType = "box";
|
||||
var dynamic = false;
|
||||
|
|
|
@ -184,7 +184,7 @@ Rectangle {
|
|||
|
||||
if (defaultURL.endsWith(".jpg") || defaultURL.endsWith(".png")) {
|
||||
var name = assetProxyModel.data(treeView.selection.currentIndex);
|
||||
var modelURL = "https://hifi-content.s3.amazonaws.com/elisalj/image_entity/snapshot.fbx";
|
||||
var modelURL = "qrc:///snapshot/snapshot.fbx";
|
||||
var textures = JSON.stringify({ "tex.picture": defaultURL});
|
||||
var shapeType = "box";
|
||||
var dynamic = false;
|
||||
|
|
BIN
interface/resources/snapshot/snapshot.fbx
Normal file
BIN
interface/resources/snapshot/snapshot.fbx
Normal file
Binary file not shown.
|
@ -6525,7 +6525,7 @@ void Application::addAssetToWorldAddEntity(QString filePath, QString mapping) {
|
|||
QJsonObject textures {
|
||||
{"tex.picture", QString("atp:" + mapping) }
|
||||
};
|
||||
properties.setModelURL("https://hifi-content.s3.amazonaws.com/elisalj/image_entity/snapshot.fbx");
|
||||
properties.setModelURL("qrc:///snapshot/snapshot.fbx");
|
||||
properties.setTextures(QJsonDocument(textures).toJson(QJsonDocument::Compact));
|
||||
properties.setShapeType(SHAPE_TYPE_BOX);
|
||||
} else {
|
||||
|
|
|
@ -548,9 +548,9 @@ var toolBar = (function () {
|
|||
z: 2.58
|
||||
},
|
||||
shapeType: "box",
|
||||
modelURL: "https://hifi-content.s3.amazonaws.com/elisalj/image_entity/snapshot.fbx",
|
||||
modelURL: 'qrc:///snapshot/snapshot.fbx',
|
||||
// change to another default image
|
||||
textures: JSON.stringify({ "tex.picture": "https://hifi-content.s3.amazonaws.com/elisalj/image_entity/dog.jpg" })
|
||||
textures: JSON.stringify({ "tex.picture": 'qrc:///snapshot/img/no-image.jpg' })
|
||||
});
|
||||
});
|
||||
|
||||
|
|
|
@ -156,7 +156,9 @@ function loaded() {
|
|||
var urlParts = url.split('/');
|
||||
var filename = urlParts[urlParts.length - 1];
|
||||
|
||||
if (url === "https://hifi-content.s3.amazonaws.com/elisalj/image_entity/snapshot.fbx") {
|
||||
var snapURL = 'qrc:///snapshot/snapshot.fbx';
|
||||
|
||||
if (url === snapURL) {
|
||||
type = "Image";
|
||||
}
|
||||
|
||||
|
|
|
@ -797,7 +797,8 @@ function loaded() {
|
|||
elID.value = properties.id;
|
||||
|
||||
// HTML workaround since image is not yet a separate entity type
|
||||
if (properties.type === "Model" && properties.modelURL === "https://hifi-content.s3.amazonaws.com/elisalj/image_entity/snapshot.fbx") {
|
||||
var snapURL = 'qrc:///snapshot/snapshot.fbx';
|
||||
if (properties.type === "Model" && properties.modelURL === snapURL) {
|
||||
properties.type = "Image";
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue