59 def report(self, outimg, helper, overlay, idle):
85 if helper
is not None and overlay
and self.
rgba_map is not None and self.
pp is not None:
87 iw, ih = self.
pp.imagesize()
90 if self.
left < -0.9e20:
92 self.
right = 0.75 * iw
99 self.
left = max(siz, min(iw - siz * 2, self.
left))
105 blob_left, blob_top = self.
pp.i2b(self.
left, 0.0, 0)
106 blob_right, blob_bot = self.
pp.i2b(self.
right, ih, 0)
109 ovl[:, :int(blob_left), 3] = 0
110 ovl[:, int(blob_right):, 3] = 0
113 tl = helper.i2d(self.
tlx, self.
tly,
"c")
114 wh = helper.i2ds(self.
cw, self.
ch,
"c")
117 helper.drawImage(
"r", ovl,
True, int(tl.x), int(tl.y), int(wh.x), int(wh.y),
False,
True)
121 ovbot = self.
tly + self.
ch
122 ovmid = 0.5 * (ovtop + ovbot)
124 helper.drawLine(self.
left, ovtop, self.
left, ovbot, col)
125 helper.drawRect(self.
left - siz, ovmid - siz/2, self.
left, ovmid + siz/2, col,
True)
126 helper.drawLine(self.
right, ovtop, self.
right, ovbot, col)
127 helper.drawRect(self.
right, ovmid - siz/2, self.
right + siz, ovmid + siz/2, col,
True)
130 mp = helper.getMousePos()
131 ip = helper.d2i(mp.x, mp.y,
"c")
133 if helper.isMouseClicked(0):
135 if ip.x > self.
left-siz
and ip.x < self.
left and ip.y > (ih - siz)/2
and ip.y < (ih + siz)/2:
138 if ip.x > self.
right and ip.x < self.
right+siz
and ip.y > (ih - siz)/2
and ip.y < (ih + siz)/2:
141 if helper.isMouseDragging(0):
146 if helper.isMouseReleased(0):