Changeset 101444 in vbox
- Timestamp:
- Oct 13, 2023 6:16:24 PM (18 months ago)
- svn:sync-xref-src-repo-rev:
- 159503
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/ValidationKit/tests/additions/tdAddGuestCtrl.py
r101416 r101444 5500 5500 iThreshold = 20 5501 5501 for i in range(0, cPixels, 4) : 5502 iRed = int(aRGBData[i]) 5503 iGreen = int(aRGBData[i + 1]) 5504 iBlue = int(aRGBData[i + 2]) 5502 if sys.version_info[0] >= 3: 5503 iRed = aRGBData[i]; 5504 iGreen = aRGBData[i + 1]; 5505 iBlue = aRGBData[i + 2]; 5506 else: # Python 2.7 treats a pixel data returned by takeScreenShotToArray as a string 5507 iRed = ord(aRGBData[i]) 5508 iGreen = ord(aRGBData[i + 1]) 5509 iBlue = ord(aRGBData[i + 2]) 5510 5505 5511 iBright = (3 * iRed + 6 * iGreen + iBlue) / 10 5506 5512 if iThreshold < iBright < 255 - iThreshold :
Note:
See TracChangeset
for help on using the changeset viewer.