kopia lustrzana https://github.com/NanoVNA-Saver/nanovna-saver
Update NanoVNA_F.py
Remove 41 to 64 lines of code from the Nanovna-F file (this will cause the screen to be split into four blocks, each evenly distributed across the full screen??)pull/330/head
rodzic
ebe517a0a9
commit
de7d047ba2
|
@ -38,33 +38,8 @@ class NanoVNA_F(NanoVNA):
|
|||
return QtGui.QPixmap()
|
||||
try:
|
||||
rgba_array = self._capture_data()
|
||||
unwrapped_array = np.empty(
|
||||
self.screenwidth*self.screenheight,
|
||||
dtype=np.uint32)
|
||||
for y in range(self.screenheight // 2):
|
||||
for x in range(self.screenwidth // 2):
|
||||
unwrapped_array[
|
||||
2 * x + 2 * y * self.screenwidth
|
||||
] = rgba_array[x + y * self.screenwidth]
|
||||
unwrapped_array[
|
||||
(2 * x) + 1 + 2 * y * self.screenwidth
|
||||
] = rgba_array[
|
||||
x + (self.screenheight//2 + y) * self.screenwidth
|
||||
]
|
||||
unwrapped_array[
|
||||
2 * x + (2 * y + 1) * self.screenwidth
|
||||
] = rgba_array[
|
||||
x + self.screenwidth // 2 + y * self.screenwidth
|
||||
]
|
||||
unwrapped_array[
|
||||
(2 * x) + 1 + (2 * y + 1) * self.screenwidth
|
||||
] = rgba_array[
|
||||
x + self.screenwidth // 2 +
|
||||
(self.screenheight//2 + y) * self.screenwidth
|
||||
]
|
||||
|
||||
image = QtGui.QImage(
|
||||
unwrapped_array,
|
||||
rgba_array,
|
||||
self.screenwidth, self.screenheight,
|
||||
QtGui.QImage.Format_ARGB32)
|
||||
logger.debug("Captured screenshot")
|
||||
|
|
Ładowanie…
Reference in New Issue