CaptureService
A service which provides control over screenshot and video capture features.
Memory category | Instances |
---|
Member index 51
Removed member index 4
History | Member | |
---|---|---|
651 | PostToFeedAsync(capturePath: string, feedCategory: string): Dictionary | |
583 | RetreiveCaptures(): Array | |
673 | StartVideoCaptureInternal(): null | |
673 | StopCapture(): null |
Description
CaptureService
is a client-side service that allows developers to control
how the screenshot and video capture feature integrates with their
experiences. It can be used to include preset moments where a capture is
automatically taken for a user, and that user can then save, share, or delete
the capture.
History 96
- 684 Add OpenCapturePermissionsPrompt
- 684 Add UploadCaptureAsync
- 684 Add ReadCapturesFromGalleryAsync
- 684 Add PromptCaptureGalleryPermission
- 684 Add OnCapturePermissionsPromptFinished
- 683 Add
- 683 Add
- 683 Add GetDeviceInfo
- 681 Remove GetDeviceInfo
- 682 Add GetDeviceInfo
- 677 Add CanCaptureVideo
- 676 Add UserVideoCaptureStartFailed
- 676 Change ReturnType of StartVideoCaptureInternalAsync from VideoCaptureResult to VideoCaptureStartedResult
- 676 Change ReturnType of StartVideoCaptureAsync from VideoCaptureResult to VideoCaptureStartedResult
- 676 Add PreVideoCaptureShared
- 675 Change Parameters of VideoCaptureInProgress from (isInProgress: bool) to (isInProgress: bool, captureTrigger: string)
- 675 Add SaveVideoCaptureToExternalStorage
- 675 Add OnVideoCaptureShared
- 675 Add DeleteVideoCapture
- 674 Add VideoCaptureInProgress
- 674 Add UserVideoCaptureFailed
- 674 Change Parameters of CaptureEnded from () to (captureType: CaptureType)
- 674 Change Parameters of CaptureBegan from () to (captureType: CaptureType)
- 673 Add StopVideoCapture
- 673 Remove StopCapture
- 673 Add StartVideoCaptureInternalAsync
- 673 Remove StartVideoCaptureInternal
- 673 Add StartVideoCaptureAsync
- 672 Add IsCapturingVideo
- 671 Add
- 670 Add StopVideoCaptureInternal
- 670 Add StopCapture
- 670 Add StartVideoCaptureInternal
- 662 Change Parameters of OpenShareCapturePrompt from (promptId: int64, contentId: ContentId, launchData: string) to (promptId: int64, captureContent: Variant, launchData: string)
- 662 Change Parameters of OpenSaveCapturesPrompt from (promptId: int64, contentIds: Array) to (promptId: int64, captures: Array)
- 662 Add TakeCapture
- 662 Change Parameters of PromptShareCapture from (contentId: ContentId, launchData: string, onAcceptedCallback: Function, onDeniedCallback: Function) to (captureContent: Content, launchData: string, onAcceptedCallback: Function, onDeniedCallback: Function)
- 662 Change Parameters of PromptSaveCapturesToGallery from (contentIds: Array, resultCallback: Function) to (captures: Array, resultCallback: Function)
- 662 Change Tags of OnSavePromptFinished from [] to [CustomLuaState]
- 662 Change Parameters of GetCaptureSizeAsync from (captureContentId: ContentId) to (captureContent: Content)
- 662 Change Parameters of GetCaptureFilePathAsync from (captureContentId: ContentId) to (captureContent: Content)
- 651 Remove PostToFeedAsync
- 645 Change Parameters of UserCaptureSaved from (captureContentId: Content) to (captureContentId: ContentId)
- 645 Change Parameters of OpenShareCapturePrompt from (promptId: int64, contentId: Content, launchData: string) to (promptId: int64, contentId: ContentId, launchData: string)
- 645 Change Parameters of SaveScreenshotCapture from () to (additionalInfo: string = )
- 645 Change Parameters of PromptShareCapture from (contentId: Content, launchData: string, onAcceptedCallback: Function, onDeniedCallback: Function) to (contentId: ContentId, launchData: string, onAcceptedCallback: Function, onDeniedCallback: Function)
- 645 Change Parameters of GetCaptureSizeAsync from (captureContentId: Content) to (captureContentId: ContentId)
- 645 Change Parameters of GetCaptureFilePathAsync from (captureContentId: Content) to (captureContentId: ContentId)
- 644 Add PostToFeedAsync
- 641 Add GetCaptureUploadDataAsync
- 632 Change Tags of CaptureSaved from [] to [Deprecated]
- 632 Change PreferredDescriptor of CaptureSaved from to UserCaptureSaved
- 632 Add CreatePostAsync
- 626 Change Parameters of CaptureSavedInternal from (captureInfo: Dictionary) to (captureInfo: Dictionary, triggerSource: string)
- 625 Add
- 625 Add
- 625 Add SaveCapturesToExternalStorageAsync
- 625 Add OnCaptureShared
- 625 Change Tags of CaptureService from [NotCreatable, Service, NotReplicated] to [NotCreatable, Service]
- 621 Add CaptureSavedInternal
- 620 Add DeleteCapturesAsync
- 617 Add GetCaptureStorageSizeAsync
- 610 Change Parameters of OpenShareCapturePrompt from (promptId: int64, contentId: Content, capturePath: string, launchData: string) to (promptId: int64, contentId: Content, launchData: string)
- 610 Add GetCaptureFilePathAsync
- 608 Add CaptureScreenshot
- 605 Change Parameters of OpenShareCapturePrompt from (promptId: int64, contentId: Content, capturePath: string, launchData: Dictionary) to (promptId: int64, contentId: Content, capturePath: string, launchData: string)
- 605 Add OpenSaveCapturesPrompt
- 605 Change Security of CaptureSaved from RobloxScriptSecurity to None
- 605 Add CaptureEnded
- 605 Add CaptureBegan
- 605 Change Parameters of PromptShareCapture from (contentId: Content, launchData: Dictionary, onAcceptedCallback: Function, onDeniedCallback: Function) to (contentId: Content, launchData: string, onAcceptedCallback: Function, onDeniedCallback: Function)
- 605 Add PromptSaveCapturesToGallery
- 605 Add OnSavePromptFinished
- 605 Add OnCaptureEnded
- 605 Add OnCaptureBegan
- 604 Add UserCaptureSaved
- 604 Add OpenShareCapturePrompt
- 604 Add PromptShareCapture
- 604 Add OnSharePromptFinished
- 603 Remove UserCaptureSaved
- 603 Remove OpenShareCapturePrompt
- 603 Remove PromptShareCapture
- 603 Remove OnSharePromptFinished
- 604 Add UserCaptureSaved
- 604 Add OpenShareCapturePrompt
- 604 Add PromptShareCapture
- 604 Add OnSharePromptFinished
- 601 Add SaveCaptureToExternalStorage
- 593 Add DeleteCapture
- 587 Add CaptureSaved
- 587 Add GetCaptureSizeAsync
- 583 Add RetrieveCaptures
- 583 Remove RetreiveCaptures
- 580 Add SaveScreenshotCapture
- 580 Add RetreiveCaptures
- 580 Add CaptureService
Members 51
CanCaptureVideo
Parameters (0) | ||
---|---|---|
No parameters. | ||
Returns (1) | ||
bool |
Security | RobloxScriptSecurity |
---|---|
Thread safety | Unsafe |
History 1
- 677 Add CanCaptureVideo
CaptureBegan
Parameters (1) | |
---|---|
captureType | CaptureType |
This event fires right before a new capture is taken. It can be used to customize the capture experience, for example by hiding certain GUI elements.
Thread safety | Unsafe |
---|
History 2
- 674 Change Parameters of CaptureBegan from () to (captureType: CaptureType)
- 605 Add CaptureBegan
CaptureEnded
Parameters (1) | |
---|---|
captureType | CaptureType |
This event fires after a new capture completes. It can be used to restore any changes made when the CaptureBegan event fired.
Thread safety | Unsafe |
---|
History 2
- 674 Change Parameters of CaptureEnded from () to (captureType: CaptureType)
- 605 Add CaptureEnded
CaptureSaved
Parameters (1) | |
---|---|
captureInfo | Dictionary |
Thread safety | Unsafe |
---|
History 4
- 632 Change Tags of CaptureSaved from [] to [Deprecated]
- 632 Change PreferredDescriptor of CaptureSaved from to UserCaptureSaved
- 605 Change Security of CaptureSaved from RobloxScriptSecurity to None
- 587 Add CaptureSaved
CaptureSavedInternal
Parameters (2) | |
---|---|
captureInfo | Dictionary |
triggerSource | string |
Security | RobloxScriptSecurity |
---|---|
Thread safety | Unsafe |
History 2
- 626 Change Parameters of CaptureSavedInternal from (captureInfo: Dictionary) to (captureInfo: Dictionary, triggerSource: string)
- 621 Add CaptureSavedInternal
CaptureScreenshot
Parameters (1) | ||
---|---|---|
onCaptureReady | Function | |
Returns (1) | ||
null |
This method captures a screenshot for the user but does not immediately
save it to their Captures gallery within the experience's main menu.
Instead, a temporary contentId
is created to identify the new capture.
The onCaptureReady
callback can be used to prompt the user to save or
share the screenshot:
1 2 3 4 5 6 7 8 9 10 |
|
Thread safety | Unsafe |
---|
History 1
- 608 Add CaptureScreenshot
CreatePostAsync
Parameters (2) | ||
---|---|---|
pathArr | Array | |
caption | string | |
Returns (1) | ||
Dictionary |
Security | RobloxScriptSecurity |
---|---|
Thread safety | Unsafe |
History 1
- 632 Add CreatePostAsync
DeleteCapture
Parameters (1) | ||
---|---|---|
capturePath | string | |
Returns (1) | ||
null |
Security | RobloxScriptSecurity |
---|---|
Thread safety | Unsafe |
History 1
- 593 Add DeleteCapture
DeleteCapturesAsync
Parameters (1) | ||
---|---|---|
pathArr | Array | |
Returns (1) | ||
int64 |
Security | RobloxScriptSecurity |
---|---|
Thread safety | Unsafe |
History 1
DeleteVideoCapture
Parameters (1) | ||
---|---|---|
videoCapture | VideoCapture | |
Returns (1) | ||
null |
Security | RobloxScriptSecurity |
---|---|
Thread safety | Unsafe |
History 1
GetCaptureFilePathAsync
Parameters (1) | ||
---|---|---|
captureContent | Content | |
Returns (1) | ||
string |
Security | RobloxScriptSecurity |
---|---|
Thread safety | Unsafe |
History 3
- 662 Change Parameters of GetCaptureFilePathAsync from (captureContentId: ContentId) to (captureContent: Content)
- 645 Change Parameters of GetCaptureFilePathAsync from (captureContentId: Content) to (captureContentId: ContentId)
- 610 Add GetCaptureFilePathAsync
GetCaptureSizeAsync
Parameters (1) | ||
---|---|---|
captureContent | Content | |
Returns (1) | ||
Vector2 |
Security | RobloxScriptSecurity |
---|---|
Thread safety | Unsafe |
History 3
- 662 Change Parameters of GetCaptureSizeAsync from (captureContentId: ContentId) to (captureContent: Content)
- 645 Change Parameters of GetCaptureSizeAsync from (captureContentId: Content) to (captureContentId: ContentId)
- 587 Add GetCaptureSizeAsync
GetCaptureStorageSizeAsync
Parameters (1) | ||
---|---|---|
pathArr | Array | |
Returns (1) | ||
int64 |
Security | RobloxScriptSecurity |
---|---|
Thread safety | Unsafe |
History 1
GetCaptureUploadDataAsync
Parameters (1) | ||
---|---|---|
capturePath | string | |
Returns (1) | ||
Dictionary |
Security | RobloxScriptSecurity |
---|---|
Thread safety | Unsafe |
History 1
GetDeviceInfo
Parameters (0) | ||
---|---|---|
No parameters. | ||
Returns (1) | ||
Dictionary |
Thread safety | Unsafe |
---|
History 3
- 683 Add GetDeviceInfo
- 681 Remove GetDeviceInfo
- 682 Add GetDeviceInfo
IsCapturingVideo
Parameters (0) | ||
---|---|---|
No parameters. | ||
Returns (1) | ||
bool |
Security | RobloxScriptSecurity |
---|---|
Thread safety | Unsafe |
History 1
- 672 Add IsCapturingVideo
OnCaptureBegan
Parameters (0) | ||
---|---|---|
No parameters. | ||
Returns (1) | ||
null |
Security | RobloxScriptSecurity |
---|---|
Thread safety | Unsafe |
History 1
- 605 Add OnCaptureBegan
OnCaptureEnded
Parameters (0) | ||
---|---|---|
No parameters. | ||
Returns (1) | ||
null |
Security | RobloxScriptSecurity |
---|---|
Thread safety | Unsafe |
History 1
- 605 Add OnCaptureEnded
OnCapturePermissionsPromptFinished
Parameters (2) | ||
---|---|---|
promptId | int64 | |
wasAccepted | bool | |
Returns (1) | ||
null |
Security | RobloxScriptSecurity |
---|---|
Thread safety | Unsafe |
History 1
OnSavePromptFinished
Parameters (2) | ||
---|---|---|
promptId | int64 | |
results | Dictionary | |
Returns (1) | ||
null |
Security | RobloxScriptSecurity |
---|---|
Thread safety | Unsafe |
History 2
- 662 Change Tags of OnSavePromptFinished from [] to [CustomLuaState]
- 605 Add OnSavePromptFinished
OpenCapturePermissionsPrompt
Parameters (2) | |
---|---|
promptId | int64 |
captureGalleryPermission | CaptureGalleryPermission |
Security | RobloxScriptSecurity |
---|---|
Thread safety | Unsafe |
History 1
OpenSaveCapturesPrompt
Parameters (2) | |
---|---|
promptId | int64 |
captures | Array |
Security | RobloxScriptSecurity |
---|---|
Thread safety | Unsafe |
History 2
- 662 Change Parameters of OpenSaveCapturesPrompt from (promptId: int64, contentIds: Array) to (promptId: int64, captures: Array)
- 605 Add OpenSaveCapturesPrompt
PromptCaptureGalleryPermission
Parameters (3) | ||
---|---|---|
captureGalleryPermission | CaptureGalleryPermission | |
onAcceptedCallback | Function | |
onDeniedCallback | Function | |
Returns (1) | ||
null |
Thread safety | Unsafe |
---|
History 1
PromptSaveCapturesToGallery
Parameters (2) | ||
---|---|---|
captures | Array | |
resultCallback | Function | |
Returns (1) | ||
null |
This method prompts the user to save the captures identified by the
provided contentIds
to their Captures gallery within the
experience's main menu.
Thread safety | Unsafe |
---|
History 2
- 662 Change Parameters of PromptSaveCapturesToGallery from (contentIds: Array, resultCallback: Function) to (captures: Array, resultCallback: Function)
- 605 Add PromptSaveCapturesToGallery
ReadCapturesFromGalleryAsync
Parameters (1) | Default | |
---|---|---|
captureTypeFilters | Array | {} |
Returns (1) | ||
Tuple |
Thread safety | Unsafe |
---|
History 1
RetrieveCaptures
Parameters (0) | ||
---|---|---|
No parameters. | ||
Returns (1) | ||
Array |
Security | RobloxScriptSecurity |
---|---|
Thread safety | Unsafe |
History 1
- 583 Add RetrieveCaptures
SaveCaptureToExternalStorage
Parameters (1) | ||
---|---|---|
capturePath | string | |
Returns (1) | ||
null |
Security | RobloxScriptSecurity |
---|---|
Thread safety | Unsafe |
History 1
SaveCapturesToExternalStorageAsync
Parameters (1) | ||
---|---|---|
pathArr | Array | |
Returns (1) | ||
int64 |
Security | RobloxScriptSecurity |
---|---|
Thread safety | Unsafe |
History 1
SaveScreenshotCapture
Parameters (1) | Default | |
---|---|---|
additionalInfo | string | |
Returns (1) | ||
null |
Security | RobloxScriptSecurity |
---|---|
Thread safety | Unsafe |
History 2
- 645 Change Parameters of SaveScreenshotCapture from () to (additionalInfo: string = )
- 580 Add SaveScreenshotCapture
SaveVideoCaptureToExternalStorage
Parameters (1) | ||
---|---|---|
videoCapture | VideoCapture | |
Returns (1) | ||
null |
Security | RobloxScriptSecurity |
---|---|
Thread safety | Unsafe |
History 1
StartVideoCaptureAsync
Parameters (2) | Default | |
---|---|---|
onCaptureReady | Function | |
captureParams | Dictionary | nil |
Returns (1) | ||
VideoCaptureStartedResult |
This method initiates a video capture recording. The recording will continue until the StopVideoCapture() method is called, or when 30 seconds have passed, whichever comes first. During the video recording, all user voices are muted.
The onCaptureReady
callback can be used to prompt the user to save or
share the video capture.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 |
|
Thread safety | Unsafe |
---|
History 2
- 676 Change ReturnType of StartVideoCaptureAsync from VideoCaptureResult to VideoCaptureStartedResult
- 673 Add StartVideoCaptureAsync
StartVideoCaptureInternalAsync
Parameters (0) | ||
---|---|---|
No parameters. | ||
Returns (1) | ||
VideoCaptureStartedResult |
Security | RobloxScriptSecurity |
---|---|
Thread safety | Unsafe |
History 2
- 676 Change ReturnType of StartVideoCaptureInternalAsync from VideoCaptureResult to VideoCaptureStartedResult
- 673 Add StartVideoCaptureInternalAsync
StopVideoCapture
Parameters (0) | ||
---|---|---|
No parameters. | ||
Returns (1) | ||
null |
This method ends a video capture that was started by the StartVideoCaptureAsync() method.
Thread safety | Unsafe |
---|
History 1
- 673 Add StopVideoCapture
StopVideoCaptureInternal
Parameters (0) | ||
---|---|---|
No parameters. | ||
Returns (1) | ||
null |
Security | RobloxScriptSecurity |
---|---|
Thread safety | Unsafe |
History 1
TakeCapture
Parameters (2) | Default | |
---|---|---|
onCaptureReady | Function | |
captureParams | Dictionary | nil |
Returns (1) | ||
null |
Thread safety | Unsafe |
---|
History 1
- 662 Add TakeCapture
UploadCaptureAsync
Parameters (1) | ||
---|---|---|
capture | Capture | |
Returns (1) | ||
Tuple |
Thread safety | Unsafe |
---|
History 1
UserCaptureSaved
Parameters (1) | |
---|---|
captureContentId | ContentId |
This event fires when the user saves a screenshot using the Roblox screenshot capture UI. It can be used for analytics or to prompt the user to share their capture.
Thread safety | Unsafe |
---|
History 4
- 645 Change Parameters of UserCaptureSaved from (captureContentId: Content) to (captureContentId: ContentId)
- 604 Add UserCaptureSaved
- 603 Remove UserCaptureSaved
- 604 Add UserCaptureSaved
UserVideoCaptureFailed
Parameters (1) | |
---|---|
result | VideoCaptureResult |
Security | RobloxScriptSecurity |
---|---|
Thread safety | Unsafe |
History 1
UserVideoCaptureStartFailed
Parameters (1) | |
---|---|
result | VideoCaptureStartedResult |
Security | RobloxScriptSecurity |
---|---|
Thread safety | Unsafe |
History 1
VideoCaptureInProgress
Parameters (2) | |
---|---|
isInProgress | bool |
captureTrigger | string |
Security | RobloxScriptSecurity |
---|---|
Thread safety | Unsafe |
History 2
- 675 Change Parameters of VideoCaptureInProgress from (isInProgress: bool) to (isInProgress: bool, captureTrigger: string)
- 674 Add VideoCaptureInProgress
Removed members 4
PostToFeedAsync
Parameters (2) | ||
---|---|---|
capturePath | string | |
feedCategory | string | |
Returns (1) | ||
Dictionary |
Security | RobloxScriptSecurity |
---|---|
Thread safety | Unsafe |
History 2
- 651 Remove PostToFeedAsync
- 644 Add PostToFeedAsync
RetreiveCaptures
Parameters (0) | ||
---|---|---|
No parameters. | ||
Returns (1) | ||
Array |
Security | RobloxScriptSecurity |
---|---|
Thread safety | Unsafe |
History 2
- 583 Remove RetreiveCaptures
- 580 Add RetreiveCaptures
StartVideoCaptureInternal
Parameters (0) | ||
---|---|---|
No parameters. | ||
Returns (1) | ||
null |
Security | RobloxScriptSecurity |
---|---|
Thread safety | Unsafe |
History 2
StopCapture
Parameters (0) | ||
---|---|---|
No parameters. | ||
Returns (1) | ||
null |
Security | RobloxScriptSecurity |
---|---|
Thread safety | Unsafe |
History 2
- 673 Remove StopCapture
- 670 Add StopCapture