Coder Social home page Coder Social logo

rive-app / rive-flutter Goto Github PK

View Code? Open in Web Editor NEW
1.2K 22.0 185.0 8.22 MB

Flutter runtime for Rive

Home Page: https://rive.app

License: MIT License

Dart 96.79% Kotlin 0.02% Swift 0.07% Objective-C 0.05% HTML 0.08% CMake 0.63% Ruby 0.18% C++ 1.28% C 0.03% Lua 0.66% Shell 0.23%
animation flutter interactive

rive-flutter's Introduction

Pub Version Build Status Discord badge Twitter handle

Rive Flutter

Rive hero image

Rive Flutter is a runtime library for Rive, a real-time interactive design and animation tool.

This library allows you to fully control Rive files with a high-level API for simple interactions and animations, as well as a low-level API for creating custom render loops for multiple artboards, animations, and state machines in a single canvas.

Table of contents

Overview of Rive

Rive is a powerful tool that helps teams create and run interactive animations for apps, games, and websites. Designers and developers can use the collaborative editor to create motion graphics that respond to different states and user inputs, and then use the lightweight open-source runtime libraries, like Rive Flutter, to load their animations into their projects.

For more information, check out the following resources:

๐Ÿก Homepage

๐Ÿ“˜ General help docs

๐Ÿ›  Rive Forums

Getting started

To get started with Rive Flutter, check out the following resources:

For more information, see the Runtime sections of the Rive help documentation:

More advanced usage:

Choosing a Renderer

For more information see: https://rive.app/community/doc/overview/docD20dU9Rod

Note on the Impeller renderer

Starting in Flutter v3.10, Impeller has replaced Skia to become the default renderer for apps on the iOS platform and may continue to be the default on future platforms over time. As such, there is a possibility of rendering and performance discrepancies when using the Rive Flutter runtime with platforms that use the Impeller renderer that may not have surfaced before. If you encounter any visual or performance errors at runtime compared to expected behavior in the Rive editor, we recommend trying the following steps to triage:

  1. Try running the Flutter app with the --no-enable-impeller flag to use the Skia renderer. If the visual discrepancy does not show when using Skia, it may be a rendering bug on Impeller. However, before raising a bug with the Flutter team, try the second point below๐Ÿ‘‡
flutter run --no-enable-impeller
  1. Try running the Flutter app on the latest master channel. It is possible that visual bugs may be resolved on the latest Flutter commits, but not yet released in the beta or stable channel.
  2. If you are still seeing visual discrepancies with just the Impeller renderer on the latest master branch, we recommend raising a detailed issue to the Flutter Github repo with a reproducible example, and other relevant details that can help the team debug any possible issues that may be present.

Supported platforms

Be sure to read the platform specific considerations for the Rive Flutter package.

Awesome Rive

For even more examples and resources on using Rive at runtime or in other tools, checkout the awesome-rive repo.

Contributing

We love contributions and all are welcome! ๐Ÿ’™

Issues

Have an issue with using the runtime, or want to suggest a feature/API to help make your development life better? Log an issue in our issues tab! You can also browse older issues and discussion threads there to see solutions that may have worked for common problems.

rive-flutter's People

Contributors

anzbert avatar caudetgit avatar creativecreatorormaybenot avatar diegoveloper avatar luigi-rosso avatar mikerreed avatar mjohnsullivan avatar mjtalbot avatar neurowave avatar nilskj avatar sese-schneider avatar umberto-sonnino avatar zambiorix avatar zplata avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

rive-flutter's Issues

Unhandled Exception: Instance of 'RiveFormatErrorException'

I copy the example code. Export file as checkedbox.flr from rive.app. And replace this line
rootBundle.load('assets/teeny_tiny.riv')
with
rootBundle.load('checkedbox.flr')

After that application throwing following exception

