Yeap, now I can do:

Yeah that's good, now I can do something like:

def pixel_sprite(filename):
        
        image = pyglet.resource.image(filename)
        
        glTexParameteri(image.texture.target,
            GL_TEXTURE_MAG_FILTER, GL_NEAREST)
        glTexParameteri(image.texture.target,
            GL_TEXTURE_MIN_FILTER, GL_NEAREST)
        
        return cocos.sprite.Sprite(image)


class Base(cocos.layer.ColorLayer):
    def __init__(self):
        super(HelloWorld, self).__init__(64,64,224,255)
        
        sprite = pixel_sprite('filename.png')
        
        sprite.scale = 5
        
        self.add(sprite)
        
Thanks!

-- 
You received this message because you are subscribed to the Google Groups 
"cocos2d discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/cocos-discuss.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to