Fixed formatting in MPPImageSegmenter.mm
This commit is contained in:
parent
d9d4016334
commit
f1a5c8d549
|
@ -243,14 +243,15 @@ using ::mediapipe::tasks::core::PacketsCallback;
|
|||
return;
|
||||
}
|
||||
|
||||
// Output packet map is moved to a block variable that will not be deallocated for the lifetime of the `dispatch_async` call. Eventhough masks are not copied, we have to ensure that they are not de allocated before the delegate call completes.
|
||||
// Output packet map is moved to a block variable that will not be deallocated for the lifetime of
|
||||
// the `dispatch_async` call. Since masks are not copied, this ensures that they are only
|
||||
// deallocated after the delegate call completes.
|
||||
__block PacketMap outputPacketMap = std::move(liveStreamResult.value());
|
||||
if (outputPacketMap[kImageOutStreamName.cppString].IsEmpty()) {
|
||||
return;
|
||||
}
|
||||
|
||||
dispatch_async(_callbackQueue, ^{
|
||||
|
||||
MPPImageSegmenterResult *result =
|
||||
[MPPImageSegmenter imageSegmenterResultWithOutputPacketMap:outputPacketMap
|
||||
shouldCopyMaskPacketData:NO];
|
||||
|
|
Loading…
Reference in New Issue
Block a user