Hi there,
I just shut down unity, cause I used more than available memory… So what happened
private void createLabels ()
{
float y ;
tm = gameObject.AddComponent<TextMesh> ();
tm.font = font;
tm.fontSize = 100;
tm.renderer.material = font.material;
tm.characterSize = 1;
for (int i = 0; i<resolution; i++)
{ //resolution = count of values in listFloat
tm = Instantiate(tm) as TextMesh;
listText.Add (tm);
}
float low = nejmensiZListFloat (listFloat); //return the lowest from listFloat
for (int i = 0; i< resolution; i+=100)
{
y = (listFloat [i] - low) / 100;
listText [i].text = listFloat [i].ToString ();
listText [i].transform.localPosition = new Vector3 (5f * i, y * 0.5f, 0f);
Debug.Log (tm.text);
}
}
I’d like to do labels for axes. But this solutions shut down Unity, cause this copied Main Camera, not the MeshText. I tried do a few copies and it worked, but i need all labels to do them adaptable due the data, which are the labeling.
Thx a lot!