x


How to create mipmap for textures loaded with www?

When I load a texture using the code below:

WWW www = new WWW(textureName);     

yield return www;

renderer.material = new Material(Shader.Find("Diffuse"));

Texture tex = www.texture;
tex.filterMode = FilterMode.Trilinear;

renderer.material.mainTexture =tex;

The texture does not come with mipmaps, how can I tell unity to generate the mipmaps?

more ▼

asked May 04 '11 at 12:28 AM

bcsanches gravatar image

bcsanches
1 3 3 5

(comments are locked)
10|3000 characters needed characters left

1 answer: sort voted first
more ▼

answered May 04 '11 at 05:43 AM

DaveA gravatar image

DaveA
26.4k 151 171 256

(comments are locked)
10|3000 characters needed characters left
Your answer
toggle preview:

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Topics:

x3721
x2188
x524
x22

asked: May 04 '11 at 12:28 AM

Seen: 1597 times

Last Updated: May 04 '11 at 12:28 AM