예제 #1
0
    def __init__(self, parent, FNandARG):
        super(Vivaldi_window, self).__init__()

        _, self.func_name, self.args = FNandARG
        #print "\n\n\n\n\n\n\n", self.args[4][0], "\n\n\n\n\n\n\n"
        self.inBox_val = 0
        self.widget = Vivaldi_widget(self, self.args[2])

        global trans_on, transN, slider_on
        if trans_on == False:
            self.setGeometry(200, 100, self.widget.width,
                             self.widget.height + 30)
        else:
            self.setGeometry(200, 100, self.widget.width + 420,
                             self.widget.height + 30)
        if trans_on == True:
            self.TFF = VTF.TFN_widget(self)
            self.TFF.setGeometry(self.widget.width + 20, 30, 400, 200)
            if transN == 2:
                self.TFF2 = VTF.TFN_widget(self)
                self.TFF2.setGeometry(self.widget.width + 20, 260, 400, 200)

        if slider_on == True:
            self.slider = VMS.multi_slider(self)
            self.slider.setGeometry(self.widget.width + 20, 30 + 200, 400, 100)

        #self.setCentralWidget(self.widget)
        self.setWindowTitle("Vivaldi")

        self.parent = parent
        self.CRG = 0
        self.viewer_image_cnt = 0

        #for video
        self.ret_image_cnt = 0

        self.isnotExist = True
        self.folder_name = ''

        # Elongate Z direction
        #LoadIdentity()
        #Translate(0, 0, self.args[1][0].full_data_shape[0] * 2 * 3.0 /2.0 )
        #Scaled(1,1,3)

        #Translate(-self.args[1][0].full_data_shape[2]/2.0, -self.args[1][0].full_data_shape[1]/2.0,  -self.args[1][0].full_data_shape[0]/2.0)
        #self.z_ = self.args[1][0].full_data_shape[0] * 3.0 / 2.0 * 2

        # Origin
        LoadIdentity()
        Translate(-self.args[1][0].full_data_shape[2] / 2.0,
                  -self.args[1][0].full_data_shape[1] / 2.0,
                  self.args[1][0].full_data_shape[0] * 2.0)
        self.z_ = self.args[1][0].full_data_shape[0] * 5.0 / 2.0
예제 #2
0
	def __init__(self, parent, FNandARG):
		super(Vivaldi_window, self).__init__()

		_, self.func_name, self.args = FNandARG
		#print "\n\n\n\n\n\n\n", self.args[4][0], "\n\n\n\n\n\n\n"
		self.inBox_val = 0
		self.widget = Vivaldi_widget(self, self.args[2])

		global trans_on, transN, slider_on
		if trans_on == False:
			self.setGeometry(200, 100, self.widget.width, self.widget.height+30)
		else:
			self.setGeometry(200, 100, self.widget.width+420, self.widget.height+30)
		if trans_on == True:
			self.TFF = VTF.TFN_widget(self)
			self.TFF.setGeometry(self.widget.width+20, 30, 400, 200)
			if transN == 2:
				self.TFF2 = VTF.TFN_widget(self)
				self.TFF2.setGeometry(self.widget.width+20, 260, 400, 200)

		if slider_on == True:
			self.slider = VMS.multi_slider(self)
			self.slider.setGeometry(self.widget.width+20, 30+200, 400,100)
	
		#self.setCentralWidget(self.widget)
		self.setWindowTitle("Vivaldi")

		self.parent = parent
		self.CRG = 0
		self.viewer_image_cnt = 0

		#for video
		self.ret_image_cnt=0

		self.isnotExist = True
		self.folder_name = ''

		# Elongate Z direction 
		#LoadIdentity()
		#Translate(0, 0, self.args[1][0].full_data_shape[0] * 2 * 3.0 /2.0 )
		#Scaled(1,1,3)
	
		#Translate(-self.args[1][0].full_data_shape[2]/2.0, -self.args[1][0].full_data_shape[1]/2.0,  -self.args[1][0].full_data_shape[0]/2.0)
		#self.z_ = self.args[1][0].full_data_shape[0] * 3.0 / 2.0 * 2

		# Origin
		LoadIdentity()
		Translate(-self.args[1][0].full_data_shape[2]/2.0, -self.args[1][0].full_data_shape[1]/2.0,  self.args[1][0].full_data_shape[0]*2.0)
		self.z_ = self.args[1][0].full_data_shape[0]*5.0/2.0
예제 #3
0
	def __init__(self, parent, FNandARG):
		super(Vivaldi_window, self).__init__()

		_, self.func_name, self.args = FNandARG
		self.inBox_val = 0
		self.widget = Vivaldi_widget(self, self.args[2])

		global trans_on, transN, slider_on
		if trans_on == False:
			self.setGeometry(200, 100, self.widget.width, self.widget.height+60)
		else:
			self.setGeometry(200, 100, self.widget.width+420, self.widget.height+60)
		if trans_on == True:
			#self.TFF = VTF.TFN_widget(self)
			self.TFF_list = VTF.TFN_stacked_widget(self, transN)
			self.TFF_list.setGeometry(self.widget.width+20, 30, 400, 200)
			
			self.TFF = self.TFF_list.currentWidget()

			if transN > 1:
				TFN_selection = QtGui.QComboBox(self)
				TFN_selection.addItem("normal")
				for elem in range(transN-1):
					TFN_selection.addItem("ch"+str(elem+1))
				
				TFN_selection.activated[str].connect(self.TFN_chosen)
				TFN_selection.move(self.widget.width+20,235)

				def tfn_key(event):
					self.parent.window.keyPressEvent(event)
				TFN_selection.keyPressEvent = tfn_key
			
			#if transN == 2:
				#self.lbl = QtGui.QLabel(
				#self.TFF2 = VTF.TFN_widget(self)
				#self.TFF2.setGeometry(self.widget.width+20, 260, 400, 200)

		if slider_on == True:
			self.slider = VMS.multi_slider(self)
			self.slider.setGeometry(self.widget.width+20, 30+200+30, 400,250)
	
		#self.setCentralWidget(self.widget)
		self.setWindowTitle("Vivaldi")

		self.parent = parent
		self.CRG = 0
		self.viewer_image_cnt = 0

		#for video
		self.ret_image_cnt=0

		self.isnotExist = True
		self.folder_name = ''

		self.catch_x = 0
		self.catch_flag = False

		# Elongate Z direction 
		#LoadIdentity()
		#Translate(0, 0, self.args[4][0].full_data_shape[0] * 2 * 3.0 /2.0 )
		#Scaled(1,1,3)
	
		#Translate(-self.args[4][0].full_data_shape[2]/2.0, -self.args[4][0].full_data_shape[1]/2.0,  -self.args[4][0].full_data_shape[0]/2.0)
		#self.z_ = self.args[4][0].full_data_shape[0] * 3.0 / 2.0 * 2

		# Origin
		LoadIdentity()
		Translate(-self.args[1][0].full_data_shape[2]/2.0, -self.args[1][0].full_data_shape[1]/2.0,  self.args[1][0].full_data_shape[0]*2.0)
		self.z_ = self.args[1][0].full_data_shape[0]*5.0/2.0