Skip to content

Uncaught (in promise) TypeError: Failed to execute 'createObjectURL' on 'URL': Overload resolution failed. #285

@lewisMachilika

Description

@lewisMachilika

`

<title>Instascan</title> <script type="text/javascript" src="instascan.min.js"></script> <style> #video,#video_,#preview{ position: relative; width: 100%; height: 80%; top: 0.0%; border: 3px solid #E43E26; text-align: center;
        display: block;
        margin-left: auto;
        margin-right: auto;
    }
    #canvas{
        position: relative;
        width: 100%;
        height: 80%;
        top: 0.0%;
        text-align: center;

        display: block;
        margin-left: auto;
        margin-right: auto;
    }
</style>
<script type="text/javascript"> let opts = { continuous: true, video: document.getElementById('preview'), mirror: true, captureImage: false, backgroundScan: true, refractoryPeriod: 5000, scanPeriod: 1 };
  let scanner = new Instascan.Scanner(opts);
  scanner.addListener('scan', function (content) {
    console.log(content);
  });
  Instascan.Camera.getCameras().then(function (cameras) {
    if (cameras.length > 0) {
      scanner.start(cameras[0]);
    } else {
      console.error('No cameras found.');
    }
  }).catch(function (e) {
    console.error(e);
  });
</script>
`

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions