This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Get an image dataURL from the canvas. | |
var imageDataURL = hidden_canvas.toDataURL('image/png'); | |
// Set the dataURL as source of an image element, showing the captured photo. | |
image.setAttribute('src', imageDataURL); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var video = document.querySelector('video'), | |
image = document.querySelector('#selfie-image'), | |
// Get the exact size of the video element. | |
width = video.videoWidth, | |
height = video.videoHeight, | |
// Context object for working with the canvas. | |
context = hidden_canvas.getContext('2d'); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using UnityEngine; | |
using System.Collections; | |
public class NumberWizardRandom : MonoBehaviour { | |
// Use this for initialization | |
int max; | |
int min; | |
int guess; |
NewerOlder