The Camera example application shows you how to work with the Camera Framework API. The source code for this application is available.
The Camera example that allows you to configure and use cameras connected to your board. You can run the Camera example using any camera configuration. This application is useful to test whether cameras connected to your system works, understand camera settings, and how to use the various features for your cameras. The application is meant to be a tool for learning how to use the Camera Framework library to build an application and how to use the API.
The following describes how to run the Camera example application (camera_example) that's available on the reference image.
It's important to note that the frame type formats supported vary from board to board.
# camera_example
Select which example you want to run:
1) Camera viewfinder
2) Record video to a file
3) Camera stream
4) Multiple camera video
5) EGL viewfinder
x) Exit the example
1
Select which of the following 4 cameras you want to use:
1) CAMERA_UNIT_1
2) CAMERA_UNIT_2
3) CAMERA_UNIT_3
4) CAMERA_UNIT_4
1
Select which of the following VF modes you want to use:
2) CAMERA_VFMODE_VIDEO
2
Do you want to modify the viewfinder configuration (y/n)?
n
Do you want to modify image attributes (y/n)?
n
Choose from the following options:
i) Modify image attributes
l) Lock 3A
v) Modify viewfinder configuration
w) Modify whitebalance
x) Exit the example
x
# camera_example
Select which example you want to run:
1) Camera viewfinder
2) Record video to a file
3) Camera stream
4) Multiple camera video
5) EGL viewfinder
x) Exit the example
1
Select which of the following 4 cameras you want to use:
1) CAMERA_UNIT_1
2) CAMERA_UNIT_2
3) CAMERA_UNIT_3
4) CAMERA_UNIT_4
1
Select which of the following VF modes you want to use:
2) CAMERA_VFMODE_VIDEO
2
Do you want to modify the viewfinder configuration (y/n)?
n
Do you want to modify image attributes (y/n)?
n
Choose from the following options:
i) Modify image attributes
l) Lock 3A
v) Modify viewfinder configuration
w) Modify whitebalance
x) Exit the example
x
Select which example you want to run:
1) Camera viewfinder
2) Record video to a file
3) Camera stream
4) Multiple camera video
5) EGL viewfinder
x) Exit the example
x
# camera_example
Select which example you want to run:
1) Camera viewfinder
2) Record video to a file
3) Camera stream
4) Multiple camera video
5) EGL viewfinder
x) Exit the example
1
Select which of the following 4 cameras you want to use:
1) CAMERA_UNIT_1
2) CAMERA_UNIT_2
3) CAMERA_UNIT_3
4) CAMERA_UNIT_4
1
Select which of the following VF modes you want to use:
2) CAMERA_VFMODE_VIDEO
2
Do you want to modify the viewfinder configuration (y/n)?
n
Do you want to modify image attributes (y/n)?
n
Choose from the following options:
i) Modify image attributes
l) Lock 3A
v) Modify viewfinder configuration
w) Modify whitebalance
x) Exit the example
w
Select the desired WB mode:
1) Default
2) Auto
3) Manual (RB Gain)
3
Current value of WB red gain is 128. Do you want to change it (y/n)?
y
Select the desired WB red value within range of 1 to 1023
1023
Current value of WB blue gain is 128. Do you want to change it (y/n)?
y
Select the desired WB blue value within range of 1 to 1023
1
Choose from the following options:
i) Modify image attributes
l) Lock 3A
v) Modify viewfinder configuration
w) Modify whitebalance
x) Exit the example
x
Select which example you want to run:
1) Camera viewfinder
2) Record video to a file
3) Camera stream
4) Multiple camera video
5) EGL viewfinder
x) Exit the example
x
On your host computer, the source code is provided for Camera example. You can build the source and deploy the binary on to your target.