MLKitSegmentationCommon 架構參考資料
透過集合功能整理內容
你可以依據偏好儲存及分類內容。
SegmentationMask
class SegmentationMask : NSObject
分段作業的結果。
-
遮罩的區隔緩衝區。
緩衝區格式是 kCVPixelFormatType_OneComponent32Float
。每個像素
會在遮罩 [0.0f, 1.0f] 的範圍中,其中 1 代表像素位於內部
區隔區域,0 表示像素超出區隔區域。呼叫者
可能會查詢遮罩來取得每像素的區域值預估值,但必須自行定義
自己的中間值門檻緩衝區為 SegmentationMask
所擁有
並將於容器取消配置時釋出,除非呼叫端明確維持
透過 CVPixelBufferRetain()
參照該資源
聲明
Swift
var buffer: CVPixelBuffer { get }
-
除非另有註明,否則本頁面中的內容是採用創用 CC 姓名標示 4.0 授權,程式碼範例則為阿帕契 2.0 授權。詳情請參閱《Google Developers 網站政策》。Java 是 Oracle 和/或其關聯企業的註冊商標。
上次更新時間:2024-08-21 (世界標準時間)。
[[["容易理解","easyToUnderstand","thumb-up"],["確實解決了我的問題","solvedMyProblem","thumb-up"],["其他","otherUp","thumb-up"]],[["缺少我需要的資訊","missingTheInformationINeed","thumb-down"],["過於複雜/步驟過多","tooComplicatedTooManySteps","thumb-down"],["過時","outOfDate","thumb-down"],["翻譯問題","translationIssue","thumb-down"],["示例/程式碼問題","samplesCodeIssue","thumb-down"],["其他","otherDown","thumb-down"]],["上次更新時間:2024-08-21 (世界標準時間)。"],[[["`SegmentationMask` stores the result of a segmentation operation."],["The `buffer` property provides pixel-level segmentation data where values range from 0.0 to 1.0, indicating the likelihood of a pixel belonging to the segmented region."],["The buffer's format is `kCVPixelFormatType_OneComponent32Float` and is owned by the `SegmentationMask` instance."],["Users are responsible for interpreting intermediate pixel values and defining thresholds for segment inclusion."]]],[]]