diff --git a/README.md b/README.md index 2372f50..bfcafa6 100644 --- a/README.md +++ b/README.md @@ -1,8 +1,8 @@
- +Proton Stream icon -# proton-stream +# Proton Stream **Your Proton Drive, streaming.** A Netflix-style library for the videos in your Proton Drive and the share links people send you, on Linux, Windows, Android, Android TV and iOS. diff --git a/android/app/src/main/AndroidManifest.xml b/android/app/src/main/AndroidManifest.xml index ea50b79..72fc90d 100644 --- a/android/app/src/main/AndroidManifest.xml +++ b/android/app/src/main/AndroidManifest.xml @@ -39,7 +39,7 @@ - - - - - - - - - - + + + + diff --git a/android/app/src/main/res/drawable/ic_launcher_foreground.xml b/android/app/src/main/res/drawable/ic_launcher_foreground.xml index 02a01a0..820502c 100644 --- a/android/app/src/main/res/drawable/ic_launcher_foreground.xml +++ b/android/app/src/main/res/drawable/ic_launcher_foreground.xml @@ -1,34 +1,34 @@ - - - - - - - - - - + + + + + + - - - + + + + + + + + + + + + + + + + + + + + + diff --git a/android/app/src/main/res/drawable/ic_launcher_monochrome.xml b/android/app/src/main/res/drawable/ic_launcher_monochrome.xml index e6b1f1f..780c1bc 100644 --- a/android/app/src/main/res/drawable/ic_launcher_monochrome.xml +++ b/android/app/src/main/res/drawable/ic_launcher_monochrome.xml @@ -1,12 +1,10 @@ - - - - - + + + + + + + + diff --git a/android/app/src/main/res/drawable/ic_notification_stream.xml b/android/app/src/main/res/drawable/ic_notification_stream.xml index 1f38efd..7cc08b5 100644 --- a/android/app/src/main/res/drawable/ic_notification_stream.xml +++ b/android/app/src/main/res/drawable/ic_notification_stream.xml @@ -1,16 +1,10 @@ - - - - - + + + + + + + + diff --git a/android/app/src/main/res/values/strings.xml b/android/app/src/main/res/values/strings.xml index 0530d7c..d8e89af 100644 --- a/android/app/src/main/res/values/strings.xml +++ b/android/app/src/main/res/values/strings.xml @@ -1,9 +1,4 @@ - + Proton Stream - - Stream diff --git a/crates/pstr-app/assets/icon-256.png b/crates/pstr-app/assets/icon-256.png index e3bda54..18a62cb 100644 Binary files a/crates/pstr-app/assets/icon-256.png and b/crates/pstr-app/assets/icon-256.png differ diff --git a/docs/ANDROID.md b/docs/ANDROID.md index 1b76e1b..c551ae8 100644 --- a/docs/ANDROID.md +++ b/docs/ANDROID.md @@ -7,6 +7,11 @@ screens, while UniFFI exposes the existing catalog, share, streaming, watch-stat and offline logic. Keep reusable behavior in the Rust crates rather than reimplementing it in Kotlin. +The application and launcher activity both use **Proton Stream** from `app_name`; +keep the full name on phones, tablets and TV. The adaptive color and +monochrome icons and TV banner are generated from `images/logo.svg` with +`python scripts/render-branding.py` (`--check` verifies generated assets). + ## Android TV The same build installs on Android TV: it is listed in the TV launcher diff --git a/docs/IOS.md b/docs/IOS.md index d212806..540c421 100644 --- a/docs/IOS.md +++ b/docs/IOS.md @@ -54,9 +54,10 @@ every push to `main` and every pull request that touches the iOS sources or the crates under them. `release.yml` calls it too, and publishes the `.ipa` next to the other artifacts. -`scripts/render-ios-icon.sh` renders `ios/ProtonStream/Resources/AppIcon.svg`, which -is Android's adaptive launcher icon with both layers on one canvas, into the asset -catalog. +`python scripts/render-branding.py` generates the platform icons from the canonical +`images/logo.svg`, including the opaque 1024 px iOS icon and its full-bleed source +`ios/ProtonStream/Resources/AppIcon.svg`. `scripts/render-ios-icon.sh` delegates to +the same generator. Use `--check` to verify that all generated assets are current. ## Where iOS differs diff --git a/docs/MOBILE.md b/docs/MOBILE.md index fbe5d9d..2e6fe86 100644 --- a/docs/MOBILE.md +++ b/docs/MOBILE.md @@ -4,6 +4,11 @@ The Android and iOS apps share the desktop app's engine, so a library, its watch settings behave the same everywhere. This page covers what is different on a phone, a tablet and a TV. [Installation](INSTALL.md) explains how to install each one. +The Android launcher, app settings and share sheet use the full name **Proton Stream**. +Its violet–pink play prism with metallic copper depth belongs to the same icon family as Drive +and Gallery. Android launchers that support themed icons can also display its +monochrome play mark. + diff --git a/docs/USER_GUIDE.md b/docs/USER_GUIDE.md index 58021c3..1efcc5a 100644 --- a/docs/USER_GUIDE.md +++ b/docs/USER_GUIDE.md @@ -3,6 +3,10 @@ This page describes the desktop app. The Android and iOS apps have the same pages as tabs at the bottom of the screen; [Android and iOS](MOBILE.md) covers what is different there. +The app uses a violet–pink play prism with a narrow metallic copper edge. The same +mark appears in the launcher and desktop notifications, with a white silhouette +for Android status-bar notifications and themed launcher icons. + The app has five pages, in the bar at the top: **Library**, **History**, **Shares**, **Downloads** and **Settings**. **Ctrl+1** to **Ctrl+5** open them. diff --git a/images/BRANDING.md b/images/BRANDING.md new file mode 100644 index 0000000..58b9e4b --- /dev/null +++ b/images/BRANDING.md @@ -0,0 +1,38 @@ +# Violet / Copper vector branding + +Drive, Stream, and Gallery share frontal violet–pink faces, shallow metallic copper backing, and narrow edge highlights. The icons are editable vector artwork with no embedded images or raster effects. + +| App | Mark | +| --- | --- | +| Proton Drive for Linux | Open folder with lilac documents | +| Proton Stream | Rounded play prism | +| Proton Gallery | Stacked photo plates, mountains, and a copper sun | + +## Master artwork + +Edit `images/logo.svg`. It uses a 256-unit grid with transparent margins, a `mark` group, and reusable linear gradients. The copper backing extends six units up and right. SVG paths, rounded rectangles, circles, strokes, translation, and the photo clip are retained when exporting Android VectorDrawables. Unsupported SVG features cause generation to fail rather than silently change the artwork. + +Earlier artwork is preserved in `images/branding-archive/`. The new assets replace the active branding without removing previous designs. + +## Regeneration + +```sh +python scripts/render-branding.py +python scripts/render-branding.py --check +``` + +Requires Python 3, librsvg (`rsvg-convert`), and ImageMagick (`magick`). Stream's TV banner also requires fontconfig and DejaVu Sans. Keep the generator identical across the three repositories; every checkout renders independently and requires no sibling checkout. Edit the canonical master rather than generated platform assets. + +## Platform treatment + +- Desktop SVGs and PNGs retain transparent margins and the exact approved geometry. The same colored artwork works on light and dark surfaces. +- Android adaptive icons use a pale lavender full-bleed background and a separate foreground containing the complete object. The 256-unit canvas maps to the central 64dp of the 108dp adaptive canvas; the painted geometry stays within the central safe circle. Android supplies the outer mask. +- Themed launcher icons and Stream's status-bar notification icon use a white silhouette without colored bevel highlights. +- iOS uses the same play prism over an opaque pale lavender square, exported at 1024px. The system supplies the corner mask. +- The Android TV banner pairs the play prism with the full Proton Stream name. + +Keep full product names in launcher metadata. Application UI typography and photo-content icons are independent of this branding. + +## Outputs + +Generated outputs include the packaged desktop SVG, the desktop/window/notification PNG, Windows ICO (16, 24, 32, 48, 64, 128, and 256px), Android adaptive and monochrome layers, status-bar notification mark, Android TV banner, iOS source SVG, and opaque 1024px iOS icon. The compatibility entry points `render-ios-icon.sh` and `render-tv-banner.sh` invoke this same generator. diff --git a/images/branding-archive/logo-before-vector.svg b/images/branding-archive/logo-before-vector.svg new file mode 100644 index 0000000..0dd1344 --- /dev/null +++ b/images/branding-archive/logo-before-vector.svg @@ -0,0 +1,27 @@ + + + Proton Stream + A forward play mark with three motion trails, in violet warming to copper at its tip. + + + + + + + + + + + + + + + + + + + + + diff --git a/images/logo.svg b/images/logo.svg index 0401675..d98ab33 100644 --- a/images/logo.svg +++ b/images/logo.svg @@ -1,39 +1,40 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + +Proton Stream +Frontal violet and pink vector icon with shallow metallic copper backing. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/img/Screenshot_20261017-195434.png b/img/Screenshot_20261017-195434.png new file mode 100644 index 0000000..02701a5 Binary files /dev/null and b/img/Screenshot_20261017-195434.png differ diff --git a/img/io_narl_proton-stream_2026-10-17_19-55-02.png b/img/io_narl_proton-stream_2026-10-17_19-55-02.png new file mode 100644 index 0000000..14d197f Binary files /dev/null and b/img/io_narl_proton-stream_2026-10-17_19-55-02.png differ diff --git a/ios/ProtonStream/Resources/AppIcon.svg b/ios/ProtonStream/Resources/AppIcon.svg index ebbfb93..9d748dd 100644 --- a/ios/ProtonStream/Resources/AppIcon.svg +++ b/ios/ProtonStream/Resources/AppIcon.svg @@ -1,37 +1,43 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/ios/ProtonStream/Resources/Assets.xcassets/AppIcon.appiconset/AppIcon-1024.png b/ios/ProtonStream/Resources/Assets.xcassets/AppIcon.appiconset/AppIcon-1024.png index 0670290..d311a8e 100644 Binary files a/ios/ProtonStream/Resources/Assets.xcassets/AppIcon.appiconset/AppIcon-1024.png and b/ios/ProtonStream/Resources/Assets.xcassets/AppIcon.appiconset/AppIcon-1024.png differ diff --git a/packaging/io.narl.proton-stream.svg b/packaging/io.narl.proton-stream.svg index 0401675..d98ab33 100644 --- a/packaging/io.narl.proton-stream.svg +++ b/packaging/io.narl.proton-stream.svg @@ -1,39 +1,40 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + +Proton Stream +Frontal violet and pink vector icon with shallow metallic copper backing. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/packaging/windows/proton-stream.ico b/packaging/windows/proton-stream.ico index 3bc2e3f..e263f09 100644 Binary files a/packaging/windows/proton-stream.ico and b/packaging/windows/proton-stream.ico differ diff --git a/scripts/render-branding.py b/scripts/render-branding.py new file mode 100755 index 0000000..32b6896 --- /dev/null +++ b/scripts/render-branding.py @@ -0,0 +1,273 @@ +#!/usr/bin/env python3 +"""Render the vector branding into desktop, Android, iOS and Windows assets. + +Kept identical across the suite; each checkout renders independently. +""" + +import argparse +from pathlib import Path +import re +import shutil +import subprocess +import tempfile +import xml.etree.ElementTree as ET + + +SVG = "{http://www.w3.org/2000/svg}" +ANDROID = "{http://schemas.android.com/apk/res/android}" +AAPT = "{http://schemas.android.com/aapt}" +ET.register_namespace("", SVG[1:-1]) +ET.register_namespace("android", ANDROID[1:-1]) +ET.register_namespace("aapt", AAPT[1:-1]) +HEADER = '\n' +GENERATED = '\n' +ROOT = Path(__file__).resolve().parent.parent +BACKGROUND = "#F4F0FA" + + +def run(*args, data=None): + return subprocess.run(args, input=data, stdout=subprocess.PIPE, check=True).stdout + + +def render(svg, size, *, opaque=False): + png = run("rsvg-convert", "-w", str(size), data=svg.encode()) + options = ["-background", BACKGROUND, "-alpha", "remove", "-alpha", "off"] if opaque else [] + return run("magick", "-", *options, "-strip", "PNG:-", data=png) + + +def shape_path(node): + """Use the same paths on Android, including rounded rectangles and circles.""" + tag = node.tag.removeprefix(SVG) + a = node.attrib + if tag == "path": + return a["d"] + if tag == "circle": + x, y, r = (float(a[k]) for k in ("cx", "cy", "r")) + return f"M{x-r:g} {y:g}a{r:g} {r:g} 0 1 0 {2*r:g} 0a{r:g} {r:g} 0 1 0 {-2*r:g} 0Z" + if tag == "rect": + x, y = float(a.get("x", 0)), float(a.get("y", 0)) + w, h = float(a["width"]), float(a["height"]) + rx = min(float(a.get("rx", a.get("ry", 0))), w / 2) + ry = min(float(a.get("ry", a.get("rx", 0))), h / 2) + if not rx or not ry: + return f"M{x:g} {y:g}h{w:g}v{h:g}h{-w:g}Z" + return (f"M{x+rx:g} {y:g}H{x+w-rx:g}a{rx:g} {ry:g} 0 0 1 {rx:g} {ry:g}" + f"V{y+h-ry:g}a{rx:g} {ry:g} 0 0 1 {-rx:g} {ry:g}" + f"H{x+rx:g}a{rx:g} {ry:g} 0 0 1 {-rx:g} {-ry:g}" + f"V{y+ry:g}a{rx:g} {ry:g} 0 0 1 {rx:g} {-ry:g}Z") + raise ValueError(f"Unsupported SVG shape: {tag}") + + +def color(value): + if value == "none": + return "#00000000" + if re.fullmatch(r"#[0-9a-fA-F]{6}", value): + return "#FF" + value[1:] + raise ValueError(f"Unsupported SVG color: {value}") + + +def xml(element): + ET.indent(element, space=" ") + return HEADER + GENERATED + ET.tostring(element, encoding="unicode") + "\n" + + +class Artwork: + def __init__(self, master): + if master.attrib.get("viewBox") != "0 0 256 256": + raise ValueError("The master must use the 256-unit vector grid") + self.defs = master.find(f"{SVG}defs") + self.mark = master.find(f"{SVG}g[@id='mark']") + if self.defs is None or self.mark is None or not list(self.mark): + raise ValueError("The master needs defs and a nonempty mark group") + self.gradients = {g.attrib["id"]: g for g in self.defs.findall(f"{SVG}linearGradient")} + self.clips = {g.attrib["id"]: g for g in self.defs.findall(f"{SVG}clipPath")} + self.svg_defs = ET.tostring(self.defs, encoding="unicode") + self.svg_mark = ET.tostring(self.mark, encoding="unicode") + + def paint(self, node, name, value): + if not value.startswith("url(#"): + node.set(ANDROID + name, color(value)) + return + gradient = self.gradients[value[5:-1]] + if gradient.attrib.get("gradientUnits") != "userSpaceOnUse": + raise ValueError("Android gradients must use userSpaceOnUse") + attr = ET.SubElement(node, AAPT + "attr", {"name": "android:" + name}) + out = ET.SubElement(attr, "gradient", { + ANDROID + "type": "linear", + **{ANDROID + dst: gradient.attrib[src] for src, dst in + (("x1", "startX"), ("y1", "startY"), ("x2", "endX"), ("y2", "endY"))}, + }) + for stop in gradient: + ET.SubElement(out, "item", { + ANDROID + "offset": stop.attrib.get("offset", "0"), + ANDROID + "color": color(stop.attrib["stop-color"]), + }) + + def android_node(self, source, parent, monochrome): + tag = source.tag.removeprefix(SVG) + a = source.attrib + if tag not in {"g", "path", "rect", "circle"}: + raise ValueError(f"Unsupported artwork element: {tag}") + supported = {"id", "transform", "clip-path"} + if tag != "g": + supported |= {"d", "x", "y", "width", "height", "rx", "ry", "cx", "cy", "r", + "fill", "fill-rule", "fill-opacity", "opacity", "stroke", "stroke-width", + "stroke-opacity", "stroke-linecap", "stroke-linejoin"} + if set(a) - supported: + raise ValueError(f"Unsupported {tag} attributes: {set(a) - supported}") + if "transform" in a: + match = re.fullmatch(r"translate\(\s*([-\d.]+)[ ,]+([-\d.]+)\s*\)", a["transform"]) + if not match: + raise ValueError("Only explicit x/y translation is supported") + parent = ET.SubElement(parent, "group", { + ANDROID + "translateX": match[1], ANDROID + "translateY": match[2], + }) + if "clip-path" in a: + clip = self.clips[a["clip-path"][5:-1]] + parent = ET.SubElement(parent, "group") + ET.SubElement(parent, "clip-path", { + ANDROID + "pathData": " ".join(shape_path(s) for s in clip), + }) + if tag == "g": + for child in source: + self.android_node(child, parent, monochrome) + return + fill = a.get("fill", "#000000") + if monochrome and fill == "none": + return # Bevel highlights do not belong in the themed silhouette. + node = ET.SubElement(parent, "path", { + ANDROID + "pathData": shape_path(source), + ANDROID + "fillType": "evenOdd" if a.get("fill-rule") == "evenodd" else "nonZero", + }) + self.paint(node, "fillColor", "#FFFFFF" if monochrome else fill) + if monochrome: + return + opacity = float(a.get("opacity", 1)) + node.set(ANDROID + "fillAlpha", f'{opacity * float(a.get("fill-opacity", 1)):g}') + if "stroke" in a: + self.paint(node, "strokeColor", a["stroke"]) + node.set(ANDROID + "strokeWidth", a.get("stroke-width", "1")) + node.set(ANDROID + "strokeAlpha", f'{opacity * float(a.get("stroke-opacity", 1)):g}') + for src, dst in (("stroke-linecap", "strokeLineCap"), ("stroke-linejoin", "strokeLineJoin")): + if src in a: + node.set(ANDROID + dst, a[src]) + + def vector(self, size=108, scale=.25, *, monochrome=False): + # The 256-unit canvas maps to 64dp; all painted corners stay inside + # the adaptive icon's central safe circle, including the copper rim. + root = ET.Element("vector", { + ANDROID + "width": f"{size}dp", ANDROID + "height": f"{size}dp", + ANDROID + "viewportWidth": str(size), ANDROID + "viewportHeight": str(size), + }) + shift = size / 2 - 128 * scale + group = ET.SubElement(root, "group", { + ANDROID + "scaleX": str(scale), ANDROID + "scaleY": str(scale), + ANDROID + "translateX": str(shift), ANDROID + "translateY": str(shift), + }) + self.android_node(self.mark, group, monochrome) + return xml(root).encode() + + def ios(self): + return HEADER + GENERATED + f''' +{self.svg_defs} + +{self.svg_mark} + +''' + + def banner(self): + return HEADER + GENERATED + f''' +{self.svg_defs} + +{self.svg_mark} + + Proton + Stream + + +''' + + +def main(): + parser = argparse.ArgumentParser(description=__doc__) + parser.add_argument("--check", action="store_true", help="Verify outputs without writing files") + args = parser.parse_args() + for command in ("rsvg-convert", "magick"): + if not shutil.which(command): + parser.error(f"{command} is required") + source = ROOT / "images/logo.svg" + master = ET.parse(source).getroot() + app = master.attrib["data-app"] + if app not in {"drive", "stream", "gallery"}: + parser.error("Unknown data-app in images/logo.svg") + art = Artwork(master) + desktop = source.read_bytes() + outputs = {} + if app in {"drive", "stream"}: + slug = "proton-drive-linux" if app == "drive" else "proton-stream" + outputs[f"packaging/io.narl.{slug}.svg"] = desktop + if app == "drive": + cover = ET.parse(ROOT / "images/cover.svg").getroot() + slot = cover.find(f"{SVG}g[@id='app-logo']") + if slot is None: + raise ValueError("The cover needs an app-logo group") + for child in list(slot): + slot.remove(child) + slot.append(ET.fromstring(art.svg_defs)) + slot.append(ET.fromstring(art.svg_mark)) + cover_svg = xml(cover) + outputs["images/cover.svg"] = cover_svg.encode() + outputs["images/cover.png"] = render(cover_svg, 1920) + if app in {"stream", "gallery"}: + res = "android/app/src/main/res/drawable/" + outputs[res + "ic_launcher_foreground.xml"] = art.vector() + outputs[res + "ic_launcher_monochrome.xml"] = art.vector(monochrome=True) + # A full-bleed neutral surface keeps the violet object legible under + # every launcher mask. The foreground retains its own copper depth. + background = ET.Element("vector", { + ANDROID + "width": "108dp", ANDROID + "height": "108dp", + ANDROID + "viewportWidth": "108", ANDROID + "viewportHeight": "108", + }) + ET.SubElement(background, "path", { + ANDROID + "fillColor": color(BACKGROUND), ANDROID + "pathData": "M0 0H108V108H0Z", + }) + outputs[res + "ic_launcher_background.xml"] = xml(background).encode() + if app == "gallery": + outputs["images/icon-512.png"] = render(desktop.decode(), 512) + outputs["android/app/src/main/res/drawable/ic_gallery.xml"] = art.vector(256, 1) + if app == "stream": + outputs["android/app/src/main/res/drawable/ic_notification_stream.xml"] = art.vector(24, 24/256, monochrome=True) + outputs["crates/pstr-app/assets/icon-256.png"] = render(desktop.decode(), 256) + ios = art.ios() + outputs["ios/ProtonStream/Resources/AppIcon.svg"] = ios.encode() + outputs["ios/ProtonStream/Resources/Assets.xcassets/AppIcon.appiconset/AppIcon-1024.png"] = render(ios, 1024, opaque=True) + with tempfile.TemporaryDirectory(prefix="proton-icons-") as temp: + files = [] + for size in (16, 24, 32, 48, 64, 128, 256): + path = Path(temp) / f"{size}.png" + path.write_bytes(render(desktop.decode(), size)) + files.append(str(path)) + outputs["packaging/windows/proton-stream.ico"] = run("magick", *files, "-strip", "ICO:-") + if not shutil.which("fc-match"): + parser.error("fontconfig is required to render the Android TV banner") + if "DejaVu Sans" not in run("fc-match", "-f", "%{family}", "DejaVu Sans").decode(): + parser.error("DejaVu Sans is required to render the Android TV banner") + outputs["android/app/src/main/res/drawable-nodpi/tv_banner.png"] = render(art.banner(), 640, opaque=True) + stale = [] + for relative, data in outputs.items(): + target = ROOT / relative + if target.exists() and target.read_bytes() == data: + continue + if args.check: + stale.append(relative) + else: + target.parent.mkdir(parents=True, exist_ok=True) + target.write_bytes(data) + print(f"wrote {relative}") + if stale: + parser.exit(1, "Branding assets need regeneration:\n" + "\n".join(stale) + "\n") + print(f"{'Verified' if args.check else 'Rendered'} {len(outputs)} assets from images/logo.svg") + + +if __name__ == "__main__": + main() diff --git a/scripts/render-ios-icon.sh b/scripts/render-ios-icon.sh index e3e2ac0..ce207d3 100755 --- a/scripts/render-ios-icon.sh +++ b/scripts/render-ios-icon.sh @@ -1,13 +1,6 @@ #!/usr/bin/env bash -# Render ios/ProtonStream/Resources/AppIcon.svg into the asset catalog's one -# 1024 px icon. iOS wants it opaque, so the alpha channel is dropped. +# Compatibility entry point: all platform icons share images/logo.svg. set -euo pipefail script_dir="$(cd -- "$(dirname -- "${BASH_SOURCE[0]}")" && pwd)" -resources="$script_dir/../ios/ProtonStream/Resources" -out="$resources/Assets.xcassets/AppIcon.appiconset/AppIcon-1024.png" - -command -v rsvg-convert >/dev/null || { echo "rsvg-convert is required (librsvg)" >&2; exit 1; } -command -v magick >/dev/null || { echo "magick is required (ImageMagick)" >&2; exit 1; } -rsvg-convert -w 1024 -h 1024 "$resources/AppIcon.svg" | magick - -alpha off -strip "$out" -echo "wrote $out" +exec python3 "$script_dir/render-branding.py" "$@" diff --git a/scripts/render-tv-banner.sh b/scripts/render-tv-banner.sh index a938474..ce207d3 100755 --- a/scripts/render-tv-banner.sh +++ b/scripts/render-tv-banner.sh @@ -1,21 +1,6 @@ #!/usr/bin/env bash -# Render the Android TV launcher banner, 320 by 180 dp, from the iOS icon: its -# canvas widened to 16:9 with the face gradient run across the whole width, -# and the play mark a little smaller, since a banner is shown as is rather -# than cut down by a mask. Twice the size, in drawable-nodpi: one file for -# every screen, which the launcher scales to its slot, sharp on a 4K one. +# Compatibility entry point: all platform icons share images/logo.svg. set -euo pipefail script_dir="$(cd -- "$(dirname -- "${BASH_SOURCE[0]}")" && pwd)" -icon="$script_dir/../ios/ProtonStream/Resources/AppIcon.svg" -out="$script_dir/../android/app/src/main/res/drawable-nodpi/tv_banner.png" - -command -v rsvg-convert >/dev/null || { echo "rsvg-convert is required (librsvg)" >&2; exit 1; } -command -v magick >/dev/null || { echo "magick is required (ImageMagick)" >&2; exit 1; } -mkdir -p "$(dirname "$out")" -sed -e 's/width="1024" height="1024" viewBox="0 0 108 108"/width="320" height="180" viewBox="-42 0 192 108"/' \ - -e 's/
Home