@Environment(value=CLIENT) public class GameRenderer extends Object implements SynchronousResourceReloadListener, AutoCloseable
ResourceReloadListener.Synchronizer
Constructor and Description |
---|
GameRenderer(MinecraftClient client,
ResourceManager resourceManager,
BufferBuilderStorage bufferBuilderStorage) |
Modifier and Type | Method and Description |
---|---|
void |
apply(ResourceManager manager) |
private void |
bobView(MatrixStack matrixStack,
float float2) |
private void |
bobViewWhenHurt(MatrixStack matrixStack,
float float2) |
void |
close() |
void |
disableShader() |
Matrix4f |
getBasicProjectionMatrix(Camera camera,
float float2,
boolean bool) |
Camera |
getCamera() |
private double |
getFov(Camera camera,
float tickDelta,
boolean changingFov) |
LightmapTextureManager |
getLightmapTextureManager() |
MapRenderer |
getMapRenderer() |
static float |
getNightVisionStrength(LivingEntity livingEntity,
float float2) |
OverlayTexture |
getOverlayTexture() |
ShaderEffect |
getShader() |
float |
getSkyDarkness(float tickDelta) |
float |
getViewDistance() |
void |
loadProjectionMatrix(Matrix4f matrix4f) |
private void |
loadShader(Identifier identifier) |
private void |
method_31136(float float2) |
void |
onCameraEntitySet(Entity entity) |
void |
onResized(int int2,
int int3) |
void |
render(float tickDelta,
long startTime,
boolean tick) |
private void |
renderFloatingItem(int scaledWidth,
int scaledHeight,
float tickDelta) |
private void |
renderHand(MatrixStack matrices,
Camera camera,
float tickDelta) |
void |
renderWorld(float tickDelta,
long limitTime,
MatrixStack matrix) |
void |
reset() |
private boolean |
shouldRenderBlockOutline() |
void |
showFloatingItem(ItemStack floatingItem) |
void |
tick() |
void |
toggleShadersEnabled() |
private void |
updateMovementFovMultiplier() |
void |
updateTargetedEntity(float tickDelta) |
private void |
updateWorldIcon() |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
reload
getName
private static final Identifier field_26730
private static final Logger LOGGER
private static final Identifier[] SHADERS_LOCATIONS
public static final int SHADER_COUNT
private final MinecraftClient client
private final ResourceManager resourceContainer
private final Random random
private float viewDistance
public final HeldItemRenderer firstPersonRenderer
private final MapRenderer mapRenderer
private final BufferBuilderStorage buffers
private int ticks
private float movementFovMultiplier
private float lastMovementFovMultiplier
private float skyDarkness
private float lastSkyDarkness
private boolean renderHand
private boolean blockOutlineEnabled
private long lastWorldIconUpdate
private long lastWindowFocusedTime
private final LightmapTextureManager lightmapTextureManager
private final OverlayTexture overlayTexture
private boolean renderingPanorama
private float zoom
private float zoomX
private float zoomY
private int floatingItemTimeLeft
private float floatingItemWidth
private float floatingItemHeight
@Nullable private ShaderEffect shader
private int forcedShaderIndex
private boolean shadersEnabled
private final Camera camera
public GameRenderer(MinecraftClient client, ResourceManager resourceManager, BufferBuilderStorage bufferBuilderStorage)
public void close()
close
in interface AutoCloseable
public void disableShader()
public void toggleShadersEnabled()
private void loadShader(Identifier identifier)
public void apply(ResourceManager manager)
apply
in interface SynchronousResourceReloadListener
public void tick()
@Nullable public ShaderEffect getShader()
public void onResized(int int2, int int3)
public void updateTargetedEntity(float tickDelta)
private void updateMovementFovMultiplier()
private double getFov(Camera camera, float tickDelta, boolean changingFov)
private void bobViewWhenHurt(MatrixStack matrixStack, float float2)
private void bobView(MatrixStack matrixStack, float float2)
private void renderHand(MatrixStack matrices, Camera camera, float tickDelta)
public void loadProjectionMatrix(Matrix4f matrix4f)
public Matrix4f getBasicProjectionMatrix(Camera camera, float float2, boolean bool)
public static float getNightVisionStrength(LivingEntity livingEntity, float float2)
public void render(float tickDelta, long startTime, boolean tick)
private void updateWorldIcon()
private boolean shouldRenderBlockOutline()
public void renderWorld(float tickDelta, long limitTime, MatrixStack matrix)
public void reset()
public MapRenderer getMapRenderer()
public void showFloatingItem(ItemStack floatingItem)
private void renderFloatingItem(int scaledWidth, int scaledHeight, float tickDelta)
private void method_31136(float float2)
public float getSkyDarkness(float tickDelta)
public float getViewDistance()
public Camera getCamera()
public LightmapTextureManager getLightmapTextureManager()
public OverlayTexture getOverlayTexture()