live_photos 0.0.1 copy "live_photos: ^0.0.1" to clipboard
live_photos: ^0.0.1 copied to clipboard

outdated

A flutter plugin to generate LivePhotos.

example/lib/main.dart

import 'package:flutter/material.dart';
import 'package:live_photos/live_photos.dart';

void main() {
  runApp(MyApp());
}

class MyApp extends StatefulWidget {
  @override
  _MyAppState createState() => _MyAppState();
}

class _MyAppState extends State<MyApp> {
  @override
  void initState() {
    super.initState();
  }

  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      home: Scaffold(
        appBar: AppBar(
          title: const Text('Plugin example app'),
        ),
        body: Center(
            child: Column(
          crossAxisAlignment: CrossAxisAlignment.center,
          children: <Widget>[
            RaisedButton(
              child: Text('generate from url'),
              onPressed: () {
                LivePhotos.generate(
                  videoURL:
                      "https://img.gifmagazine.net/gifmagazine/images/3870471/original.mp4",
                ).then(
                  (value) {
                    if (value) {
                      print("Success");
                    } else {
                      print("Failed");
                    }
                  },
                ).catchError(
                  (e) => print(e),
                );
              },
            ),
          ],
        )),
      ),
    );
  }
}
5
likes
0
points
25
downloads

Publisher

unverified uploader

Weekly Downloads

A flutter plugin to generate LivePhotos.

Repository (GitHub)
View/report issues

License

unknown (license)

Dependencies

flutter

More

Packages that depend on live_photos

Packages that implement live_photos