mirror of
https://git.mirrors.martin98.com/https://github.com/syoyo/tinygltf.git
synced 2025-08-14 15:55:55 +08:00
Import texture names as well.
Every other structure has it already.
This commit is contained in:
parent
39abfb5f91
commit
239be2c09f
@ -456,6 +456,8 @@ struct Image {
|
||||
};
|
||||
|
||||
struct Texture {
|
||||
std::string name;
|
||||
|
||||
int sampler;
|
||||
int source; // Required (not specified in the spec ?)
|
||||
Value extras;
|
||||
@ -2224,6 +2226,8 @@ static bool ParseTexture(Texture *texture, std::string *err, const json &o,
|
||||
ParseExtensionsProperty(&texture->extensions, err, o);
|
||||
ParseExtrasProperty(&texture->extras, o);
|
||||
|
||||
ParseStringProperty(&texture->name, err, o, "name", false);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user