E/flutter (10317): [ERROR:flutter/lib/ui/ui_dart_state.cc(166)] Unhandled Exception: Instance of 'RiveFormatErrorException'
E/flutter (10317): #0      new RuntimeHeader.read (package:rive/src/rive_core/runtime/runtime_header.dart:17:9)
E/flutter (10317): #1      RiveFile.import (package:rive/src/rive_file.dart:32:29)
E/flutter (10317): #2      _MyHomePageState.initState.<anonymous closure> (package:happyshooping/main.dart:128:28)
E/flutter (10317): #3      _rootRunUnary (dart:async/zone.dart:1198:47)
E/flutter (10317): #4      _CustomZone.runUnary (dart:async/zone.dart:1100:19)
E/flutter (10317): #5      _FutureListener.handleValue (dart:async/future_impl.dart:143:18)
E/flutter (10317): #6      Future._propagateToListeners.handleValueCallback (dart:async/future_impl.dart:696:45)
E/flutter (10317): #7      Future._propagateToListeners (dart:async/future_impl.dart:725:32)
E/flutter (10317): #8      Future._completeWithValue (dart:async/future_impl.dart:529:5)
E/flutter (10317): #9      _AsyncAwaitCompleter.complete (dart:async-patch/async_patch.dart:40:15)
E/flutter (10317): #10     _completeOnAsyncReturn (dart:async-patch/async_patch.dart:311:13)
E/flutter (10317): #11     PlatformAssetBundle.load (package:flutter/src/services/asset_bundle.dart)

I noticed that this example use
teeny_tiny.riv
but when I generate file it's with .flr
teeny_tiny.flr

Second plugin
I also found this plugin: https://pub.dev/packages/flare_flutter
So which one should I use in my case?

If you explain the purpose of both that will be great.

"useIntrinsicSize" naming consideration

Problem

You recently added the useIntrinsicSize property and I have some concerns regarding the naming:

Flutter already has a concept called Intrinsics (see Intrinsics & baselines) and it refers to something different.
So now we have a naming conflict:

  • Flutter has an intrinsic sizing conflict.
  • The Rive render box uses useIntrinsicSize for a different concept.

Proposal

The property should be called useArtboardSize instead because that is what it really does. In Flutter's terms what your new useIntrinsicSize does is just considered the "regular" layout, i.e. the difference between being sized by parent or being sized by child.

This is just one idea of course, however, I think that it is useful to mention the name shadowing :)

Error: Use JsonReader.setLenient(true) to accept malformed JSON at path$

Version 0.6.7 in flutter when running on a Android device
Follow the sample code, I write my own Widget:

import 'package:flutter/material.dart';
import 'package:flutter/services.dart';
import 'package:rive/rive.dart';

class RiveContainer extends StatefulWidget {
  final String url;
  final String animationName;
  const RiveContainer(this.url, {this.animationName});
  @override
  State<StatefulWidget> createState() => _RiveContainerState();
}

class _RiveContainerState extends State<RiveContainer>
    with SingleTickerProviderStateMixin {
  String _animationName;
  Artboard _riveArtboard;
  RiveAnimationController _controller;
  @override
  void initState() {
    super.initState();
    _animationName = widget.animationName ?? Uri.parse(widget.url).fragment;
    // Load the animation file from the bundle, note that you could also
    // download this. The RiveFile just expects a list of bytes.
    rootBundle.load(Uri.parse(widget.url).pathSegments.join('/')).then(
      (data) {
        final file = RiveFile();

        // Load the RiveFile from the binary data.
        if (file.import(data)) {
          // The artboard is the root of the animation and gets drawn in the
          // Rive widget.
          final artboard = file.mainArtboard;
          // Add a controller to play back a known animation on the main/default
          // artboard.We store a reference to it so we can toggle playback.
          artboard.addController(_controller = SimpleAnimation(_animationName));
          setState(() {
            _riveArtboard = artboard;
            _controller.isActive = true;
          });
        }
      },
    );
  }

  @override
  Widget build(BuildContext context) {
    return _riveArtboard != null
        ? AspectRatio(
            aspectRatio: _riveArtboard.width / _riveArtboard.height,
            child: Rive(
              artboard: _riveArtboard,
            ))
        : const SizedBox();
  }
}

