Fix bug where power-of-two textures were showing up black in Carousel.
Change-Id: Id1a578f63e137eadca4bb1419863fcd2db154dcb
diff --git a/carousel/java/com/android/ex/carousel/CarouselRS.java b/carousel/java/com/android/ex/carousel/CarouselRS.java
index 53c2415..f655b9e 100644
--- a/carousel/java/com/android/ex/carousel/CarouselRS.java
+++ b/carousel/java/com/android/ex/carousel/CarouselRS.java
@@ -63,7 +63,6 @@
private ScriptC_Carousel mScript;
private ScriptField_Card mCards;
private Sampler mSampler;
- private ProgramRaster mProgramRaster;
private ProgramStore mProgramStore;
private ProgramFragment mFragmentProgram;
private ProgramVertex mVertexProgram;
@@ -276,7 +275,7 @@
private void initFragmentProgram() {
Sampler.Builder sampleBuilder = new Sampler.Builder(mRS);
- sampleBuilder.setMin(Value.LINEAR_MIP_LINEAR);
+ sampleBuilder.setMin(Value.LINEAR);
sampleBuilder.setMag(LINEAR);
sampleBuilder.setWrapS(CLAMP);
sampleBuilder.setWrapT(CLAMP);
diff --git a/carousel/test/src/com/android/carouseltest/CarouselTestActivity.java b/carousel/test/src/com/android/carouseltest/CarouselTestActivity.java
index fe77022..a12c76d 100644
--- a/carousel/test/src/com/android/carouseltest/CarouselTestActivity.java
+++ b/carousel/test/src/com/android/carouseltest/CarouselTestActivity.java
@@ -44,8 +44,8 @@
private static final int HOLDOFF_DELAY = 0;
private static final int CARD_SLOTS = 56;
private static final int TOTAL_CARDS = 1000;
- private static final int TEXTURE_HEIGHT = 511;
- private static final int TEXTURE_WIDTH = 511;
+ private static final int TEXTURE_HEIGHT = 512;
+ private static final int TEXTURE_WIDTH = 512;
private static final String TAG = "CarouselTestActivity";
private static final int SLOTS_VISIBLE = 7;