I helped myself by synchronizing the ROIs by the setState and getState 
methods, which are called when a mouse drag is detected. It is not nice, 
but it works.

Am Donnerstag, 22. März 2018 19:10:17 UTC+1 schrieb jean Bilheux:
>
> I'm dealing with the exact same issue here. I will let you know if I can 
> figure out how.
>
> On Thursday, February 8, 2018 at 9:57:20 AM UTC-5, Hauke Brunken wrote:
>>
>> Hi,
>>
>> I'm using Qt Designer for the layout where i have a graphicsLayoutWidget. 
>> I add two viewBoxes by:
>> self.viewBoxL = self.graphicsLayoutWidget.addViewBox(lockAspect=1.0,
>> invertY=True, name='l')
>> self.viewBoxR = self.graphicsLayoutWidget.addViewBox(lockAspect=1.0,
>> invertY=True, name='r')
>>
>> self.imgItemL = pg.ImageItem(border='w')
>> self.imgItemR = pg.ImageItem(border='w')
>>
>> self.viewBoxL.addItem(self.imgItemL)
>> self.viewBoxR.addItem(self.imgItemR)
>>
>> self.viewBoxL.setXLink(self.viewBoxR)
>> self.viewBoxL.setYLink(self.viewBoxR)
>>
>> self.imgItemL.setImage(imgL)
>> self.imgItemR.setImage(imgR)
>> which show two pictures of the same thing, but with different colors (I'm 
>> loading two different images with the same size). Now I want to add a ROI 
>> item. It seems that it is not possible to add this ROI item to both views, 
>> so I made two items and added them to viewBoxL and viewBoxR. Is it possible 
>> to synchronize these two items, so that every change I make in viewBoxL 
>> appears in viewBoxR?
>>
>> Thanks for your help!
>> Hauke
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"pyqtgraph" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/pyqtgraph/ad59a433-1fb2-4aac-b723-b39582023038%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to