MCPcopy Create free account
hub / github.com/ElementsProject/elements / getpixel

Method getpixel

contrib/signet/getcoins.py:47–48  ·  view source on GitHub ↗
(self, pos)

Source from the content-addressed store, hash-verified

45 self._grid = [[tuple(data[stride * y + 3 * x:stride * y + 3 * (x + 1)]) for x in range(width)] for y in range(height)]
46
47 def getpixel(self, pos):
48 return self._grid[pos[1]][pos[0]]
49
50def print_image(img, threshold=128):
51 '''Print black-and-white image to terminal in braille unicode characters.'''

Callers 1

print_imageFunction · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected