Currently I am working on a application like snapchat and tik-tok and I need to pre buffer videos or store them in cache memory before playing and play them from cache memory
Asked
Active
Viewed 670 times
3
-
1Did you get any solution? – Pratik Butani Sep 13 '21 at 18:22
1 Answers
-2
Use precache() method to pre-load the videos before rendering the screen.
@override
void didChangeDependencies() {
precacheImage(theImage.image, context);
super.didChangeDependencies();
}
Or use precacheImage(videoName, context);
before returning Widget in build method.

Tanha Patel
- 395
- 2
- 9