Forum
Contact





DirectX using C#
DirectX using C++
DirectX using Visual Basic



Latest Forum posts

 Tutorial 3 for Windows Phone 7
  Posted by: Anonymous
  When: 19/05/2013 at 11:27:50

 No download link for 2d series: shooter
  Posted by: zaboleq
  When: 07/05/2013 at 15:46:28

 Collision Class?
  Posted by: Anonymous
  When: 05/05/2013 at 19:03:59

 stack overflow
  Posted by: cityguy
  When: 07/04/2013 at 01:58:38

 Meshes looks strange.
  Posted by: ab_saratov
  When: 01/04/2013 at 04:31:08

 Lamppost Not loaded
  Posted by: Anonymous
  When: 22/03/2013 at 06:43:52

 Collision Class?
  Posted by: Da_Boom
  When: 21/03/2013 at 01:23:09

 Math boggles me
  Posted by: cityguy
  When: 17/03/2013 at 03:44:48

 Collision Class?
  Posted by: Da_Boom
  When: 16/03/2013 at 03:44:42

 Tree update
  Posted by: Anonymous
  When: 15/03/2013 at 21:11:22

 XNA 4.0
  Posted by: Anonymous
  When: 15/03/2013 at 19:43:57

 Error when I try to run.
  Posted by: Anonymous
  When: 15/03/2013 at 19:21:06

 Error With the Effect File
  Posted by: Anonymous
  When: 15/03/2013 at 18:21:01

 Can only get shadowmap
  Posted by: Anonymous
  When: 15/03/2013 at 15:48:52

 Vertex and Pixel Shader Versions?
  Posted by: Anonymous
  When: 15/03/2013 at 15:07:16

 Unsupported properties
  Posted by: Anonymous
  When: 15/03/2013 at 14:23:00

 Problem Loading Skybox
  Posted by: Rana
  When: 15/03/2013 at 10:34:45

 Black Screen Of Death - Help!
  Posted by: Anonymous
  When: 15/03/2013 at 03:43:43

 2.0 anyone?
  Posted by: Anonymous
  When: 15/03/2013 at 02:19:48

 Defitinition of tha rotation axis
  Posted by: Anonymous
  When: 15/03/2013 at 00:55:14




Topic: Loading a model



  
Goto parent category
  
Create a new user account


   Loading a model
 Poster : Mako
 Posts: 3
 Country : USA
 City: Austin

  
Posted by Mako on 04/02/2008 at 21:55:22
I've seen several topics on this but no clear answer.  I have the terrain working perfectly fine and now I would like to load a model.  How do I go about doing this?  

Do I need to add something in the series4effects.fx file?  Because when I add the model in the content pipeline and try to load and draw it like I usually do, I cannot for the life of me see it, no matter how I fiddle around with the camera.  

Once I can see it, I won't have a problem scaling it and adding heightmap collision detection or anything, I just can't see it, so I don't know if it is even loading correctly.

If someone could post just the few lines of code needed to load a simple model I would really appreciate it.  Thanks.
 Poster : Mako
 Posts: 3
 Country : USA
 City: Austin

  
Posted by Mako on 04/02/2008 at 22:50:55
I'll try and be more specific.  Do I just use the "colored" technique like in the series 2 example where he loads the model of the plane?  And if so, how do I add all the other parameters it needs, because it won't accept just xWorld.

What coordinates can the camera see in it's default starting location, that way I know I'm not trying to load it outside of the camera's visibility range.  Or how can I figure out what the camera can see?

I don't need answers to all of those, but anything will help.
 Poster : Anonymous
 Posts:
 Country :
 City:

  
Posted by Anonymous on 05/02/2008 at 07:05:22
Hy hm i think you are doing this with XNA.
In MDX you have to load the model from an .X file then you fave to use drawsubsets to actualy draw it.

I used Mesh.FromFile and Mesh.LoadHierarchyFromFile. I think there has to be something similar to this: Model
which has some functions that can use the loaded file from the ContentManager.

Good Luck
 Poster : Anonymous
 Posts:
 Country :
 City:

  
Posted by Anonymous on 05/02/2008 at 17:58:35
I saw someone had posted saying they had a dwarf running around on this landscape.  If that person is still browsing these forums, I'd love to see how they added a model and the heightmap collision.  It's a bit tough with the Z up thing.
 Poster : Anonymous
 Posts:
 Country :
 City:

  
Posted by Anonymous on 20/06/2012 at 11:58:43
I read your post and wished I'd wriettn it

  
Post a new reply
 





Google
 
Web www.riemers.net
If you appreciate the amount of time I spend creating and updating
these pages, feel free to donate -- any amount is welcome !
- Website design & DirectX code : Riemer Grootjans -
©2006 Riemer Grootjans


News
Home
Forum
XNA 2.0 Recipes Book (8)
XNA 3.0 Recipes Book (8)
Downloads
Extra Reading (3)
Matrices: geometrical
Matrix Mathematics
Homogenous matrices
Community Projects (1)
Tutorials (160)
XNA 4.0 using C# (89)
DirectX using C# (54)
Series 1:Terrain (14)
Opening a window
Linking to the Device
Drawing a triangle
Camera
Rotation - Translation
Indices
Terrain creation
Terrain from file
DirectInput
Importing bmp files
Colored vertices
DirectX Light basics
Mesh creation
Mesh lighting
Series 2: Flightsim (19)
Series 3: HLSL (19)
Short Tuts (2)
Resizing problem
Checking Device caps
DirectX using C++ (15)
DirectX using VB (2)