After playing for a while then occur this error on screen with yellow letters with red background:
Use JsonReader.setLenient(true) to accept malformed JSON at path$
But no console error at all.
I think it happens inside your package and I hope you can fix this as soon as possible.

Suggestion: Enable asset swapping runtime.

This tool would be really useful. For instance, if a character is customizable it will allow using a single bone animation with the image asset (the one attached to the bone) chosen/swapped runtime.

How to transition?

Sorry if this is obvious, though I have an animation and I wish for it push another page once its over, tried to add a listener to the controller for when its active or not but it returns an error, anybody have a solution please?

navigator._debuglocked' is not true is the error

Can't import file from url

Future<RiveFile> _fileFromImageUrl() async {
    HttpClient client = HttpClient();
    HttpClientRequest request = await client.getUrl(Uri.parse(
        "https://res.cloudinary.com/color-project/raw/upload/v1617085445/color/challenge/challenge_animation/rocket_movlqn.riv"
        // _challengeGroup.challenges[0].animationUrl
        ));
    HttpClientResponse response = await request.close();
    var data = await consolidateHttpClientResponseBytes(response);
    var file = RiveFile.import(ByteData.view(data.buffer));
    print(file);
    return file; 
}

I want to import file from web, not using rootBundle.
I try to import with http, dio, httpClient but I can't .

plz help me

แ„‰แ…ณแ„แ…ณแ„…แ…ตแ†ซแ„‰แ…ฃแ†บ 2021-03-30 แ„‹แ…ฉแ„’แ…ฎ 3 29 35

Above screen shot is the result of the error

Flutter app using Rive won't run in Flutter web debug mode

App won't begin running upon flutter run -d chrome if using the runtime. A window is initiated however remains blank and the console never reports service listening.

This only occurs when running without the Skia flag. Running with CanvasKit works fine.

Enrich flutter package documentation

As a developer I look in to the docs of any package and its example to understand the usage of it. I think there should be a richer documentation so that developers are confident to use this package in their apps. I could not find anything as documentation on pub.dev

Request for Clarification: Flare-Flutter vs Rive Flutter Runtime Use Cases

Could someone clarify whether this (rive-flutter) or flare-flutter are intended for use with the .riv files created by Rive.app? There is no obvious delineation between the two on this or the Rive website, and various online tutorials offer conflicting advice.

If possible, please clarify the following additional questions:

Which of the two libraries (or both) will be maintained alongside flutter going forward?
Will both be updated for null safety?
What about flutter 2.0? Desktop support?

RiveRenderBox does not support Intrinsics

The Rive widget and render boxes currently do not support intrinsics at all.

When using IntrinsicWidth or IntrinsicHeight (for example), the Rive widget just returns 0 size (default fallback).
More importantly, when relying on intrinsics (using custom render objects or ones that rely on it anyway), Rive does not work either.

You can learn more about intrinsics here.


This somewhat relates to #53, however, that is only an issue with the naming.

If animationName changed from 'Untitled 1' to anything else - no playback.

If I change a name of the animation in an animation controller - animation doesn't play. If I set it back to 'Untitled 1' - animation performs as expected.

class CircularLoadingIndicator extends StatefulWidget {
  const CircularLoadingIndicator({
    Key key,
  }) : super(key: key);

  @override
  _CircularLoadingIndicatorState createState() => _CircularLoadingIndicatorState();
}

class _CircularLoadingIndicatorState extends State<CircularLoadingIndicator> with SingleTickerProviderStateMixin {
  Artboard _riveArtboard;
  RiveAnimationController _controller;

  @override
  void initState() {
    rootBundle.load(RiveElements.circularLoadingIndicator).then(
      (data) async {
        final file = RiveFile();

        if (file.import(data)) {
          final artBoard = file.mainArtboard
            ..addController(
              _controller = SimpleAnimation('Spinning')..isActive = true,  //works only if 'Untitled 1'
            );
          setState(() => _riveArtboard = artBoard);
        }
      },
    );
    super.initState();
  }

