All Projects → souvik-ghosh → react-native-create-thumbnail

souvik-ghosh / react-native-create-thumbnail

Licence: MIT License
iOS/Android thumbnail generator with support for both local and remote videos

Programming Languages

java
68154 projects - #9 most used programming language
objective c
16641 projects - #2 most used programming language
javascript
184084 projects - #8 most used programming language
ruby
36898 projects - #4 most used programming language
Starlark
911 projects

Projects that are alternatives of or similar to react-native-create-thumbnail

imtool
🖼️ Client-side canvas-based image manipulation library.
Stars: ✭ 38 (-75.32%)
Mutual labels:  thumbnails
yet-another-speed-dial
a modern speed dial for chrome, edge and firefox
Stars: ✭ 102 (-33.77%)
Mutual labels:  thumbnails
thumbnailme
Thumbnail me is an open source software project based on the ‘Movie Thumbnailer’ binary.
Stars: ✭ 63 (-59.09%)
Mutual labels:  thumbnails
nano photos provider2
PHP photos provider for nanogallery2
Stars: ✭ 37 (-75.97%)
Mutual labels:  thumbnails
react-hover-video-player
A React component for rendering videos that play on hover, including support for mouse and touch events and a simple API for adding thumbnails and loading states.
Stars: ✭ 60 (-61.04%)
Mutual labels:  thumbnails
flutter scroll gallery
Gallery with thumbnails
Stars: ✭ 42 (-72.73%)
Mutual labels:  thumbnails
Node S3 Uploader
Flexible and efficient resize, rename, and upload images to Amazon S3 disk storage. Uses the official AWS Node SDK for transfer, and ImageMagick for image processing. Support for multiple image versions targets.
Stars: ✭ 237 (+53.9%)
Mutual labels:  thumbnails
hls-live-thumbnails
A service which will generate thumbnails from a live HLS stream.
Stars: ✭ 49 (-68.18%)
Mutual labels:  thumbnails
micro
A not-so-micro ShareX server with support for thumbnails, deleting uploads and users.
Stars: ✭ 25 (-83.77%)
Mutual labels:  thumbnails
express-thumbnail
Express framework middleware for creation of thumbnails on the fly
Stars: ✭ 14 (-90.91%)
Mutual labels:  thumbnails
laravel-thumbnails
Laravel Package for making thumbnails instantly
Stars: ✭ 51 (-66.88%)
Mutual labels:  thumbnails
flask-thumbnails
A simple extension to create a thumbs for the flask framework
Stars: ✭ 59 (-61.69%)
Mutual labels:  thumbnails
LPThumbnailView
A thumbnail view for iOS to give context to multiple images/videos using thumbnails and counter.
Stars: ✭ 54 (-64.94%)
Mutual labels:  thumbnails
lamba-thumbnailer
AWS S3 Video Thumbnailer with Lambda
Stars: ✭ 21 (-86.36%)
Mutual labels:  thumbnails
thumbsupply
Generate thumbnails for your videos from node.js.
Stars: ✭ 17 (-88.96%)
Mutual labels:  thumbnails
MementoEmbed
A service that provides archive-aware oEmbed-compatible embeddable surrogates (social cards, thumbnails, etc.) for archived web pages (mementos).
Stars: ✭ 13 (-91.56%)
Mutual labels:  thumbnails
image-zoom
smooth, iOS/medium.com style thumbnail viewing
Stars: ✭ 35 (-77.27%)
Mutual labels:  thumbnails
angular-super-gallery
AngularJS super image gallery
Stars: ✭ 46 (-70.13%)
Mutual labels:  thumbnails
react-gallery-carousel
Mobile-friendly gallery carousel 🎠 with server side rendering, lazy loading, fullscreen, thumbnails, touch, mouse emulation, RTL, keyboard navigation and customisations.
Stars: ✭ 178 (+15.58%)
Mutual labels:  thumbnails
oembed
PHP OEmbed wrapper for well-known video platforms and services
Stars: ✭ 26 (-83.12%)
Mutual labels:  thumbnails

react-native-create-thumbnail

iOS/Android thumbnail generator with support for both local and remote videos. react-native-create-thumbnail is a wrapper around AVAssetImageGenerator (iOS) and MediaMetadataRetriever (Android)

npm version npm downloads Maintenance Status

Getting started

  1. Install library from npm

    npm i react-native-create-thumbnail

    or

    yarn add react-native-create-thumbnail
  2. Link native code

    With autolinking (react-native 0.60+)

    cd ios && pod install

    Pre 0.60

    react-native link react-native-create-thumbnail

Usage

import { createThumbnail } from "react-native-create-thumbnail";

createThumbnail({
  url: '<path to video file>',
  timeStamp: 10000,
})
  .then(response => console.log({ response }))
  .catch(err => console.log({ err }));

Request Object

Property Type Description
url String (required) Path to video file (local or remote)
timeStamp Number (default 0) Thumbnail timestamp (in milliseconds)
format String (default jpeg) Thumbnail format, can be one of: jpeg, or png
dirSize Number (default 100) Maximum size of the cache directory (in megabytes). When this directory is full, the previously generated thumbnails will be deleted to clear about half of it's size.
headers Object Headers to load the video with. e.g. { Authorization: 'someAuthToken' }
cacheName String (optional) Cache name for this thumbnail to avoid duplicate generation. If specified, and a thumbnail already exists with the same cache name, it will be returned instead of generating a new one.

Response Object

Property Type Description
path String Path to generated thumbnail
size Number Size (in bytes) of thumbnail
mime String Mimetype of thumbnail
width Number Thumbnail width
height Number Thumbnail height

Notes

Requires following Permissions on android

READ_EXTERNAL_STORAGE, WRITE_EXTERNAL_STORAGE

Limitations

  • Remote videos aren't supported on android sdk_version < 14.
  • This is a Native Module, so it won't work in expo managed projects.
  • This library heavily depends on the native API's to generate the thumbnails. Thus it can only generate from the video formats/codecs that are supported by the device's OS.

Credits

Maintenance Status

Active: Bug reports, feature requests and pull requests are welcome.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].