def run(self):
        while not rospy.is_shutdown() and self._created:
            #Update the image in the window
            basic_header.showFrame(self.title, self.frame)

            #Get keyboard input
            key = cv2.waitKey(200) #Specify timeout. Used to regulate loop speed

            #If key == ESC end program
            if key == 27:
                self.end()
    def run(self):
        while not rospy.is_shutdown() and self._created:
            #Draw pixel regions on the image
            self.drawObjectBoundaries()

            #Update the image in the window
            basic_header.showFrame(self.title, self.frame)

            #Get keyboard input
            key = cv2.waitKey(
                200)  #Specify timeout. Used to regulate loop speed

            #If Any key end program
            if key != 255:
                self.end()
    def run(self):
        contour_colour = (0, 255, 0)
        while not rospy.is_shutdown() and self._created:
            #Draw pixel regions on the image
            self.drawPixelRegions(self.pixel_regions)

            #Empty pixel regions buffer
            self.pixel_regions = []

            #Update the image in the window
            basic_header.showFrame(self.title, self.frame)

            #Get keyboard input
            key = cv2.waitKey(
                300)  #Specify timeout. Used to regulate loop speed

            #If key == ESC end program
            if key == 27:
                self.end()
Exemple #4
0
 def updateView(self, rgb_mode=True):
     if self.created:
         basic_header.showFrame(self.title, self.frame, rgb_mode)
         key = cv2.waitKey(300)
         if key == 27:
             self.end()