  @override
  Widget build(BuildContext context) => SizedBox(
        width: 44,
        height: 44,
        child: Rive(
          artboard: _riveArtboard,
        ),
      );

  @override
  void dispose() {
    _controller?.dispose();
    super.dispose();
  }
}

Exception on the NNBD beta

When I try to load my .riv file with the new rive: ^0.7.0-nullsafety.0 I get the following message:

โ•โ•โ•โ•โ•โ•โ•โ• Exception caught by widgets library โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•
The following UnsupportedError was thrown building FutureBuilder<ByteData>(dirty, state: _FutureBuilderState<ByteData>#c1468):
Unsupported operation: Unsupported property key 1. A new runtime is likely necessary to play this file.

The relevant error-causing widget was
FutureBuilder<ByteData>
package:rive_test/main.dart:83
When the exception was thrown, this was the stack
#0      _skipProperty                                                          package:rive/src/rive_file.dart:63
#1      _readRuntimeObject                                                     package:rive/src/rive_file.dart:49
#2      new RiveFile._                                                         package:rive/src/rive_file.dart:103
#3      new RiveFile.import                                                    package:rive/src/rive_file.dart:217
#4      _MyHomePageState.build.<anonymous closure>                             package:rive_test/main.dart:87
...
โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•โ•

I think it is related to this statement from the changelog: New binary format 7.0 with improved flexibility which is not compatible with 6.0 files. The Rive editor will be able to export both format 6.0 and 7.0, but please note that 6.0 is now deprecated and all new improvements and bug fixes to the format will be done on 7.0. but this means that the "old" format is incompatible with this version? And, if so, how can I get a new format from the editor?

Only runs once

My riv is only running once after build. When I toggle:

setState(() => _controller.isActive = !_controller.isActive);

nothing happens. I can se from the console:

flutter: Animation started playing
flutter: Animation stopped playing

That is starting and stopping almost at the same time. Do I need to rewind it or something?

Update README example for NNBD

I noticed there's a breaking change in the null safe version of this package. This chunk of code in the README should be updated with the latest best practice:

final file = RiveFile();

// Load the RiveFile from the binary data.
if (file.import(data)) { ... }

Rive doesn't play animation

rive: 0.6.8
flutter channel stable, 1.22.3, on Linux.

I follow some guides (one, two) to implement rive package with my flutter application. I follow exactly the way as they recommend but whatever file I pick up the file isn't being played by the app.
What is wrong with it or it might be an issue?

Thanks!

Contents of old .flr file persisting after deletion in Flutter project

I created an animation in Rive, found here, and i exported it into my flutter project. I then edited the Rive animation (changed a color), and then re-exported it and added it into my flutter project. I then deleted the old .flr file that was there, and changed the name of the new .flr file to be the same name of the one I just deleted.

The issue is that part of the object I created in Rive still has an element in it that is the same color in flutter as the deleted .flr file.

Let me know if you need any more info.

Animation don't work

Hello!! I'm a beginner in rive...

My rive animation displays first frame, but animation doesn't start.

rootBundle.load('assets/loading.riv').then((data) async {
        final file = RiveFile();
        if (file.import(data)) {
          final artboard = file.mainArtboard;
          _controller = SimpleAnimation('idle');
          _controller.isActive = true;
          artboard.addController(_controller);
          setState(() => _riveArtboard = artboard);
        }
      },
);
Container(
        width: 140,
        height: 140,
        child: _riveArtboard == null
            ? SizedBox()
            : Rive(artboard: _riveArtboard),
);

Can anybody help me? Thanks.
The riv file is attached.

How to build AnimatedIcon

Hey :)
I would like to build custom AnimatedIcons based on rive. Is that possible? I see no possibility to manipulate the animation status based on the controller or do I miss something?

Looking forward to your response :)

Shape "fill linear" opacity animation

Hello.
I'm trying to hide object with opacity from 100 to 0. It's all fine, but if object has "fill" property with "linear" property it does not hide.
I'm running example in web with flutter beta channel and "rive: ^0.6.3".
Example riv file attached

