Skip to content

Commit ce0a2e2

Browse files
andressbarajasQuzarDC
authored andcommitted
pvr_tex: Remove unused variable opaquepix
1 parent 649e5fe commit ce0a2e2

1 file changed

Lines changed: 3 additions & 4 deletions

File tree

utils/pvrtex/pvr_texture_encoder.c

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -859,7 +859,7 @@ void pteAutoSelectPixelFormat(PvrTexEncoder *pte) {
859859
assert(pte);
860860
assert(pte->src_img_cnt);
861861

862-
unsigned clearpix = 0, halfpix = 0, opaquepix = 0;
862+
unsigned clearpix = 0, halfpix = 0;
863863

864864
for(int j = 0; j < pte->src_img_cnt; j++) {
865865
pteImage *img = pte->src_imgs + j;
@@ -868,10 +868,9 @@ void pteAutoSelectPixelFormat(PvrTexEncoder *pte) {
868868
int a = img->pixels[i].a;
869869
if (a == 0)
870870
clearpix++;
871-
else if (a == 0xff)
872-
opaquepix++;
873-
else
871+
else if (a != 0xff)
874872
halfpix++;
873+
//else: fully opaque, no count needed
875874
}
876875
}
877876

0 commit comments

Comments
 (0)