Sử dụng bộ sưu tập để sắp xếp ngăn nắp các trang
Lưu và phân loại nội dung dựa trên lựa chọn ưu tiên của bạn.
ARCore cho phép bạn sử dụng ImageMetadata để truy cập các giá trị khoá siêu dữ liệu từ
kết quả chụp ảnh bằng máy ảnh. Một số loại siêu dữ liệu hình ảnh camera phổ biến mà bạn
có thể muốn truy cập là tiêu cự, dữ liệu dấu thời gian của hình ảnh hoặc ánh sáng
của bạn.
Mô-đun Camera của Android có thể ghi lại 160 tham số trở lên về hình ảnh
cho từng khung hình được chụp, tuỳ thuộc vào khả năng của thiết bị. Để xem danh sách tất cả
khoá siêu dữ liệu có thể dùng, hãy xem ImageMetadata.
Nhận giá trị của từng khoá siêu dữ liệu
Sử dụng getImageMetadata()
để nhận một giá trị khoá siêu dữ liệu cụ thể và nắm bắt MetadataNotFoundException
nếu không có. Ví dụ sau đây cho thấy việc lấy
Giá trị khoá siêu dữ liệu SENSOR_EXPOSURE_TIME.
[[["Dễ hiểu","easyToUnderstand","thumb-up"],["Giúp tôi giải quyết được vấn đề","solvedMyProblem","thumb-up"],["Khác","otherUp","thumb-up"]],[["Thiếu thông tin tôi cần","missingTheInformationINeed","thumb-down"],["Quá phức tạp/quá nhiều bước","tooComplicatedTooManySteps","thumb-down"],["Đã lỗi thời","outOfDate","thumb-down"],["Vấn đề về bản dịch","translationIssue","thumb-down"],["Vấn đề về mẫu/mã","samplesCodeIssue","thumb-down"],["Khác","otherDown","thumb-down"]],["Cập nhật lần gần đây nhất: 2024-10-14 UTC."],[[["ARCore provides access to camera image metadata like focal length, timestamp, and lighting information using `ImageMetadata`."],["Android's `Camera` module can record over 160 image parameters, which can be accessed through the `ImageMetadata` class."],["Developers can retrieve specific metadata values using `getImageMetadata()`, while handling potential exceptions like `MetadataNotFoundException`."],["The provided Java and Kotlin code snippets demonstrate how to obtain the `SENSOR_EXPOSURE_TIME` metadata value from a frame."]]],["ARCore utilizes `ImageMetadata` to access camera image capture metadata, such as focal length, timestamps, and lighting. The Android `Camera` module can record over 160 parameters per frame. To retrieve a specific key value, use `getImageMetadata()`, handling `MetadataNotFoundException`. The example demonstrates fetching the `SENSOR_EXPOSURE_TIME` metadata, using `getLong()` method and handling `NotYetAvailableException` if sensor data is unavailable. Refer to the `ImageMetadata` documentation for the complete list of available keys.\n"]]