- Home /
Question by
DiebeImDunkeln · Feb 02, 2015 at 01:05 PM ·
texture2dblur
How to use AssetPreview.GetAssetPreview without blur?
hi,
for my tileset editor I use AssetPreview.GetAssetPreview to make thumbnails which I put on my buttons. But the images are all blured. How can I avoid this blur?
This is my script to generate and save the textures:
Texture2D bTexture = null;
while(bTexture==null)
{
bTexture = AssetPreview.GetAssetPreview(go);
Thread.Sleep(50);
}
if(bTexture != null)
{
byte[] data = bTexture.EncodeToPNG();
string pathAndName = AssetDatabase.GenerateUniqueAssetPath(path+go.name+".png");
File.WriteAllBytes(pathAndName, data);
}
thanks in advance Frank
Comment
Answer by _ME4T · Feb 16, 2015 at 09:17 PM
I was just having this problem, and I'm sad to say it's because I had somehow set my texture resolution to 1/8th res for the whole project. Setting it back to full-res fixed it.
Go to Edit > Project Settings > Quality, under the Rendering heading, change Texture Quality.
Might not be your problem, but worth a shot.
Thanks for your answer, but that was not the problem. $$anonymous$$y texture quality is set to full res.:-)