image_viewer_360 0.1.3 copy "image_viewer_360: ^0.1.3" to clipboard
image_viewer_360: ^0.1.3 copied to clipboard

A Flutter widget for smooth 360-degree product image viewers with drag, zoom, autoplay, and frame preloading.

Image Viewer 360 #

image_viewer_360 is a Flutter widget for presenting 360-degree product image sequences. It supports drag rotation, zoom, autoplay, frame preloading, and cache warming for network images.

Features #

  • Drag horizontally to rotate through frames.
  • Play, pause, previous, and next controls.
  • Zoom and pan the current frame with InteractiveViewer.
  • Preload nearby decoded frames for smoother rotation.
  • Warm the remaining frames in the disk cache.
  • Customize loading, empty, and placeholder states.

Installation #

Add the package to your app:

dependencies:
  image_viewer_360: ^0.1.1

Then import it:

import 'package:image_viewer_360/image_viewer_360.dart';

Usage #

ImageViewer360(
  imageUrls: productFrameUrls,
  minBufferToPlay: 6,
  prefetchAhead: 8,
)

The imageUrls list should contain frame URLs in display order.

Custom UI #

ImageViewer360(
  imageUrls: productFrameUrls,
  loadingBuilder: (context, {
    required readyFrameCount,
    required totalFrameCount,
    required progress,
  }) {
    return Center(
      child: Text('$readyFrameCount of $totalFrameCount frames ready'),
    );
  },
  placeholderBuilder: (context) {
    return const Center(child: Icon(Icons.image_not_supported_outlined));
  },
)
0
likes
150
points
--
downloads

Documentation

API reference

Publisher

unverified uploader

Weekly Downloads

A Flutter widget for smooth 360-degree product image viewers with drag, zoom, autoplay, and frame preloading.

Repository (GitHub)
View/report issues

Topics

#flutter #image-viewer #product-viewer #ecommerce #widget

License

MIT (license)

Dependencies

cached_network_image, flutter, flutter_cache_manager

More

Packages that depend on image_viewer_360