FinderPatternFinder$FurthestFromAverageComparator.smali
.class final Lcom/google/zxing/qrcode/detector/FinderPatternFinder$FurthestFromAverageComparator;
.super Ljava/lang/Object;
.source "FinderPatternFinder.java"
# interfaces
.implements Ljava/io/Serializable;
.implements Ljava/util/Comparator;
# annotations
.annotation system Ldalvik/annotation/EnclosingClass;
value = Lcom/google/zxing/qrcode/detector/FinderPatternFinder;
.end annotation
.annotation system Ldalvik/annotation/InnerClass;
accessFlags = 0x1a
name = "FurthestFromAverageComparator"
.end annotation
.annotation system Ldalvik/annotation/Signature;
value = {
"Ljava/lang/Object;",
"Ljava/io/Serializable;",
"Ljava/util/Comparator<",
"Lcom/google/zxing/qrcode/detector/FinderPattern;",
">;"
}
.end annotation
# instance fields
.field private final average:F
# direct methods
.method static constructor <clinit>()V
.registers 1
return-void
.end method
.method private constructor <init>(F)V
.registers 2
.param p1, "f" # F
.line 660
invoke-direct {p0}, Ljava/lang/Object;-><init>()V
.line 661
iput p1, p0, Lcom/google/zxing/qrcode/detector/FinderPatternFinder$FurthestFromAverageComparator;->average:F
.line 662
return-void
.end method
.method synthetic constructor <init>(FLcom/google/zxing/qrcode/detector/FinderPatternFinder$1;)V
.registers 3
.param p1, "x0" # F
.param p2, "x1" # Lcom/google/zxing/qrcode/detector/FinderPatternFinder$1;
.line 658
invoke-direct {p0, p1}, Lcom/google/zxing/qrcode/detector/FinderPatternFinder$FurthestFromAverageComparator;-><init>(F)V
return-void
.end method
# virtual methods
.method public compare(Lcom/google/zxing/qrcode/detector/FinderPattern;Lcom/google/zxing/qrcode/detector/FinderPattern;)I
.registers 6
.param p1, "center1" # Lcom/google/zxing/qrcode/detector/FinderPattern;
.param p2, "center2" # Lcom/google/zxing/qrcode/detector/FinderPattern;
.line 665
invoke-virtual {p2}, Lcom/google/zxing/qrcode/detector/FinderPattern;->getEstimatedModuleSize()F
move-result v0
iget v1, p0, Lcom/google/zxing/qrcode/detector/FinderPatternFinder$FurthestFromAverageComparator;->average:F
sub-float/2addr v0, v1
invoke-static {v0}, Ljava/lang/Math;->abs(F)F
move-result v0
.line 666
invoke-virtual {p1}, Lcom/google/zxing/qrcode/detector/FinderPattern;->getEstimatedModuleSize()F
move-result v1
iget v2, p0, Lcom/google/zxing/qrcode/detector/FinderPatternFinder$FurthestFromAverageComparator;->average:F
sub-float/2addr v1, v2
invoke-static {v1}, Ljava/lang/Math;->abs(F)F
move-result v1
.line 665
invoke-static {v0, v1}, Ljava/lang/Float;->compare(FF)I
move-result v0
return v0
.end method
.method public bridge synthetic compare(Ljava/lang/Object;Ljava/lang/Object;)I
.registers 3
.line 658
check-cast p1, Lcom/google/zxing/qrcode/detector/FinderPattern;
check-cast p2, Lcom/google/zxing/qrcode/detector/FinderPattern;
invoke-virtual {p0, p1, p2}, Lcom/google/zxing/qrcode/detector/FinderPatternFinder$FurthestFromAverageComparator;->compare(Lcom/google/zxing/qrcode/detector/FinderPattern;Lcom/google/zxing/qrcode/detector/FinderPattern;)I
move-result p1
return p1
.end method