- Home /
Custom texture importer for custom folder
I have been trying to create a custom texture importer for a specified folder, where every texture inside it will have certain settings applied. However, im not sure how to do so. I have been looking at TextureImporter and AssetPostprocessor, but i cannot get them to reference each other. Also had no luck making AssetDatabase do what i want. I wonder if anyone have a method for doing this?
Answer by pweeks · Feb 05, 2016 at 04:58 PM
public class TexturePostProcessor : AssetPostprocessor
{
void OnPreprocessTexture()
{
if (assetPath.Contains("folder_name_you_care_about"))
{
// do custom
}
}
}
Your answer
Follow this Question
Related Questions
Custom Fonts... Missing on friend's computer 1 Answer
Long texture reimport during platform switching(standalone <-> ios) 1 Answer
Difference between Resources folder Vs normal folder 0 Answers
Is it possible to automatically match materials to textures with the same name? 1 Answer
For some reason, image is not the same resolution as the imported image! 1 Answer