コード例 #1
0
ファイル: GUI.py プロジェクト: igarag/Academy
    def __init__(self, camera, parent=None):
        super(MainWindow, self).__init__(parent)
        self.setupUi(self)

        self.camera = camera

        self.logo = LogoWidget(self,
                               self.logoLayout.parent().width(),
                               self.logoLayout.parent().height())
        self.logoLayout.addWidget(self.logo)
        self.logo.setVisible(True)

        self.updGUI.connect(self.updateGUI)

        self.cameraCheck.stateChanged.connect(self.showCameraWidget)
        self.colorFilterCheck.stateChanged.connect(self.showColorFilterWidget)

        self.cameraWidget = CameraWidget(self)
        self.colorFilterWidget = ColorFilterWidget(self)

        self.cameraCommunicator = Communicator()
        self.colorFilterCommunicator = Communicator()
        self.trackingCommunicator = Communicator()

        self.playButton.clicked.connect(self.playClicked)
        self.playButton.setCheckable(True)
コード例 #2
0
    def __init__(self, parent=None):
        super(MainWindow, self).__init__(parent)
        self.setupUi(self)
        self.teleop = TeleopWidget(self)
        self.tlLayout.addWidget(self.teleop)
        self.teleop.setVisible(True)

        self.record = False

        self.updGUI.connect(self.updateGUI)

        self.cameraCheck.stateChanged.connect(self.showCameraWidget)
        self.sensorsCheck.stateChanged.connect(self.showSensorsWidget)

        self.rotationDial.valueChanged.connect(self.rotationChange)
        self.altdSlider.valueChanged.connect(self.altitudeChange)

        self.cameraWidget = CameraWidget(self)
        self.sensorsWidget = SensorsWidget(self)

        self.cameraCommunicator = Communicator()
        self.trackingCommunicator = Communicator()

        self.stopButton.clicked.connect(self.stopClicked)
        self.playButton.clicked.connect(self.playClicked)
        self.resetButton.clicked.connect(self.resetClicked)
        self.takeoffButton.clicked.connect(self.takeOffClicked)
        self.takeoff = False
        self.reset = False
コード例 #3
0
    def __init__(self, parent=None):
        super(MainWindow, self).__init__(parent)
        self.setupUi(self)
        self.teleop = TeleopWidget(self)
        self.tlLayout.addWidget(self.teleop)
        self.teleop.setVisible(True)

        self.logo = LogoWidget(self,
                               self.logoLayout.parent().width(),
                               self.logoLayout.parent().height())
        self.logoLayout.addWidget(self.logo)
        self.logo.setVisible(True)

        self.record = False

        self.updGUI.connect(self.updateGUI)

        self.segmentCheck.stateChanged.connect(self.showSegmentWidget)

        self.segmentWidget = SegmentWidget(self)

        self.segmentCommunicator = Communicator()
        self.trackingCommunicator = Communicator()

        #self.stopButton.clicked.connect(self.stopClicked)
        self.playButton.clicked.connect(self.playClicked)
        self.playButton.setCheckable(True)
        self.resetButton.clicked.connect(self.resetClicked)
        self.takeoff = False
        self.reset = False
コード例 #4
0
    def __init__(self, parent=None):

        super().__init__()

        self.setGeometry(300, 300, 300, 500)
        self.setWindowTitle('SSDcomponent')
        self.setWindowIcon(QIcon(path))

        # BUTTON
        TestButton = QPushButton("Evaluar")
        TestButton.clicked.connect(self.effect)

        # AUXILIAR IMAGE
        self.imgLabel = QLabel(self)
        image = cv2.imread('logoJdeRobot.png', 1)
        image = cv2.cvtColor(image, cv2.COLOR_BGR2RGB)
        imgDef = QImage(image.data, image.shape[1], image.shape[0],
                        QImage.Format_RGB888)
        self.imgLabel.setPixmap(QPixmap.fromImage(imgDef))

        # IMAGE PRINCIPAL
        self.imgPrincipal = QLabel(self)

        # Configuracion BOX
        vbox = QVBoxLayout()
        vbox.addWidget(self.imgPrincipal)
        vbox.addWidget(self.imgLabel)
        vbox.addWidget(TestButton)
        self.setLayout(vbox)

        # Necesario
        self.cameraCommunicator = Communicator()
        self.trackingCommunicator = Communicator()
        self.show()
