Camera - Displays the camera to take photos and record videos in an Arrangement.

Camera
Displays the camera to take photos and record videos in an Arrangement.

.......... Screenshots ..........

AspectRatio: 1:1

AspectRatio: 3:4

AspectRatio: 9:16

AspectRatio: Full


For a more standard camera size you can leave the Arrangement height at 70%.

  • I'm creating a separate extension to give it the AspectRatio of 1:1, 3:4, 9:16 automatically.

When initializing you must grant this permissions:


StartCamera

Starts the camera and displays it in the Arrangement.


StopCamera

Stops the camera and releases resources.

component_method (12)


SwitchCamera

Switch between front and rear cameras.

component_method (11)


TakePicture

Take a photo and save automatically.

component_method (10)


SetZoomLevel

Adjust the zoom level (1-10)

blocks (12)

You can also zoom by pinching without using this function.


GetZoomLevel

Gets the current zoom level

component_method (9)


GetMaxZoomLevel

Gets the maximum zoom available

component_method (8)


FocusOnPoint

Focus on a specific point on the screen (x, y between 0-1)

blocks (13)


CaptureAndGetPath

Captures a photo and returns the file path

component_method (7)


StartRecording

Start video recording

component_method (6)


StopRecording

Stops video recording

component_method (5)


IsCameraActive

Check if the camera is active.

component_method (4)


CameraResolution

Gets the current camera resolution.

component_method (1)


HasFlash

Check if the device has flash.

component_method (2)


AvailableCamerasCount

Gets the number of available cameras.


IsRecording

Check if video is currently being recorded.

component_method


CameraId

Camera ID to use (0: rear, 1: front)

component_set_get (3)


FlashEnabled

Turn the camera flash on or off

component_set_get (4)


AutoFocusEnabled

Turns autofocus on or off

component_set_get (5)


TouchToFocusEnabled

Turn touch focus on or off

component_set_get (12)

You can focus on a specific point by touching the screen.


JpegQuality

JPEG quality for photos (0-100)

component_set_get (6)


SaveDirectory

Directory where to save the photos

component_set_get (7)

Currently only saving in Pictures is available.


CaptureSoundEnabled

Turn the sound on or off when taking a photo

component_set_get (8)


VideoBitrate

Video bitrate (bits per second)

component_set_get (10)


VideoFrameRate

Frame rate per second for video

component_set_get (9)


FocusFrameColor

Focus frame color

component_set_get


FocusFrameDisappearanceTime

Frame disappearance time in milliseconds


FocusFrameSize

Focus frame size

component_set_get (2)


PictureTaken

It is triggered when a photo has been taken successfully.

component_event


PictureError

Triggered when an error occurs while taking a photo

component_event (1)


CameraReady

It fires when the camera is ready

component_event (7)


CameraSwitched

It fires when the camera is changed

component_event (8)


FocusedOnPoint

It fires when you focus on a touch point

component_event (2)


RecordingStarted

Triggered when video recording starts

component_event (3)


RecordingStopped

Triggered when video recording is stopped

component_event (4)


RecordingError

Triggered when an error occurs during video recording

component_event (9)


ZoomChanged

Triggered when the zoom level changes, either by gestures or programmatically

component_event (5)


ZoomEnded

Fires when the user finishes zooming, either by releasing the screen or ending the pinch gesture

component_event (6)


v1.0 Sep 04, 2025.

Camera.aia (55.2 KB)

joejsanz.joedevcamera.aix (32.0 KB)


JDK: 11
Minimum API Level: 21
Updated On: 2025-09-04T07:00:00Z

Built using: FAST-CLI v4.3.1-premium


Thanks.

8 Likes