0
我試圖找出,如何工作this code。我的代碼中使用了什麼樣的規範化?
public class UnPoint
{
public int X, Y;
public float x, y;
public float v;
public static float X_MIN = -1f;
public static float X_MAX = 1f;
public static float Y_MIN = 0f;
public static float Y_MAX = 1f;
public UnPoint(int XX, int YY, int w, int h)
{
X = XX;
Y = YY;
x = (X_MAX-X_MIN)/((float)(w-1)) * ((float)X) + X_MIN;
y = (Y_MAX-Y_MIN)/((float)(h-1))*((float)((h-1) - Y)) + Y_MIN;
}
}
什麼是X,Y?我認爲,這是一種正常化。但我沒有找到這種類型。
我很樂意提供任何建議。
謝謝你的回答。 – Jordan