new_file_2.zip

Expose runtime major/minor version

To know exactly the current installed version of the Rive package is, it would be helpful to expose this file:
https://github.com/rive-app/rive-flutter/blob/master/lib/src/rive_core/runtime/runtime_header.dart#L7

Or at least the runtime's major/minor version publicly.

This helps us to decide which version of the files that can be loaded from the network.
Currently, we have to maintain a separate variable of exactly these two variables in our codebase and keep them up-to-date every time we update the rive package.

So getting them via RuntimeHeader.majorVersion and RuntimeHeader.minorVersion would be very helpful.

Get multiple artboards

Hi, I'm using this library with a single .riv file that has three artboards inside.

At the moment I'm retrieving the artboards calling

riverFile.artboards[0];
riverFile.artboards[1];
riverFile.artboards[2];

But sometimes the artboards I'm getting is not the one I wanted.

It's that the correct way of using this or it exists something better, maybe using the artboards name?

rive v0.6.8 is incompatible with build_runner >=1.12.0

Because build_runner >=1.12.0 depends on graphs ^1.0.0 and rive 0.6.8 depends on graphs ^0.2.0, build_runner >=1.12.0 is incompatible with rive 0.6.8.

I'm using both rive and build_runner in my project, but the latest version of rive did not use the same version of graphs as build_runner. Is it possible to update this?

Thank you in advance.

I have no idea how to export rive2 animations

Everything that worked on FlareActor doesn't work on rive2.
Obviously, I exported the animation, but there are only arbboard's wallpaper and the animation stopped.

I am really wandering. Is it still not supported in the beta version?

Container Box Radius Not Applying to Animation

Hi all,

I'd like to clip the corners of my rive animation so as to round the corners. To do so I did the following (all other code follows the example in your blog):

/// Show the rive file, when loaded
  @override
  Widget build(BuildContext context) {
    return _artboard != null
        ? Container(
            decoration: BoxDecoration(
                border: Border.all(
                  color: Colors.red,
                  width: 5,
                ),
                borderRadius: BorderRadius.circular(100)),
            child: Rive(
              artboard: _artboard,
              fit: BoxFit.cover,
            ),
          )
        : Container();
  }

I expected the Container to contstrain the edges of the Rive animation; instead, the edges of the (square) animation poke through like so:
asdfasdfasdf

Am I missing something? Would love the option to clip/mask animations from within flutter!

Issues with the web editor

Hi there, thanks for the amazing job you are making in the editor, just want to point out that I have seen some issues while I'm using the editor.

  1. The following image shows that sometimes the controls aren't visibles, unless I close the tab or if it's reloaded:

0

I haven't tried yet to refresh the cache of my browser, but hope you can see that issue and may suggest me something to do here.

  1. Another thing that I find it a bit annoying is the fact that a shape doesn't always saves the state when the file/tab/session is closed, some animations also don't save the state (maybe for the same reason?):

If I set a color like #CCCCCC for both, the stroke & the fill:
1

Then, if I set it's opacity to 0:
2

And I save the changes:
3

I reopen the file after the tab was closed:
4

It's supposed to be with an opacity of 0, but it gets ignored:
5

Flutter web: invalid member on null: advance

Hi!

I'm trying to use an animation realized with Rive2, but when the render start the following error is thrown:

The following JSNoSuchMethodError was thrown during paint():
NoSuchMethodError: invalid member on null: 'advance'

The relevant error-causing widget was: 
  Rive file:///Users/CHRX001/Documents/dev/portfolio/lib/widgets/scroll_down_animated.dart:40:54
