XNA Creators Club Online
Page 1 of 1 (3 items)
Sort Posts: Previous Next

Models with Textures references

Last post 3/25/2009 2:58 PM by Kamilyon. 2 replies.
  • 3/24/2009 8:45 PM

    Models with Textures references

    Sorry if this has been asked/answered already, I did a quick search but didn't see what I was looking for.


    Is there a way to tell the Content Pipeline to ignore missing assets (textures etc...) when processing a model file?

    I have many models from  a previous project (non-xna) that were orginally saved with texture references.

    I no longer have many of these textures and will be assigning textures at run-time anyways.


    Cheers
    code with pride, not ego!
  • 3/24/2009 10:58 PM In reply to

    Re: Models with Textures references

    The default ModelProcessor will try to build any textures it finds, and produces a fatal error if they do not exist.

    You can change that behavior by making a custom processor, deriving from ModelProcessor and overriding the Process method. For instance you could strip out any missing textures (changing those polygons to be untextured) before you chain to the base ModelProcessor. Or you could override the ConvertMaterial method if you want to customize how materials get processed.
    XNA Framework Developer - blog - homepage
  • 3/25/2009 2:58 PM In reply to

    Re: Models with Textures references

    Thats what I figured.
    I was really hoping for a config option to "Ignore missing Assets" (hint hint... ;) )

    Thanks Shawn.


    Cheers
    code with pride, not ego!
Page 1 of 1 (3 items) Previous Next
var gDomain='m.webtrends.com'; var gDcsId='dcschd84w10000w4lw9hcqmsz_8n3x'; var gTrackEvents=1; var gFpc='WT_FPC'; /*<\/scr"+"ipt>");} /*]]>*/
DCSIMG