摄像头得到的图像是左右相反的,为了得到和照镜子一样的体验,使用Xaml的3DProjection功能额将显示元素180度旋转即可,这是解决前台摄像头显示问题左右翻转问题的一个解决办法
<MediaPlayerElement Grid.Column="0" Name="UIMediaPlayerElement" Stretch="Uniform" AreTransportControlsEnabled="False" Canvas.ZIndex="-1" MaxWidth="720" MaxHeight="720" RenderTransformOrigin="0.5,0.5">
<MediaPlayerElement.Projection>
<PlaneProjection RotationX="180" />
</MediaPlayerElement.Projection>
<MediaPlayerElement.RenderTransform>
<TransformGroup>
<ScaleTransform ScaleX="-1" ScaleY="-1" />
<SkewTransform />
<RotateTransform />
<TranslateTransform />
</TransformGroup>
</MediaPlayerElement.RenderTransform>
</MediaPlayerElement>