Yes, I have a bigger texture than 512, like the login background.
Thanks for this, i'll change it :)
here is the code to load textures:
def load_pygame_surface(img):
#Convert a pygame surface into a texture
filter = library.config["filter"]
mipmap = library.config["mipmap"]
img.set_colorkey((255, 0, 255));
t = Tex()
t.width, t.height = size = list(img.get_size())
size[0] = next_pow2(size[0])
size[1] = next_pow2(size[1])
t.tex_coords = (0, t.height / size[1], t.width / size[0], 0)
n = pygame.Surface(size, pygame.SRCALPHA | pygame.HWSURFACE)
n.blit(img, (0, size[1] - t.height))
data = pygame.image.tostring(n, 'RGBA', True)
t.id = rabbyt.load_texture(data, size, "RGBA", filter, mipmap)
return t
then I do myRabbytSprite.texture = t
thanks again!
On Aug 15, 3:10 am, Joseph Marshall <
marshallpeng...@gmail.com> wrote:
> Do you have a custom texture loading hook in place? Or are you using
> rabbyt's default? And are you using pygame or pyglet?
>
> If you want to maintain compatibility with older video cards also make sure
> that your textures do not exceed 512x512. I have found some older cards will
> fail to load textures larger than that.
>
> Joseph
>
> On Sat, Aug 14, 2010 at 7:03 PM,
laetitiak...@hotmail.fr <
>
>
laetitiak...@hotmail.fr> wrote:
> > oh, i forgot to precise:
> > all my textures have a power of 2 height and width.
>
> > --
> > You received this message because you are subscribed to the Google Groups
> > "Rabbyt" group.
> > To post to this group, send email to
rab...@googlegroups.com.
> > To unsubscribe from this group, send email to
> >
rabbyt+un...@googlegroups.com<
rabbyt%2Bunsu...@googlegroups.com>
> > .