English
continuousCapture
About 275 wordsLess than 1 minute
2026-09-24
This method opens the mobile continuous capture camera.
FxUI.media.continuousCapture(options: Object)Parameters
| Parameter | Description | Type | Allowed Values | Default |
|---|---|---|---|---|
| count | Number of images already selected | number | — | — |
| maxCount | Maximum number of images that can be captured | number | — | — |
| waterMarkInfos | Watermark configuration | Array | — | — |
waterMarkInfos
| Parameter | Description | Type | Allowed Values | Default |
|---|---|---|---|---|
| value | Watermark text, displayed as-is | string | — | — |
Other Fields
The following fields are passed through to the host. PWC does not guarantee the same behavior on App and mini programs.
| Parameter | Description | Type | Allowed Values | Default |
|---|---|---|---|---|
| watermarkStyle | Watermark overlay mode | number | 0 overlay, 1 concat | — |
| showWatermarkLabel | Whether the watermark shows the field name | boolean | true, false | — |
| saveToAlbum | Whether to save images to the album | boolean | true, false | — |
| validLocation | Whether to validate location | boolean | true, false | — |
Code Example
This method returns a Promise object, as shown below:
import FxUI from 'fxui-mobile';
FxUI.media.continuousCapture({
count: 0,
maxCount: 1
}).then((res) => {
console.log('continuousCapture success callback', res)
}).catch((err) => {
console.log('continuousCapture failure callback', err)
})Capture with watermarks:
import FxUI from 'fxui-mobile';
FxUI.media.continuousCapture({
count: 0,
maxCount: 3,
waterMarkInfos: [
{ value: '2026-10-15 14:30' },
{ value: 'Zhang San' },
{ value: 'Haidian, Beijing' }
]
}).then((res) => {
console.log(res.imageInfos)
}).catch((err) => {
console.log(err)
})Return Value
On success, the Promise resolves with:
{
imageInfos: [
{
path: '',
ext: '',
fileName: '',
size: 0
}
]
}| Field | Description |
|---|---|
| path | Image path |
| ext | File extension |
| fileName | File name |
| size | File size |
If the user cancels or the host call fails, the Promise is rejected.
Notes
- The remaining capture count is
maxCount - count. BothcountandmaxCountare recommended. Passcount: 0when no images have been selected yet. - Pass the final text to show in
waterMarkInfos.value.
