minor clean up
minorclean
correcting tiling when image dimension is less than max texture size