Skip to content

Commit

Permalink
2.0.1
Browse files Browse the repository at this point in the history
  • Loading branch information
afriscic committed Nov 19, 2024
1 parent 3d7aa43 commit cf544f2
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>net9.0-android;net9.0-ios;net9.0-maccatalyst;</TargetFrameworks>
<TargetFrameworks>net9.0;net9.0-android;net9.0-ios;net9.0-maccatalyst;</TargetFrameworks>
<!--TargetFrameworks Condition="$([MSBuild]::IsOSPlatform('windows'))">$(TargetFrameworks);net9.0-windows10.0.19041.0</TargetFrameworks-->

<UseMaui>true</UseMaui>
Expand All @@ -10,7 +10,7 @@
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
<IsAotCompatible>true</IsAotCompatible>
<Nullable>enable</Nullable>
<Version>2.0.0</Version>
<Version>2.0.1</Version>
<Authors>Alen Friščić</Authors>
<PackageLicenseExpression>MIT</PackageLicenseExpression>
<PackageReadmeFile>README.md</PackageReadmeFile>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ internal class BarcodeAnalyzer : Java.Lang.Object, ImageAnalysis.IAnalyzer, IOnS

private bool _processInverted = false;
private bool _updateCoordinateTransform = false;
private int _transformDegrees = 0;
private Point _previewViewCenter = new();
private RectF _previewViewRect = new();

Expand Down Expand Up @@ -82,9 +83,10 @@ public void Analyze(IImageProxy proxy)
_cameraManager.CameraView.TriggerOnImageCaptured(image);
}

if (_updateCoordinateTransform)
if (_updateCoordinateTransform || _transformDegrees != _proxy.ImageInfo.RotationDegrees)
{
_coordinateTransform = _cameraManager.GetCoordinateTransform(_proxy);
_transformDegrees = _proxy.ImageInfo.RotationDegrees;

_previewViewCenter.X = _cameraManager.PreviewView.Width / 2;
_previewViewCenter.Y = _cameraManager.PreviewView.Height / 2;
Expand Down

0 comments on commit cf544f2

Please sign in to comment.