Ejemplo n.º 1
0
    def __init__(self, *args, **kwargs):
        """ Draw a dummy actor for testing
                
        """
        super(Dummy, self).__init__()

        self.batch = Batch()

        fos.lib.pyglet.text.Label(
            'Hello, world',
            font_name='Times New Roman',
            font_size=36,
            dpi=250,
            #                                  x=window.width//2, y=window.height//2,
            anchor_x='center',
            anchor_y='center',
            batch=self.batch)
        fos.lib.pyglet.text.Label(
            'Hi',
            font_name='Times New Roman',
            font_size=26,
            dpi=100,
            #                                  x=window.width//2, y=window.height//2,
            anchor_x='center',
            anchor_y='center',
            batch=self.batch)
Ejemplo n.º 2
0
class Dummy(Actor):
    def __init__(self, *args, **kwargs):
        """ Draw a dummy actor for testing
                
        """
        super(Dummy, self).__init__()

        self.batch = Batch()

        fos.lib.pyglet.text.Label(
            'Hello, world',
            font_name='Times New Roman',
            font_size=36,
            dpi=250,
            #                                  x=window.width//2, y=window.height//2,
            anchor_x='center',
            anchor_y='center',
            batch=self.batch)
        fos.lib.pyglet.text.Label(
            'Hi',
            font_name='Times New Roman',
            font_size=26,
            dpi=100,
            #                                  x=window.width//2, y=window.height//2,
            anchor_x='center',
            anchor_y='center',
            batch=self.batch)

    def update(self, dt):
        pass

    def draw(self):
        pass
        glPushMatrix()
        #glRotatef(5.0, 0, 1, 0)
        glTranslatef(-100, 0, 0)
        self.batch.draw()
        glPopMatrix()
Ejemplo n.º 3
0
Archivo: labels.py Proyecto: arokem/Fos
class Dummy(Actor):
    
    def __init__(self, *args, **kwargs):
        """ Draw a dummy actor for testing
                
        """
        super(Dummy, self).__init__()
        
        self.batch = Batch()
        
        fos.lib.pyglet.text.Label('Hello, world', 
                                  font_name='Times New Roman', 
                                  font_size=36,
                                  dpi=250,
#                                  x=window.width//2, y=window.height//2,
                                  anchor_x='center', anchor_y='center',
                                  batch = self.batch)
        fos.lib.pyglet.text.Label('Hi', 
                                  font_name='Times New Roman', 
                                 font_size=26,
                                  dpi=100,
#                                  x=window.width//2, y=window.height//2,
                                  anchor_x='center', anchor_y='center',
                                  batch = self.batch)
        
        
    def update(self, dt):
        pass
        
    def draw(self):
        pass
        glPushMatrix()
        #glRotatef(5.0, 0, 1, 0)
        glTranslatef(-100,0,0)
        self.batch.draw()
        glPopMatrix()
Ejemplo n.º 4
0
Archivo: labels.py Proyecto: arokem/Fos
    def __init__(self, *args, **kwargs):
        """ Draw a dummy actor for testing
                
        """
        super(Dummy, self).__init__()
        
        self.batch = Batch()
        
        fos.lib.pyglet.text.Label('Hello, world', 
                                  font_name='Times New Roman', 
                                  font_size=36,
                                  dpi=250,
#                                  x=window.width//2, y=window.height//2,
                                  anchor_x='center', anchor_y='center',
                                  batch = self.batch)
        fos.lib.pyglet.text.Label('Hi', 
                                  font_name='Times New Roman', 
                                 font_size=26,
                                  dpi=100,
#                                  x=window.width//2, y=window.height//2,
                                  anchor_x='center', anchor_y='center',
                                  batch = self.batch)