def send_plo_state_change(brush):
    import liblo
    
    states = [float(i) for i in brush.get_state()]
    #print states
    
    target = liblo.Address(*get_plo_target())
    try:
        liblo.send(target, "/plo/mypaint/brush/states_changed", *states)
    except Exception, e:
        print e
Exemple #2
0
    def start_recording(self, brush):
        assert not self.finished

        self.brush_settings = brush.brushinfo.save_to_string() # fast (brush caches this string)

        states = brush.get_state()
        assert states.dtype == 'float32'
        self.brush_state = states.tostring()

        self.brush = brush
        self.brush.new_stroke() # this just resets the stroke_* members of the brush

        self.tmp_event_list = []
Exemple #3
0
    def start_recording(self, brush):
        assert not self.finished

        self.brush_settings = brush.brushinfo.save_to_string() # fast (brush caches this string)

        states = brush.get_state()
        assert states.dtype == 'float32'
        self.brush_state = states.tostring()

        self.brush = brush
        self.brush.new_stroke() # this just resets the stroke_* members of the brush

        self.tmp_event_list = []
Exemple #4
0
    def start_recording(self, brush):
        assert not self.finished

        bi = brush.brushinfo
        self.brush_settings = bi.save_to_string()
        self.brush_name = bi.get_string_property("parent_brush_name")

        states = brush.get_state()
        assert states.dtype == 'float32'
        self.brush_state = states.tostring()

        self.brush = brush
        self.brush.new_stroke()  # resets the stroke_* members of the brush

        self.tmp_event_list = []
Exemple #5
0
    def start_recording(self, brush):
        assert not self.finished

        bi = brush.brushinfo
        self.brush_settings = bi.save_to_string()
        self.brush_name = bi.get_string_property("parent_brush_name")

        states = brush.get_state()
        assert states.dtype == 'float32'
        self.brush_state = states.tostring()

        self.brush = brush
        self.brush.new_stroke()  # resets the stroke_* members of the brush

        self.tmp_event_list = []