Permalink
Browse files

Vertex program textures work again.

  • Loading branch information...
1 parent 1a637cb commit 4dae1b4c7b4724f31f8d1ffde9cc55cd31234799 @gzorin committed Jul 24, 2012
Showing with 5 additions and 6 deletions.
  1. +2 −2 src/samples/rsxgltest/Makefile.am
  2. +1 −2 src/samples/rsxgltest/cube.vert
  3. +2 −2 src/samples/rsxgltest/manycubes.cc
@@ -72,8 +72,8 @@ copyteximage_sources = copyteximage.cc texture.c fbo_inner.vert fbo_inner.frag n
feedback_objects = nagel_bin.o gradient_png.o face_png.o
feedback_sources = feedback.cc texture.c texcube.vert texcube.frag nagel.bin face.png gradient.png
-objects = $(manypoints_objects)
-sources = $(manypoints_sources)
+objects = $(manycubes_objects)
+sources = $(manycubes_sources)
rsxgltest_elf_DEPENDENCIES = $(top_builddir)/src/library/libEGL.a $(top_builddir)/src/library/libGL.a \
$(objects)
@@ -26,8 +26,7 @@ main(void)
texture1D(texture,i + _delta2),
texture1D(texture,i + _delta3));
- //gl_Position = ProjMatrix * (TransMatrix * m * vec4(position,1));
- gl_Position = ProjMatrix * (TransMatrix * vec4(position,1));
+ gl_Position = ProjMatrix * (TransMatrix * m * vec4(position,1));
c = vec3(0.5,0.5,0.5);
}
@@ -82,7 +82,7 @@ Eigen::Affine3f ViewMatrixInv =
)
).inverse();
-const GLuint ncubes = 10;
+const GLuint ncubes = 100;
extern "C"
void
@@ -312,7 +312,7 @@ rsxgltest_init(int argc,const char ** argv)
memcpy(ptmp,m.data(),sizeof(float) * 16);
}
- glTexSubImage1D(GL_TEXTURE_1D,0,0,ncubes * 4,GL_BGRA,GL_FLOAT,tmp);
+ glTexSubImage1D(GL_TEXTURE_1D,0,0,ncubes * 4,GL_RGBA,GL_FLOAT,tmp);
delete [] tmp;
}

0 comments on commit 4dae1b4

Please sign in to comment.