Rabbit-R1/android (non root)/smali/smali_classes3/com/google/zxing/LuminanceSource.smali
2024-05-21 17:08:36 -04:00

217 lines
4.2 KiB
Smali

.class public abstract Lcom/google/zxing/LuminanceSource;
.super Ljava/lang/Object;
.source "LuminanceSource.java"
# instance fields
.field private final height:I
.field private final width:I
# direct methods
.method protected constructor <init>(II)V
.locals 0
.line 33
invoke-direct {p0}, Ljava/lang/Object;-><init>()V
iput p1, p0, Lcom/google/zxing/LuminanceSource;->width:I
iput p2, p0, Lcom/google/zxing/LuminanceSource;->height:I
return-void
.end method
# virtual methods
.method public crop(IIII)Lcom/google/zxing/LuminanceSource;
.locals 0
.line 94
new-instance p0, Ljava/lang/UnsupportedOperationException;
const-string p1, "This luminance source does not support cropping."
invoke-direct {p0, p1}, Ljava/lang/UnsupportedOperationException;-><init>(Ljava/lang/String;)V
throw p0
.end method
.method public final getHeight()I
.locals 0
iget p0, p0, Lcom/google/zxing/LuminanceSource;->height:I
return p0
.end method
.method public abstract getMatrix()[B
.end method
.method public abstract getRow(I[B)[B
.end method
.method public final getWidth()I
.locals 0
iget p0, p0, Lcom/google/zxing/LuminanceSource;->width:I
return p0
.end method
.method public invert()Lcom/google/zxing/LuminanceSource;
.locals 1
.line 109
new-instance v0, Lcom/google/zxing/InvertedLuminanceSource;
invoke-direct {v0, p0}, Lcom/google/zxing/InvertedLuminanceSource;-><init>(Lcom/google/zxing/LuminanceSource;)V
return-object v0
.end method
.method public isCropSupported()Z
.locals 0
const/4 p0, 0x0
return p0
.end method
.method public isRotateSupported()Z
.locals 0
const/4 p0, 0x0
return p0
.end method
.method public rotateCounterClockwise()Lcom/google/zxing/LuminanceSource;
.locals 1
.line 119
new-instance p0, Ljava/lang/UnsupportedOperationException;
const-string v0, "This luminance source does not support rotation by 90 degrees."
invoke-direct {p0, v0}, Ljava/lang/UnsupportedOperationException;-><init>(Ljava/lang/String;)V
throw p0
.end method
.method public rotateCounterClockwise45()Lcom/google/zxing/LuminanceSource;
.locals 1
.line 129
new-instance p0, Ljava/lang/UnsupportedOperationException;
const-string v0, "This luminance source does not support rotation by 45 degrees."
invoke-direct {p0, v0}, Ljava/lang/UnsupportedOperationException;-><init>(Ljava/lang/String;)V
throw p0
.end method
.method public final toString()Ljava/lang/String;
.locals 7
iget v0, p0, Lcom/google/zxing/LuminanceSource;->width:I
.line 134
new-array v0, v0, [B
.line 135
new-instance v1, Ljava/lang/StringBuilder;
iget v2, p0, Lcom/google/zxing/LuminanceSource;->height:I
iget v3, p0, Lcom/google/zxing/LuminanceSource;->width:I
add-int/lit8 v3, v3, 0x1
mul-int/2addr v2, v3
invoke-direct {v1, v2}, Ljava/lang/StringBuilder;-><init>(I)V
const/4 v2, 0x0
move v3, v2
:goto_0
iget v4, p0, Lcom/google/zxing/LuminanceSource;->height:I
if-ge v3, v4, :cond_4
.line 137
invoke-virtual {p0, v3, v0}, Lcom/google/zxing/LuminanceSource;->getRow(I[B)[B
move-result-object v0
move v4, v2
:goto_1
iget v5, p0, Lcom/google/zxing/LuminanceSource;->width:I
if-ge v4, v5, :cond_3
.line 139
aget-byte v5, v0, v4
and-int/lit16 v5, v5, 0xff
const/16 v6, 0x40
if-ge v5, v6, :cond_0
const/16 v5, 0x23
goto :goto_2
:cond_0
const/16 v6, 0x80
if-ge v5, v6, :cond_1
const/16 v5, 0x2b
goto :goto_2
:cond_1
const/16 v6, 0xc0
if-ge v5, v6, :cond_2
const/16 v5, 0x2e
goto :goto_2
:cond_2
const/16 v5, 0x20
.line 150
:goto_2
invoke-virtual {v1, v5}, Ljava/lang/StringBuilder;->append(C)Ljava/lang/StringBuilder;
add-int/lit8 v4, v4, 0x1
goto :goto_1
:cond_3
const/16 v4, 0xa
.line 152
invoke-virtual {v1, v4}, Ljava/lang/StringBuilder;->append(C)Ljava/lang/StringBuilder;
add-int/lit8 v3, v3, 0x1
goto :goto_0
.line 154
:cond_4
invoke-virtual {v1}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
move-result-object p0
return-object p0
.end method