jit.gl.texture @wrap bug?
I'm using an array of js instantiated jit.gl.textures @rectangle 0. The
default wrapping mode for power-of-two textures is "repeat". When I change
the wrap attribute of all textures (i.e. mirroredrepeat or clampedge), most
of them are changed accordingly but some others stick to "repeat". I can try
to set this attribute over and over, but the ones that stick always stick. I
guess somethings gone wrong at construction time.(?)
function wrap(s)
{
var tmp = s;
for(var k=0; k
{
hObjects[k].wrap = tmp;
post("tex_container set wrap for "+k+"n");
}
}
from checking the max window nObj is correct, and all textures should be
changed. I also know that the hObjects[] array is correct because I use
these handles to reference the textures for other functions that work
without problems.
This is the function I use to create and setup the jit.gl.textures. Even if
I set it default to "mirroredrepeat" at the setup, the problem remains. All
other attibutes like name and file work correctly.
function setup()
{
for(var k=0; k
{
hObjects[k] = new JitterObject("jit.gl.texture", context);
hObjects[k].name = id+"."+k;
hObjects[k].automatic = 0;
hObjects[k].rectangle = 0;
hObjects[k].wrap = "mirroredrepeat";
hObjects[k].file = texPath+textlines[k];
}
outlet(0,["count", nObj]);
}
Any ideas?
-thijs
I'm seeing correct behavior in my tests with the latest devlopment
build, as testing with jit.gl.texture.help + jit.gl.gridshape
@tex_map 1. Can you verify this on your machine + also perhaps
provide a more complete, but simple example to illustrate?
Thanks,
-Joshua
Hi Joshua,
The helpfile works correct on my machine too. It only occurs with multiple
instances of jit.gl.texture. I also checked if there is some kind of logical
pattern to it, but it appears to be totally random. I'll try to provide a
simple test patch in the following days.
best, thijs