Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Deserialize raises GLTFException: Unknown Schema uri glTFProperty.schema.jso #72

Open
SpaceIm opened this issue Feb 13, 2021 · 3 comments
Labels
bug Something isn't working good first issue Good for newcomers help wanted Extra attention is needed

Comments

@SpaceIm
Copy link

SpaceIm commented Feb 13, 2021

I'm trying to package gltf-SDK 1.9.5.0 for conan (with minimal modifications like std::powf replaced by std::pow, unvendoring of rapidjson, fix of installation folders).

I've written a simple cpp file, based on the tests in SerializeTests.cpp to see that produced package makes sense:

#include <GLTFSDK/GLTF.h>
#include <GLTFSDK/Deserialize.h>
#include <GLTFSDK/Document.h>
#include <GLTFSDK/Math.h>
#include <GLTFSDK/Serialize.h>

#include <utility>

int main() {
  Microsoft::glTF::Document originalDoc;

  Microsoft::glTF::Scene sc;
  sc.id = "0";
  sc.nodes = { "0" };
  originalDoc.SetDefaultScene(std::move(sc));

  Microsoft::glTF::Node matrixNode;
  matrixNode.id = "0";
  matrixNode.name = "matrixNode";
  matrixNode.matrix = Microsoft::glTF::Matrix4::IDENTITY;
  originalDoc.nodes.Append(std::move(matrixNode));

  auto outputString = Microsoft::glTF::Serialize(originalDoc);
  auto twoPassDoc = Microsoft::glTF::Deserialize(outputString);
  return 0;
}

GLTFException: Unknown Schema uri glTFProperty.schema.jso (without the "n") is raided in Microsoft::glTF::Deserialize (tested on Windows with gcc 7 and 8, Visual Studio 2015/2017/2019, and on Macos with apple-clang 12).

@bghgary
Copy link
Contributor

bghgary commented Feb 17, 2021

I'm not sure if there is a question here. Looks like there is an issue with the schema uri. Have you debugged the code?

@orzel7
Copy link

orzel7 commented Sep 26, 2021

I have the same issue while trying to run GLTFSDK.Samples/Deserialize example. gcc version 9.3.0 (Ubuntu 9.3.0-17ubuntu1~20.04)

@orzel7
Copy link

orzel7 commented Sep 26, 2021

I can run the example by disabling schema validation: Deserialize(manifest, DeserializeFlags::None, SchemaFlags::DisableSchemaRoot);

@bghgary bghgary added bug Something isn't working help wanted Extra attention is needed triaged good first issue Good for newcomers labels Dec 7, 2023
@thomlucc thomlucc removed the triaged label Sep 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working good first issue Good for newcomers help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

4 participants