added DrawResolutionOffset to work with DrawResolution
This commit is contained in:
@@ -39,7 +39,9 @@ public class DetailDistanceUtil
|
||||
private static final double treeGenMultiplier = 1.0;
|
||||
private static final double treeCutMultiplier = 1.0;
|
||||
private static byte minGenDetail = CONFIG.client().graphics().quality().getDrawResolution().detailLevel;
|
||||
private static byte minDrawDetail = (byte) Math.max(CONFIG.client().graphics().quality().getDrawResolution().detailLevel, CONFIG.client().graphics().quality().getDrawResolution().detailLevel);
|
||||
private static byte minDrawDetail = (byte) Math.max(CONFIG.client().graphics().quality().getDrawResolution().detailLevel, CONFIG.client().graphics().quality().getDrawResolutionOffset());
|
||||
private static final int minGenDetailOffset = CONFIG.client().graphics().quality().getDrawResolutionOffset();
|
||||
private static final int minDrawDetailOffset = CONFIG.client().graphics().quality().getDrawResolutionOffset();
|
||||
private static final int maxDetail = LodUtil.REGION_DETAIL_LEVEL + 1;
|
||||
private static final int minDistance = 0;
|
||||
private static int minDetailDistance = (int) (MC_RENDER.getRenderDistance()*16 * 1.42f);
|
||||
@@ -141,6 +143,10 @@ public class DetailDistanceUtil
|
||||
|
||||
public static byte getLodDrawDetail(int detail)
|
||||
{
|
||||
detail += minDrawDetailOffset;
|
||||
if (detail > 10)
|
||||
detail = 10;
|
||||
|
||||
if (detail < minDrawDetail)
|
||||
return minDrawDetail;
|
||||
else
|
||||
|
||||
+10
@@ -76,6 +76,7 @@ public interface ILodConfigWrapperSingleton
|
||||
HorizontalResolution DRAW_RESOLUTION_DEFAULT = HorizontalResolution.BLOCK;
|
||||
String DRAW_RESOLUTION_DESC = ""
|
||||
+ " What is the maximum detail fake chunks should be drawn at? \n"
|
||||
+ " This setting will only affect closer chunks.\n"
|
||||
+ " Higher settings will increase memory and GPU usage. \n"
|
||||
+ "\n"
|
||||
+ " " + HorizontalResolution.CHUNK + ": render 1 LOD for each Chunk. \n"
|
||||
@@ -89,6 +90,15 @@ public interface ILodConfigWrapperSingleton
|
||||
HorizontalResolution getDrawResolution();
|
||||
void setDrawResolution(HorizontalResolution newHorizontalResolution);
|
||||
|
||||
MinDefaultMax<Integer> DRAW_RESOLUTION_OFFSET_MIN_DEFAULT_MAX = new MinDefaultMax<Integer>(0, 0, 4);
|
||||
String DRAW_RESOLUTION_OFFSET_DESC = ""
|
||||
+ " By how many levels should we lower resolution across the board?\n"
|
||||
+ " Very similar to 'Block size',\n"
|
||||
+ " but this setting will affect ALL chunks.\n"
|
||||
+ " Lower settings will increase memory and GPU usage. \n";
|
||||
Integer getDrawResolutionOffset();
|
||||
void setDrawResolutionOffset(int newDrawResolutionOffset);
|
||||
|
||||
MinDefaultMax<Integer> LOD_CHUNK_RENDER_DISTANCE_MIN_DEFAULT_MAX = new MinDefaultMax<Integer>(16, 64, 1024);
|
||||
String LOD_CHUNK_RENDER_DISTANCE_DESC = ""
|
||||
+ " The radius of the mod's render distance. (measured in chunks) \n";
|
||||
|
||||
Reference in New Issue
Block a user