mirror of
https://github.com/Linloir/SceneEditor.git
synced 2025-12-17 07:28:12 +08:00
Fix model loading
- Fix texture path storing full path instead of texture name making the texture loaded check always fail
This commit is contained in:
parent
b6b0da76d4
commit
c911ac1613
@ -13,7 +13,7 @@ QOpenGLContext* sharedContext;
|
||||
// Must set context before calling this function
|
||||
Texture::Texture(TextureType type, std::string path) {
|
||||
_type = type;
|
||||
_path = path;
|
||||
_path = path.substr(path.find_last_of('/') + 1);
|
||||
|
||||
OPENGL_FUNCTIONS->glGenTextures(1, &_id);
|
||||
OPENGL_FUNCTIONS->glBindTexture(GL_TEXTURE_2D, _id);
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user