Remove unused vars (Java)
Bug: None
Change-Id: I713e4547fc2c9d10f0d0267e8fb562f4ce00fd73
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/367922
Reviewed-by: Zoé Lepaul <xalep@webrtc.org>
Commit-Queue: Jeremy Leconte <jleconte@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#43378}
diff --git a/sdk/android/api/org/webrtc/Camera2Capturer.java b/sdk/android/api/org/webrtc/Camera2Capturer.java
index c4becf4..cb6f0f1 100644
--- a/sdk/android/api/org/webrtc/Camera2Capturer.java
+++ b/sdk/android/api/org/webrtc/Camera2Capturer.java
@@ -15,13 +15,11 @@
import androidx.annotation.Nullable;
public class Camera2Capturer extends CameraCapturer {
- private final Context context;
@Nullable private final CameraManager cameraManager;
public Camera2Capturer(Context context, String cameraName, CameraEventsHandler eventsHandler) {
super(cameraName, eventsHandler, new Camera2Enumerator(context));
- this.context = context;
cameraManager = (CameraManager) context.getSystemService(Context.CAMERA_SERVICE);
}
diff --git a/sdk/android/api/org/webrtc/FileVideoCapturer.java b/sdk/android/api/org/webrtc/FileVideoCapturer.java
index 8270367..408d8b5 100644
--- a/sdk/android/api/org/webrtc/FileVideoCapturer.java
+++ b/sdk/android/api/org/webrtc/FileVideoCapturer.java
@@ -99,10 +99,6 @@
final ByteBuffer dataY = buffer.getDataY();
final ByteBuffer dataU = buffer.getDataU();
final ByteBuffer dataV = buffer.getDataV();
- final int chromaHeight = (frameHeight + 1) / 2;
- final int sizeY = frameHeight * buffer.getStrideY();
- final int sizeU = chromaHeight * buffer.getStrideU();
- final int sizeV = chromaHeight * buffer.getStrideV();
try {
ByteBuffer frameDelim = ByteBuffer.allocate(FRAME_DELIMETER_LENGTH);
diff --git a/sdk/android/api/org/webrtc/RTCStats.java b/sdk/android/api/org/webrtc/RTCStats.java
index eaa28de..ae87bd9 100644
--- a/sdk/android/api/org/webrtc/RTCStats.java
+++ b/sdk/android/api/org/webrtc/RTCStats.java
@@ -77,7 +77,6 @@
.append(type)
.append(", id: ")
.append(id);
- boolean first = true;
for (Map.Entry<String, Object> entry : members.entrySet()) {
builder.append(", ").append(entry.getKey()).append(": ");
appendValue(builder, entry.getValue());
diff --git a/sdk/android/api/org/webrtc/VideoFrameDrawer.java b/sdk/android/api/org/webrtc/VideoFrameDrawer.java
index af32587..7c1259f 100644
--- a/sdk/android/api/org/webrtc/VideoFrameDrawer.java
+++ b/sdk/android/api/org/webrtc/VideoFrameDrawer.java
@@ -141,7 +141,6 @@
final static float[] srcPoints =
new float[] {0f /* x0 */, 0f /* y0 */, 1f /* x1 */, 0f /* y1 */, 0f /* x2 */, 1f /* y2 */};
private final float[] dstPoints = new float[6];
- private final Point renderSize = new Point();
private int renderWidth;
private int renderHeight;
diff --git a/sdk/android/src/java/org/webrtc/AndroidVideoDecoder.java b/sdk/android/src/java/org/webrtc/AndroidVideoDecoder.java
index 47cb568..fbdc072 100644
--- a/sdk/android/src/java/org/webrtc/AndroidVideoDecoder.java
+++ b/sdk/android/src/java/org/webrtc/AndroidVideoDecoder.java
@@ -422,7 +422,6 @@
@Override
public void onFrame(VideoFrame frame) {
- final VideoFrame newFrame;
final Integer decodeTimeMs;
final long timestampNs;
synchronized (renderedTextureMetadataLock) {