Dynamically load PNG using script

Hi,

When my scene starts to load, I want to load a PNG file into the background for the game.

I am using a 3D project as my objects rotate etc, but the background will always be 2D

  1. What object should I use for the PNG? A quad?

  2. How can this be done dynamically in C#? I tried using a quad, but I dont see any objects I use can use to change the background on this object.

bump

Yes, you’ll want to use a quad. Create and assign a material to the quad. Assigning a texture to that is just GetComponent().material.mainTexture = someTexture;

Loading the PNG can be done through the WWW class; there’s some sample code here that should help with that.