forked from me/IronOS-Meta
Make erase image as well
This commit is contained in:
5
.github/workflows/push.yml
vendored
5
.github/workflows/push.yml
vendored
@@ -27,9 +27,12 @@ jobs:
|
|||||||
- name: prep
|
- name: prep
|
||||||
run: mkdir -p /tmp/${{ matrix.model }}
|
run: mkdir -p /tmp/${{ matrix.model }}
|
||||||
|
|
||||||
- name: build test
|
- name: build logo's
|
||||||
run: cd Bootup\ Logos && ./run.sh /tmp/${{ matrix.model }}/ ${{matrix.args}}
|
run: cd Bootup\ Logos && ./run.sh /tmp/${{ matrix.model }}/ ${{matrix.args}}
|
||||||
|
|
||||||
|
- name: build logo's
|
||||||
|
run: cd Bootup\ Logos && python3 img2logo.py -E dummy.png /tmp/${{ matrix.model }}/
|
||||||
|
|
||||||
- name: Archive artifacts
|
- name: Archive artifacts
|
||||||
uses: actions/upload-artifact@v2
|
uses: actions/upload-artifact@v2
|
||||||
with:
|
with:
|
||||||
|
|||||||
@@ -193,15 +193,15 @@ def img2hex(
|
|||||||
Optional `negative' inverts black/white regardless of input image type
|
Optional `negative' inverts black/white regardless of input image type
|
||||||
or other options.
|
or other options.
|
||||||
"""
|
"""
|
||||||
|
if make_erase_image:
|
||||||
|
data = [0xFF] * 1024
|
||||||
|
else:
|
||||||
try:
|
try:
|
||||||
image = Image.open(input_filename)
|
image = Image.open(input_filename)
|
||||||
except BaseException as e:
|
except BaseException as e:
|
||||||
raise IOError('error reading image file "{}": {}'.format(input_filename, e))
|
raise IOError('error reading image file "{}": {}'.format(input_filename, e))
|
||||||
|
|
||||||
if make_erase_image:
|
if getattr(image, "is_animated", False):
|
||||||
data = [0xFF] * 1024
|
|
||||||
elif getattr(image, "is_animated", False):
|
|
||||||
data = animated_image_to_bytes(image, negative, dither, threshold)
|
data = animated_image_to_bytes(image, negative, dither, threshold)
|
||||||
else:
|
else:
|
||||||
# magic/required header
|
# magic/required header
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
#! /bin/sh
|
#! /bin/sh
|
||||||
echo $1
|
echo $1
|
||||||
echo $2
|
echo $2
|
||||||
find Images/ -type f -exec python img2logo.py {} "$1" "$2" \;
|
find Images/ -type f -exec python3 img2logo.py {} "$1" "$2" \;
|
||||||
|
|||||||
Reference in New Issue
Block a user