Export (0) Print
Expand All

Loading an X File (Legacy) (Direct3D 9)

Use the following procedure in legacy applications to load a .x file.

  1. Use the DirectXFileCreate function to create an IDirectXFile object.
  2. If templates are present in the DirectX file that you will load, use the IDirectXFile::RegisterTemplates method to register those templates.
  3. Use the IDirectXFile::CreateEnumObject method to create an IDirectXFileEnumObject enumerator object.
  4. Loop through the objects in the file. For each object, perform the following steps.
    1. Use the IDirectXFileEnumObject::GetNextDataObject method to retrieve each IDirectXFileData object.
    2. Use the IDirectXFileData::GetType method to retrieve the data's type.
    3. Load the data using the IDirectXFileData::GetData method.
    4. If the object has optional members, retrieve the optional members by calling the IDirectXFileData::GetNextObject method.
    5. Release the IDirectXFileData object.
  5. Release the IDirectXFileEnumObject object.
  6. Release the IDirectXFile object.

 

 

Community Additions

ADD
Show:
© 2014 Microsoft