Forums > Jitter

points texture with .gl.texture bug?


wk
February 8, 2006 | 6:39 pm

hello,

for some reason textures made with .gl.texture doesnt work when drawing
matrix
using points with point_sprite attribute on,
the same texture declared in .gl.render works,

below example patch,

best,
wojciech

max v2;
#N vpatcher 40 130 814 664;
#P window setfont "Sans Serif" 9.;
#P message 15 197 142 196617 point_sprite 1 , point_size 50;
#P message 47 330 34 196617 reset;
#P user com 411 367 239 196617 13;
#K set 0 29797 30836 30066 25888 25701 25452 24946 25956 8297 28192
29285 28260 25970;
#K end;
#P newex 293 157 48 196617 loadbang;
#P newex 86 266 48 196617 loadbang;
#P message 316 366 92 196617 texture circle_lcd;
#P message 316 338 87 196617 texture circle_gl;
#P newex 364 255 219 196617 jit.gl.texture ihu @name circle_gl @dim 50
50;
#P newex 206 256 130 196617 prepend texture circle_lcd;
#P message 206 184 156 196617 clear , paintoval 0 0 49 49 , bang;
#P newex 206 204 99 196617 jit.lcd 4 char 50 50;
#P message 86 297 312 196617 reset , drawmatrix points points ,
texture circle_lcd , point_size 50;
#P newex 86 386 150 196617 jit.gl.sketch ihu @color 1 1 1 1;
#P newex 181 151 85 196617 jit.matrix points;
#P newex 181 77 69 196617 qmetro 1000;
#P newex 181 126 126 196617 jit.expr @expr in[0]*2-1;
#P newex 181 102 113 196617 jit.noise 3 float32 100;
#P newex 76 114 61 196617 t b b erase;
#P newex 76 163 81 196617 jit.gl.render ihu;
#P toggle 76 49 15 0;
#P newex 76 75 51 196617 qmetro 2;
#P newex 86 429 74 196617 jit.window ihu;
#P user com 411 338 239 196617 7;
#K set 0 27241 29742 26476 11892 25976 29813 29285;
#K end;
#P connect 18 0 22 0;
#P connect 3 0 2 0;
#P connect 2 0 5 0;
#P connect 22 0 4 0;
#P connect 14 0 4 0;
#P connect 5 0 4 0;
#P connect 5 2 4 0;
#P connect 18 0 11 0;
#P connect 16 0 10 0;
#P connect 11 0 10 0;
#P connect 21 0 10 0;
#P connect 17 0 10 0;
#P connect 3 0 8 0;
#P connect 8 0 6 0;
#P connect 6 0 7 0;
#P connect 7 0 9 0;
#P connect 5 1 9 0;
#P connect 19 0 13 0;
#P connect 13 0 12 0;
#P connect 12 0 14 0;
#P connect 12 0 15 0;
#P pop;


February 8, 2006 | 8:34 pm

I might suggest you try turning off rectangular textures (i.e.
@rectangle 0). This will use power of two textures, which might be
required for point sprites on your HW. This difference in rectangular
vs power of two textures is the big difference between the default
jit.gl.render textures (for legacy purposes), and the default
jit.gl.texture.

Let us know if that doesn’t solve your problems and we can look into
your patch further.

-Joshua



wk
February 8, 2006 | 10:48 pm

thanks joshua,

it helped indeed,

best,
wojciech


Viewing 3 posts - 1 through 3 (of 3 total)