Changed left and right image orientation angles to match iOS UIImageOrientation

This commit is contained in:
Prianka Liz Kariat 2023-07-07 19:57:44 +05:30
parent cb1035a9ee
commit 7556a3f1b4
2 changed files with 4 additions and 4 deletions

View File

@ -402,7 +402,7 @@ static NSString *const kLiveStreamTestsDictExpectationKey = @"expectation";
];
MPPImage *image = [self imageWithFileInfo:kBurgerRotatedImage
orientation:UIImageOrientationRight];
orientation:UIImageOrientationLeft];
[self assertResultsOfClassifyImage:image
usingImageClassifier:imageClassifier
@ -425,7 +425,7 @@ static NSString *const kLiveStreamTestsDictExpectationKey = @"expectation";
displayName:nil] ];
MPPImage *image = [self imageWithFileInfo:kMultiObjectsRotatedImage
orientation:UIImageOrientationRight];
orientation:UIImageOrientationLeft];
// roi around folding chair
MPPImageClassifierResult *imageClassifierResult =

View File

@ -30,13 +30,13 @@ using ::mediapipe::tasks::core::PacketsCallback;
} // namespace
/** Rotation degrees for a 90 degree rotation to the right. */
static const NSInteger kMPPOrientationDegreesRight = -90;
static const NSInteger kMPPOrientationDegreesRight = -270;
/** Rotation degrees for a 180 degree rotation. */
static const NSInteger kMPPOrientationDegreesDown = -180;
/** Rotation degrees for a 90 degree rotation to the left. */
static const NSInteger kMPPOrientationDegreesLeft = -270;
static const NSInteger kMPPOrientationDegreesLeft = -90;
static NSString *const kTaskPrefix = @"com.mediapipe.tasks.vision";