diff --git a/mediapipe/tasks/ios/vision/core/sources/MPPVisionPacketCreator.h b/mediapipe/tasks/ios/vision/core/sources/MPPVisionPacketCreator.h index eaf059ad..ed07c6d9 100644 --- a/mediapipe/tasks/ios/vision/core/sources/MPPVisionPacketCreator.h +++ b/mediapipe/tasks/ios/vision/core/sources/MPPVisionPacketCreator.h @@ -41,7 +41,7 @@ * timestamp. * * @param image The image to send to the MediaPipe graph. - * @param timestampMs The timestamp (in milliseconds) to assign to the packet. + * @param timestampInMilliseconds The timestamp (in milliseconds) to assign to the packet. * @param error Pointer to the memory location where errors if any should be saved. If @c NULL, no * error will be saved. * @@ -49,7 +49,7 @@ * occurred during the conversion. */ + (mediapipe::Packet)createPacketWithMPPImage:(MPPImage *)image - timestampMs:(NSInteger)timestampMs + timestampInMilliseconds:(NSInteger)timestampInMilliseconds error:(NSError **)error; /** @@ -66,11 +66,11 @@ * specified timestamp. * * @param image The `NormalizedRect` to send to the MediaPipe graph. - * @param timestampMs The timestamp (in milliseconds) to assign to the packet. + * @param timestampInMilliseconds The timestamp (in milliseconds) to assign to the packet. * * @return The MediaPipe packet containing the normalized rect. */ + (mediapipe::Packet)createPacketWithNormalizedRect:(mediapipe::NormalizedRect &)normalizedRect - timestampMs:(NSInteger)timestampMs; + timestampInMilliseconds:(NSInteger)timestampInMilliseconds; @end diff --git a/mediapipe/tasks/ios/vision/core/sources/MPPVisionPacketCreator.mm b/mediapipe/tasks/ios/vision/core/sources/MPPVisionPacketCreator.mm index bf136a75..af419c6d 100644 --- a/mediapipe/tasks/ios/vision/core/sources/MPPVisionPacketCreator.mm +++ b/mediapipe/tasks/ios/vision/core/sources/MPPVisionPacketCreator.mm @@ -42,7 +42,7 @@ using ::mediapipe::Timestamp; } + (Packet)createPacketWithMPPImage:(MPPImage *)image - timestampMs:(NSInteger)timestampMs + timestampInMilliseconds:(NSInteger)timestampInMilliseconds error:(NSError **)error { std::unique_ptr imageFrame = [image imageFrameWithError:error]; @@ -51,7 +51,7 @@ using ::mediapipe::Timestamp; } return MakePacket(std::move(imageFrame)) - .At(Timestamp(int64(timestampMs * kMicroSecondsPerMilliSecond))); + .At(Timestamp(int64(timestampInMilliseconds * kMicroSecondsPerMilliSecond))); } + (Packet)createPacketWithNormalizedRect:(NormalizedRect &)normalizedRect { @@ -59,9 +59,9 @@ using ::mediapipe::Timestamp; } + (Packet)createPacketWithNormalizedRect:(NormalizedRect &)normalizedRect - timestampMs:(NSInteger)timestampMs { + timestampInMilliseconds:(NSInteger)timestampInMilliseconds { return MakePacket(std::move(normalizedRect)) - .At(Timestamp(int64(timestampMs * kMicroSecondsPerMilliSecond))); + .At(Timestamp(int64(timestampInMilliseconds * kMicroSecondsPerMilliSecond))); } @end