Format with google-java-format
This commit is contained in:
parent
c0c1c315c5
commit
c4d9df970c
@ -34,7 +34,6 @@ import android.opengl.GLES20;
|
||||
import android.opengl.GLES30;
|
||||
import android.opengl.GLUtils;
|
||||
import android.opengl.Matrix;
|
||||
import androidx.annotation.DoNotInline;
|
||||
import androidx.annotation.IntRange;
|
||||
import androidx.annotation.Nullable;
|
||||
import androidx.media3.common.C;
|
||||
@ -413,7 +412,8 @@ public final class GlUtil {
|
||||
currentEglContextVersion,
|
||||
/* offset= */ 0);
|
||||
checkGlError();
|
||||
return currentEglContextVersion[0]; }
|
||||
return currentEglContextVersion[0];
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns a newly created sync object and inserts it into the GL command stream.
|
||||
@ -445,7 +445,8 @@ public final class GlUtil {
|
||||
*/
|
||||
public static void deleteSyncObject(long syncObject) throws GlException {
|
||||
deleteSyncObjectQuietly(syncObject);
|
||||
checkGlError(); }
|
||||
checkGlError();
|
||||
}
|
||||
|
||||
/** Releases the GL sync object if set, suppressing any error. */
|
||||
public static void deleteSyncObjectQuietly(long syncObject) {
|
||||
@ -546,8 +547,7 @@ public final class GlUtil {
|
||||
public static void focusEglSurface(
|
||||
EGLDisplay eglDisplay, EGLContext eglContext, EGLSurface eglSurface, int width, int height)
|
||||
throws GlException {
|
||||
focusRenderTarget(
|
||||
eglDisplay, eglContext, eglSurface, /* framebuffer= */ 0, width, height);
|
||||
focusRenderTarget(eglDisplay, eglContext, eglSurface, /* framebuffer= */ 0, width, height);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -26,7 +26,6 @@ import android.view.Choreographer;
|
||||
import android.view.Choreographer.FrameCallback;
|
||||
import android.view.Display;
|
||||
import android.view.Surface;
|
||||
import android.view.WindowManager;
|
||||
import androidx.annotation.DoNotInline;
|
||||
import androidx.annotation.Nullable;
|
||||
import androidx.annotation.RequiresApi;
|
||||
@ -419,7 +418,9 @@ public final class VideoFrameReleaseHelper {
|
||||
|
||||
@Nullable
|
||||
private DisplayHelper maybeBuildDisplayHelper(@Nullable Context context) {
|
||||
if (context == null) { return null;}
|
||||
if (context == null) {
|
||||
return null;
|
||||
}
|
||||
DisplayManager displayManager =
|
||||
(DisplayManager) context.getSystemService(Context.DISPLAY_SERVICE);
|
||||
return displayManager != null ? new DisplayHelper(displayManager) : null;
|
||||
@ -443,8 +444,7 @@ public final class VideoFrameReleaseHelper {
|
||||
}
|
||||
}
|
||||
|
||||
private final class DisplayHelper
|
||||
implements DisplayManager.DisplayListener {
|
||||
private final class DisplayHelper implements DisplayManager.DisplayListener {
|
||||
|
||||
private final DisplayManager displayManager;
|
||||
|
||||
|
@ -106,7 +106,8 @@ public final class SphericalGLSurfaceView extends GLSurfaceView {
|
||||
// fusion. It's used instead of TYPE_ROTATION_VECTOR since the latter uses the magnetometer on
|
||||
// devices. When used indoors, the magnetometer can take some time to settle depending on the
|
||||
// device and amount of metal in the environment.
|
||||
@Nullable Sensor orientationSensor = sensorManager.getDefaultSensor(Sensor.TYPE_GAME_ROTATION_VECTOR);
|
||||
@Nullable
|
||||
Sensor orientationSensor = sensorManager.getDefaultSensor(Sensor.TYPE_GAME_ROTATION_VECTOR);
|
||||
if (orientationSensor == null) {
|
||||
orientationSensor = sensorManager.getDefaultSensor(Sensor.TYPE_ROTATION_VECTOR);
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user