Fixing the non loading of some texture because the QImage bit size is not exactly what's expected

This commit is contained in:
Sam Gateau 2015-01-29 15:24:36 -08:00
parent b2f16be92a
commit ec54ac7401

View file

@ -56,8 +56,6 @@ void ImageOverlay::setImageURL(const QUrl& url) {
}
void ImageOverlay::render(RenderArgs* args) {
QString problem("http://s3.amazonaws.com/hifi-public/images/tools/grid-toolbar.svg");
bool theONE = (_imageURL == problem);
if (!_isLoaded && _renderImage) {
_isLoaded = true;
_texture = DependencyManager::get<TextureCache>()->getTexture(_imageURL);
@ -70,17 +68,8 @@ void ImageOverlay::render(RenderArgs* args) {
}
if (_renderImage) {
glEnable(GL_TEXTURE_2D);
if (theONE) {
std::string name = _imageURL.toString().toStdString();
}
GLuint texID = _texture->getID();
if (texID == 27) {
std::string name = _imageURL.toString().toStdString();
glBindTexture(GL_TEXTURE_2D, texID);
} else
glBindTexture(GL_TEXTURE_2D, _texture->getID());
glBindTexture(GL_TEXTURE_2D, _texture->getID());
}
const float MAX_COLOR = 255.0f;