CameraVideoApp
).Add Components:
Button1
to the screen from the User Interface
palette and set the text to “Capture Image.”Button2
and rename it with the text “Record Video.”Image1
component to display captured images. Label
to display messages .Layout:
Camera
component from the Media
palette into the workspace. This component will be used to capture images. VideoRecorder
component from the Media
palette into the workspace.1. Record Video Button Click:
Button1
drawer, drag out a when Button1.Click
block.
Camcoder1
drawer, drag out a call Camcoder1.RecordVideo
block and place it inside the click event like this.CamCoder1
drawer, drag out a when CamCoder1.AfterRecording
block
VideoPlayer1
drawer, drag out a set VideoPlayer1.Source
block and attach a get clip with it.
2.Image Capture Button Click:
Button2
drawer, drag out a when Button2.Click
block.Camera1
drawer, drag out a call Camcoder1.TakePicture
block and place it inside the click event like this.Camera1
drawer, drag out a when Camera1.AfterPicture
blockImage1
drawer, drag out a set Image1.Picture
block and attach a get Image with it.