Skip to content

Commit

Permalink
fix data type on texture load from int32_t* and uint32_t* (#6257)
Browse files Browse the repository at this point in the history
#changelog #gl
  • Loading branch information
shenberg authored and arturoc committed Mar 18, 2019
1 parent 021e1a2 commit eb1f22f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions libs/openFrameworks/gl/ofTexture.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -557,7 +557,7 @@ void ofTexture::loadData(const uint16_t * data, int w, int h, int glFormat){
//----------------------------------------------------------
void ofTexture::loadData(const uint32_t * data, int w, int h, int glFormat){
ofSetPixelStoreiAlignment(GL_UNPACK_ALIGNMENT,w,2,ofGetNumChannelsFromGLFormat(glFormat));
loadData(data, w, h, glFormat, GL_SHORT);
loadData(data, w, h, glFormat, GL_UNSIGNED_INT);
}

//----------------------------------------------------------
Expand All @@ -575,7 +575,7 @@ void ofTexture::loadData(const int16_t * data, int w, int h, int glFormat){
//----------------------------------------------------------
void ofTexture::loadData(const int32_t * data, int w, int h, int glFormat){
ofSetPixelStoreiAlignment(GL_UNPACK_ALIGNMENT,w,2,ofGetNumChannelsFromGLFormat(glFormat));
loadData(data, w, h, glFormat, GL_SHORT);
loadData(data, w, h, glFormat, GL_INT);
}

//----------------------------------------------------------
Expand Down

0 comments on commit eb1f22f

Please sign in to comment.