| 70 | } |
| 71 | |
| 72 | void ImageComponent::setImage(std::string path) |
| 73 | { |
| 74 | mPath = path; |
| 75 | |
| 76 | if(mPath.empty() || !mWindow->getResourceManager()->fileExists(mPath)) |
| 77 | mTexture.reset(); |
| 78 | else |
| 79 | mTexture = TextureResource::get(*mWindow->getResourceManager(), mPath); |
| 80 | |
| 81 | resize(); |
| 82 | } |
| 83 | |
| 84 | void ImageComponent::setOrigin(float originX, float originY) |
| 85 | { |
no test coverage detected