mapbox / mapbox/mapbox-maps-ios

Create ImageSource from a UIImage without having to write to disk

Open
#985 3 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

:stop_sign: blocked auto-triaged feature :green_apple:
Dominant language
Swift
Stars
601
Forks
196
PR merge metrics
No merged PRs in 30d

Description

## New Feature

Allow ImageSource to set a UIImage instead of a Url for the image. Not all images are stored on disk or on a remote server.

## Why

I am creating image layers on the fly, on device and there is no way to add them as a layer on the map. I attempted using a base64 string but that did not work. It’s much less efficient to have to round trip to a server or save the image to disk (they add up quick) if I don’t have to.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by locating the ImageSource API and its existing URL-based image handling. Trace how UIImage-backed content could enter the image-layer path without a disk or server round trip, then identify the relevant iOS tests or examples to update. Done means an on-device UIImage can be used directly as an image layer and the behavior is covered by tests.

Written by the indexing model from the issue text.

Assessment

Tech stack
ios, swift
Domain
mobile
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.