{"id":18686784,"url":"https://github.com/leon/labs-sharp-pano","last_synced_at":"2025-11-08T00:30:32.680Z","repository":{"id":142075583,"uuid":"309911680","full_name":"leon/labs-sharp-pano","owner":"leon","description":"POF for converting equirectangular images to cube faces","archived":false,"fork":false,"pushed_at":"2020-11-04T07:18:56.000Z","size":22752,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2024-12-28T00:43:26.691Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/leon.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2020-11-04T06:33:21.000Z","updated_at":"2022-07-25T11:03:04.000Z","dependencies_parsed_at":"2023-07-09T05:32:05.535Z","dependency_job_id":null,"html_url":"https://github.com/leon/labs-sharp-pano","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/leon%2Flabs-sharp-pano","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/leon%2Flabs-sharp-pano/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/leon%2Flabs-sharp-pano/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/leon%2Flabs-sharp-pano/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/leon","download_url":"https://codeload.github.com/leon/labs-sharp-pano/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":239541850,"owners_count":19656102,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-07T10:29:05.869Z","updated_at":"2025-11-08T00:30:32.586Z","avatar_url":"https://github.com/leon.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Proof of Concept\n\nusing sharp to convert from an equirectangular image to 6 cube faces compatible with three.js\n\n![Demo](/assets/test2048.jpg)\n\n# Run\n\nWill take the jpg specified in `index.ts main() imageName` and opening the image as a raw byte buffer then\nproject cube face onto unit sphere by converting cartesian to spherical coordinates and then using different\ncopy functions, copy the pixels from the source image into a cube face.\nWe then do this six times, once for each cube face.\n\nthe result will be present in the `out` dir.\n\n```bash\nyarn install\nyarn start\n```\n\n# Help\n\nIn the `renderFace.ts` file we have a `copyPixel` function which uses either linear, bicubic, lanczos algorithms\nto copy the pixels from the source to the destination.\nThese are javascript implementations which mean that they are very sluggish.\nI have done some reading about libvips and the mapim function it has.\nBut my knowledge of how I would convert renderFace to use this is limited.\n\nHas anyone seen a equirectangular to cubemap implementation in sharp?\nThe thing I'm looking for should copy a pixel from a raw array into another raw array using lanczos,\nsince that gives me the best looking outcome.\n\nCould someone point me in the right direction?\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fleon%2Flabs-sharp-pano","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fleon%2Flabs-sharp-pano","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fleon%2Flabs-sharp-pano/lists"}