translateY method

double translateY(
  1. double y,
  2. InputImageRotation rotation,
  3. Size size,
  4. Size absoluteImageSize,
)

Implementation

double translateY(double y, InputImageRotation rotation, Size size,
    Size absoluteImageSize) {
  switch (rotation) {
    case InputImageRotation.rotation90deg:
    case InputImageRotation.rotation270deg:
      return y *
          size.height /
          (Platform.isIOS
              ? absoluteImageSize.height
              : absoluteImageSize.width);
    default:
      return y * size.height / absoluteImageSize.height;
  }
}