Remove mirrored effect from front camera Remove mirrored effect from front camera dart dart

Remove mirrored effect from front camera


You can use the transform widget to manually mirror the camera widget:

import 'dart:math' as math; // import thisTransform(  alignment: Alignment.center,  transform: Matrix4.rotationY(math.pi),  child: /*Your Camera Widget*/,)


In my case I let the camera widget normal and I apply the transform in preview.

import 'dart:math' as math;if (bytesImage != null) ...[  SizedBox(    width: double.infinity,    height: double.infinity,    child: Transform(      alignment: Alignment.center,      transform: Matrix4.rotationY(math.pi),      child: Image.memory(        bytesImage!,        fit: BoxFit.cover,      ),    ),  ),],