When the exception was thrown, this was the stack: 
packages/rive/src/rive.dart 71:52                                        advance
packages/rive/src/rive_render_box.dart 111:9                             paint
packages/flutter/src/rendering/object.dart 2311:7                        [_paintWithContext]
packages/flutter/src/rendering/object.dart 189:12                        paintChild
packages/flutter/src/rendering/proxy_box.dart 129:14                     paint
...
The following RenderObject was being processed when the exception was fired: RiveRenderObject#a17bf
...  parentData: <none> (can use size)
...  constraints: BoxConstraints(w=42.0, h=42.0)
...  size: Size(42.0, 42.0)
RenderObject: RiveRenderObject#a17bf
  parentData: <none> (can use size)
  constraints: BoxConstraints(w=42.0, h=42.0)
  size: Size(42.0, 42.0)

And there is the class I use:

class ScrollDownAnimated extends StatefulWidget {
  _ScrollDownAnimatedState createState() => _ScrollDownAnimatedState();
}

class _ScrollDownAnimatedState extends State<ScrollDownAnimated> {
  Artboard _artboard;
  RiveAnimationController _controller;

  @override
  void initState() {
    super.initState();

    rootBundle.load('animations/scroll_down.riv').then((data) async {
      final file = RiveFile();

      if (file.import(data)) {
        final artboard = file.mainArtboard;

        artboard.addController(_controller = SimpleAnimation('default'));
        setState(() => _artboard = artboard);
      }
    });
  }

  @override
  Widget build(BuildContext context) => Center(
        child: Column(
          children: [
            Text('Scroll',
                style: AppTheme.theme.textTheme.bodyText1
                    .copyWith(color: AppTheme.white)),
            SizedBox(height: AppTheme.instance.smallVerticalSpacing / 3),
            SizedBox(width: 42, height: 42, child: Rive(artboard: _artboard))
          ],
        ),
      );
}

If anyone have an idea ? ^^'

Work start not respected on initial load [Bug]

When running an animation with workStart at x frames (x != 0), the animation initially starts at 0 frames. (workStart not respected)

