mirror of
https://github.com/openmv/openmv.git
synced 2025-11-04 14:49:50 +08:00
examples: Fix image drawing advanced script.
This commit is contained in:
parent
57c406cd5e
commit
54137a48db
@ -81,11 +81,11 @@ while(True):
|
|||||||
|
|
||||||
apply_mask = CYCLE_MASK and ((value_mixer >> 9) & 1)
|
apply_mask = CYCLE_MASK and ((value_mixer >> 9) & 1)
|
||||||
if apply_mask:
|
if apply_mask:
|
||||||
img.draw_image(small_img, int(x), int(y), mask=small_img.to_bitmap(copy=True), x_scale=rescale, y_scale=rescale, alpha=240, hint=image.IMAGE_HINT_BILINEAR | image.IMAGE_HINT_CENTER)
|
img.draw_image(small_img, int(x), int(y), mask=small_img.to_bitmap(copy=True), x_scale=rescale, y_scale=rescale, alpha=240, hint=image.BILINEAR | image.CENTER)
|
||||||
status += 'alpha:240 '
|
status += 'alpha:240 '
|
||||||
status += '+mask '
|
status += '+mask '
|
||||||
else:
|
else:
|
||||||
img.draw_image(small_img, int(x), int(y), x_scale=rescale, y_scale=rescale, alpha=128, hint=image.IMAGE_HINT_BILINEAR | image.IMAGE_HINT_CENTER)
|
img.draw_image(small_img, int(x), int(y), x_scale=rescale, y_scale=rescale, alpha=128, hint=image.BILINEAR | image.CENTER)
|
||||||
status += 'alpha:128 '
|
status += 'alpha:128 '
|
||||||
|
|
||||||
img.draw_string(8, 0, status, mono_space = False)
|
img.draw_string(8, 0, status, mono_space = False)
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user