Mulai
Salin prompt pengaturan dengan langkah instalasi dan panduan markdown lengkap untuk plugin ini.
Set up this Capacitor plugin in the project.
Use the package manager already used by the project.
Install these package(s): `@capgo/ricoh360`, `@capgo/capacitor-ricoh360-camera-plugin`
Run the required Capacitor sync/update step after installation.
Read this markdown guide for the full setup steps: https://raw.githubusercontent.com/Cap-go/website/refs/heads/main/apps/docs/src/content/docs/docs/plugins/ricoh360-camera/getting-started.mdx
Use that guide for platform-specific steps, native file edits, permissions, config changes, imports, and usage setup.
If that guide references other docs pages, read them too.
Instalasi
Bagian berjudul “Instalasi”bun add @capgo/ricoh360bunx cap syncimport { Ricoh360Camera } from '@capgo/ricoh360';API Pengenalan
Judul Bagian “API Pengenalan”initialize
Judul Bagian “inisialisasi”Menginisialisasi SDK dengan URL kamera
import { Ricoh360Camera } from '@capgo/ricoh360';
await Ricoh360Camera.initialize({} as InitializeOptions);getCameraAsset
Judul Bagian “getCameraAsset”Mengambil asset kamera dari URL dan mengembalikannya sebagai base64
import { Ricoh360Camera } from '@capgo/ricoh360';
await Ricoh360Camera.getCameraAsset({} as GetCameraAssetOptions);listFiles
Judul Bagian “daftarFile”Mendisplay file-file yang disimpan di kamera
import { Ricoh360Camera } from '@capgo/ricoh360';
await Ricoh360Camera.listFiles();capturePicture
Judul Bagian “tangkapGambar”Mengambil gambar
import { Ricoh360Camera } from '@capgo/ricoh360';
await Ricoh360Camera.capturePicture();captureVideo
Bagian berjudul “captureVideo”Mengambil video
import { Ricoh360Camera } from '@capgo/ricoh360';
await Ricoh360Camera.captureVideo({} as VideoCaptureOptions);livePreview
Bagian berjudul “livePreview”Mulai tampilan langsung
import { Ricoh360Camera } from '@capgo/ricoh360';
await Ricoh360Camera.livePreview({} as LivePreviewOptions);stopLivePreview
Bagian berjudul “stopLivePreview”Menghentikan tampilan langsung
import { Ricoh360Camera } from '@capgo/ricoh360';
await Ricoh360Camera.stopLivePreview();readSettings
Bagian berjudul “readSettings”Baca pengaturan kamera
import { Ricoh360Camera } from '@capgo/ricoh360';
await Ricoh360Camera.readSettings({} as { options: string[] });setSettings
Bagian berjudul “setSettings”Atur pengaturan kamera
import { Ricoh360Camera } from '@capgo/ricoh360';
await Ricoh360Camera.setSettings({} as { options: Record<string, any> });sendCommand
Bagian berjudul “sendCommand”Kirim perintah mentah ke kamera
import { Ricoh360Camera } from '@capgo/ricoh360';
await Ricoh360Camera.sendCommand({} as { endpoint: string; payload: Record<string, any> });Referensi Tipe
Bagian berjudul “Referensi Tipe”InitializeOptions
Bagian berjudul “InitializeOptions”export interface InitializeOptions { url: string;}CommandResponse
Bagian berjudul “CommandResponse”export interface CommandResponse { session?: string; info?: string; preview?: string; picture?: string; settings?: string;}GetCameraAssetOptions
Bagian berjudul “GetCameraAssetOptions”export interface GetCameraAssetOptions { url: string; saveToFile?: boolean;}GetCameraAssetResponse
Bagian berjudul “GetCameraAssetResponse”export interface GetCameraAssetResponse { statusCode: number; data: string; // base64 encoded data filePath?: string;}ListFilesOptions
Bagian berjudul “ListFilesOptions”export interface ListFilesOptions { fileType?: 'all' | 'image' | 'video'; startPosition?: number; entryCount?: number; maxThumbSize?: number; _detail?: boolean;}ListFilesResponse
Bagian berjudul “ListFilesResponse”export interface ListFilesResponse { results: { entries: { name: string; fileUrl: string; size: number; dateTimeZone: string; width?: number; height?: number; previewUrl?: string; _projectionType?: string; isProcessed?: boolean; _thumbSize?: number; }[]; totalEntries: number; };}VideoCaptureOptions
Bagian berjudul “VideoCaptureOptions”export interface VideoCaptureOptions { // Define any specific options needed for capturing a video resolution?: '4K' | '2K'; frameRate?: number; bitrate?: number;}LivePreviewOptions
Opsi Live Previewexport interface LivePreviewOptions { displayInFront?: boolean; cropPreview?: boolean;}Sumber Kebenaran
Sumber KebenaranHalaman ini dihasilkan dari plugin’s src/definitions.tsRe-run sinkronisasi ketika publik API berubah di atas