コード例 #5
0
    def __init__(self, parent=None):
        super(MainWindow, self).__init__(parent)
        self.setupUi(self)
        self.teleop = TeleopWidget(self)
        self.tlLayout.addWidget(self.teleop)
        self.teleop.setVisible(True)

        self.updGUI.connect(self.updateGUI)

        self.cameraWidget = CameraWidget(self)

        self.cameraCommunicator = Communicator()
        self.trackingCommunicator = Communicator()
コード例 #6
0
ファイル: GUI.py プロジェクト: zhangxuelei86/RoboticsAcademy
    def __init__(self, camera, parent=None):
        super(MainWindow, self).__init__(parent)
        self.setupUI(self)

        self.camera = camera

        self.updGUI.connect(self.updateImage)
        self.updGUI.connect(self.updateCamImage)

        self.cameraCommunicator = Communicator()
        self.colorFilterCommunicator = Communicator()
        self.trackingCommunicator = Communicator()

        self.playButton.clicked.connect(self.playClicked)
        self.playButton.setCheckable(True)
コード例 #7
0
    def __init__(self, parent=None):
        super(MainWindow, self).__init__(parent)
        self.setupUi(self)
        self.teleop = TeleopWidget(self)
        self.tlLayout.addWidget(self.teleop)
        self.teleop.setVisible(True)
        self.logo = LogoWidget(self,
                               self.logoLayout.parent().width(),
                               self.logoLayout.parent().height())
        self.logoLayout.addWidget(self.logo)
        self.logo.setVisible(True)

        self.updGUI.connect(self.updateGUI)
        self.sensorsCheck.stateChanged.connect(self.showSensorsWidget)

        self.rotationDial.valueChanged.connect(self.rotationChange)
        self.altdSlider.valueChanged.connect(self.altitudeChange)

        self.cameraWidget = ColorFilterWidget(self)
        self.sensorsWidget = SensorsWidget(self)
        self.changeCamButton.clicked.connect(self.changeCamera)

        self.trackingCommunicator = Communicator()

        self.pushButton.clicked.connect(self.pushClicked)
        self.pushButton.setCheckable(True)
        self.resetButton.clicked.connect(self.resetClicked)
        self.takeoffButton.clicked.connect(self.takeOffClicked)
        self.camera1 = CameraWidget(self)

        self.takeoff = False
        self.reset = False
        self.record = False
コード例 #8
0
    def __init__(self, parent=None):

        super().__init__()

        # Directories
        self.setGeometry(300, 300, 1000, 1000)
        self.setWindowTitle('Compare')
        self.setWindowIcon(QIcon(path))

        # BUTTONs
        TestButton = QPushButton("Previous")
        TestButton.clicked.connect(self.effect1)

        TestButton2 = QPushButton("Next")
        TestButton2.clicked.connect(self.effect2)

        # AUXILIAR IMAGE
        self.imgLabel = QLabel(self)
        image = cv2.imread('logoJdeRobot.png', 1)
        image = cv2.cvtColor(image, cv2.COLOR_BGR2RGB)
        imgDef = QImage(image.data, image.shape[1], image.shape[0],
                        QImage.Format_RGB888)
        self.imgLabel.setPixmap(QPixmap.fromImage(imgDef))

        # Configuracion BOX
        vbox = QVBoxLayout()
        vbox.addWidget(self.imgLabel)

        hbox = QHBoxLayout()
        hbox.addWidget(TestButton)
        hbox.addWidget(TestButton2)
        vbox.addLayout(hbox)

        self.setLayout(vbox)

        # Necesario
        self.cameraCommunicator = Communicator()
        self.trackingCommunicator = Communicator()
        self.show()