This could be fixed in two ways:

  1. The main controller running the linear animation has to set the initial _time on start to the value of animation.workStart. This would move the work of implementation to the customer's custom controller implementation.
  2. The LinearAnimationInstance should be aware of the initial workStart, and should adjust the starting point of _time accordingly (preferred because no additional workload to the customer) (https://github.com/rive-app/rive-flutter/blob/master/lib/src/rive_core/animation/linear_animation_instance.dart#L21)

Reproducible:
Create an animation, set the work area start to non-zero, loop the work area, run it.
The expected behavior is that the loop should start at the work area start, however, it starts at 0.

Riv not animating

Hello,
The Riv object is not animating, it only shows tge first frame (displayed as an image), i tried the example in the rive package but not working, i changed the object by getting examples from the website(riv) and changed the SimpleAnimation name with no success on both web(chrome) and Android,

Flutter (Channel beta, 1.26.0-17.4.pre, on Microsoft Windows [version 10.0.18363.1316], locale fr-FR)
โ€ข Flutter version 1.26.0-17.4.pre at C:\Users\aksel\AppData\Local\Android\flutter
โ€ข Framework revision 48c9d3e0e1 (2 days ago), 2021-02-10 11:46:09 -0800
โ€ข Engine revision 2c527d6c7e
โ€ข Dart version 2.12.0 (build 2.12.0-259.8.beta)

[โˆš] Android toolchain - develop for Android devices (Android SDK version 30.0.3)
โ€ข Android SDK at C:\Users\aksel\AppData\Local\Android\Sdk
โ€ข Platform android-30, build-tools 30.0.3
โ€ข ANDROID_HOME = C:\Users\aksel\AppData\Local\Android\Sdk
โ€ข Java binary at: C:\Program Files\Android\Android Studio\jre\bin\java
โ€ข Java version OpenJDK Runtime Environment (build 1.8.0_242-release-1644-b01)
โ€ข All Android licenses accepted.

[โˆš] Chrome - develop for the web
โ€ข Chrome at C:\Program Files (x86)\Google\Chrome\Application\chrome.exe

[โˆš] Android Studio (version 4.1.0)
โ€ข Android Studio at C:\Program Files\Android\Android Studio
โ€ข Flutter plugin can be installed from:
https://plugins.jetbrains.com/plugin/9212-flutter
โ€ข Dart plugin can be installed from:
https://plugins.jetbrains.com/plugin/6351-dart
โ€ข Java version OpenJDK Runtime Environment (build 1.8.0_242-release-1644-b01)

[โˆš] VS Code (version 1.52.1)
โ€ข VS Code at C:\Users\aksel\AppData\Local\Programs\Microsoft VS Code
โ€ข Flutter extension can be installed from:
https://marketplace.visualstudio.com/items?itemName=Dart-Code.flutter

[โˆš] Connected device (1 available)
โ€ข Chrome (web) โ€ข chrome โ€ข web-javascript โ€ข Google Chrome 88.0.4324.150

โ€ข No issues found!

Is it possible to export/manipulate the current frame of a paused animation?

On the Rive's landing page, it is stated that:

Or switch it up!
Of course, all of this can be manipulated with code to add even more interactivity. Connect your graphics to data, swap out images at runtime, change colors, follow the mouse position, and more.

are there currently any docs about this?

I have an idling character, ideally I would like to pause the animation with one button and take a screenshot of the current state of my artboard programmatically with another button. The closest thing I could find for achieving this in Flutter is to use a RenderRepaintBoundry.toImage(). I was wondering if there is any "Rive" way to achieve this?

How to precache/preload Rive (.riv) animations?

I've found some info on how to preload Flare (.flr) animations but I can't find any info on how to export an animation from Rive as Flare.

Would be great if there was an example for either of these.

Many thanks

Rive not working on deployment

Hello,
I deployed my Flutter app to Firebase Hosting, but the Rive widget does not appear in the page, as if there was no Rive widget, the naviigator's consol shows no indications.
Localy it works fine,

dependencies:
rive: ^0.6.7
cloud_firestore: ^0.16.0
firebase_core: ^0.7.0

Flutter (Channel beta, 1.26.0-17.4.pre, on Microsoft Windows [version 10.0.18363.1316], locale fr-FR)
โ€ข Flutter version 1.26.0-17.4.pre at C:\Users\aksel\AppData\Local\Android\flutter
โ€ข Framework revision 48c9d3e0e1 (2 days ago), 2021-02-10 11:46:09 -0800
โ€ข Engine revision 2c527d6c7e
โ€ข Dart version 2.12.0 (build 2.12.0-259.8.beta)

[โˆš] Android toolchain - develop for Android devices (Android SDK version 30.0.3)
โ€ข Android SDK at C:\Users\aksel\AppData\Local\Android\Sdk
โ€ข Platform android-30, build-tools 30.0.3
โ€ข ANDROID_HOME = C:\Users\aksel\AppData\Local\Android\Sdk
โ€ข Java binary at: C:\Program Files\Android\Android Studio\jre\bin\java
โ€ข Java version OpenJDK Runtime Environment (build 1.8.0_242-release-1644-b01)
โ€ข All Android licenses accepted.

[โˆš] Chrome - develop for the web
โ€ข Chrome at C:\Program Files (x86)\Google\Chrome\Application\chrome.exe

[โˆš] Android Studio (version 4.1.0)
โ€ข Android Studio at C:\Program Files\Android\Android Studio
โ€ข Flutter plugin can be installed from:
https://plugins.jetbrains.com/plugin/9212-flutter
โ€ข Dart plugin can be installed from:
https://plugins.jetbrains.com/plugin/6351-dart
โ€ข Java version OpenJDK Runtime Environment (build 1.8.0_242-release-1644-b01)

[โˆš] VS Code (version 1.52.1)
โ€ข VS Code at C:\Users\aksel\AppData\Local\Programs\Microsoft VS Code
โ€ข Flutter extension can be installed from:
https://marketplace.visualstudio.com/items?itemName=Dart-Code.flutter

[โˆš] Connected device (1 available)
โ€ข Chrome (web) โ€ข chrome โ€ข web-javascript โ€ข Google Chrome 88.0.4324.150

โ€ข No issues found!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.