问题标签 [webcam.js]

For questions regarding programming in ECMAScript (JavaScript/JS) and its various dialects/implementations (excluding ActionScript). Note JavaScript is NOT the same as Java! Please include all relevant tags on your question; e.g., [node.js], [jquery], [json], [reactjs], [angular], [ember.js], [vue.js], [typescript], [svelte], etc.

0 投票
2 回答
47 浏览

c# - 位图 C# ASP.NET 的 URI

我正在使用 webcam.js 在 ASP.NET MVC 中捕获一个 URI。我想将此 URI 转换为 C# 中的位图。下面是我当前尝试将 URI 解析为位图的代码,但是它"Invalid length for a Base-64 char array or string"在创建字节缓冲区时会出错。我也尝试将其作为 C# Uri 类型引入,但没有任何运气。

这是我从 webcam.js 对象 data_uri 发布的 URI,它在 html 中呈现图像。

感谢您的任何帮助!