Skip to content

Instantly share code, notes, and snippets.

@CalvinGonsalves
CalvinGonsalves / main.dart
Last active September 23, 2022 23:05
open and close video stream from web cam in flutter web
import 'package:flutter/material.dart';
import 'dart:html' as html;
import 'dart:ui' as ui;
void main() {
runApp(MyApp());
}
class MyApp extends StatelessWidget {
@override
@CalvinGonsalves
CalvinGonsalves / main.dart
Last active January 11, 2021 15:10
HtmlElementView does not display video from webcam after popping the dialog and returning back to access web cam
import 'dart:async';
import 'dart:typed_data';
import 'package:flutter/material.dart';
import 'package:flutter/services.dart';
import 'dart:html' as html;
import 'dart:ui' as ui;
void main() {
runApp(MyApp());