Answer Questions
Sergio Ordine Memory Management - Minimize to Optimize?
Evening All.. Got a quick question about memory.. i have a program thats runs at around 35mb in memory, when i minimize the program, drops to 1 mb (natural due to unloading items not used) however when the program is maximized, the program levels at 20 mb in memory. i've checked the loadGraphicsContent() method to if it loads twice on construction, however it doesn't. Is this just C#/XNA cleaning itself up or is there another reason Thanks Oh my... I experienced this behaviour in all .net programms. Some time ago i found an link to a msdn page where it was described why. I will dig my link if i find it again... bump ... could it be start up code being deleted What are you measuring For an application to ...Show All
Bruce Baker Rendering to a Texture?
I tried to do a search but kept getting an error message. I was wondering if anyone had an example on how to render to a texture under XNA. Thx I'm not sure if I can be of any help but would it work if you try to set the Resource Pool to Managed or Default instead of SystemMemory I'm not sure if you did already but things to double-check before you post here about the exception that you've gotten. Create the texture with: ResourceUsage = ResourceUsage.RenderTarget SurfaceFormat = myGraphicsComponent.BackBufferFormat ResourcePool = ResourcePool.Default Get the top surface with texture.GetSurfaceLevel(0) Set that as the rendertarget with graphicsDevice.SetRenderTarget(0, surface); Render ...Show All
mattii Tell us about your website or game!
As part of our effort to reach out to the XNA community, we would like to create a special community page on the XNA Developer Center that links to YOUR site or game. Here's what you need to do, send me (David Weller) an email (click on my name link to the left of this post for the email address) telling me: 1) Your name 2) Your contact email 3) Your website or game 4) (Optionally) If you send me a link to your game, please let us know if you give Microsoft permission to use your game as part of any press-related activities we might do (i.e., incorporate a screenshot/video of your game, etc.). Please don't reply to this post with links to your site/game, I need the information emailed to me. Thanks! Well, since ...Show All
Guostong Rants on XNA 1.0
This is my first reaction when I installed and tried the 1.0 of XNA. To summarize my feeling: it's still 95% for XBox and no nearer to replace the old MDX 1.0. So I decided not to migrate from MDX to XNA though I want to do that very much. I feel like MDX 2 more; amen to MDX 2. The hardest issue for me is the content pipeline, which is very necessary, but the workflow is fixed and it assumes the contents are only built before the program runs. The helper functions wrapping D3DX can only be used with types in the content pipeline. I have to utilize the full content pipeline just for generating something dynamically, of course with significant performance cost. Or I have to write those D3DX utilities my self. Currently I don't have a good id ...Show All
Shan Ganesh Video/Animation Playback
Hi, I'm currently writing a library (for XNA/DirectX) for animation/soundless video playback, and I have a few design questions for the pros out there if you don't mind answering them : I'm having my animation class inherit from game component, and update the frame depending on game time in the overriden Update method, and render it in the overidden Draw method, but even when I preload my textures to render, playback is choppy. Not sure exactly why, but I notice this only when I have significant number of frames (I noticed it with 100 frames, but *not* with 10/15). This problem may be linked and solved by the 2nd point, so please read on. When I preload all the textures for the frames in the animation (and the no. of frames ...Show All
wutwjd X, Y positive/negative reversed?!?
Was just trying to do something simple with the 3D part of XNA, and noticed something strange...Lets say I make 3 vertices, all same color(Red), using VertexPositionColor, with cordinates: X Y Z -0.5f -0.5f -2f 0.5f -0.5f -2f 0.5f 0.5f -2f Then I go to draw this, (using the "simple.fx" shader found in the spacewar demo). Well, as you can imagine the triangle is supposed to look like so: o-------o | ' | '' o' (err, excuse my uber artistic skills hehe) well, thats not what im seeing. im seeing this(again.. uber skills... :D) .o .' | . | o-------o you get the idea. basically my X and Y positive and negative directions seem to be reversed. if its important, heres the code im using to render: public o ...Show All
Neotech Any effect tutorials
Can anyone recommend some good material on introduction to building effects and what you can do with them I'm currently using BasicEffect to manage a simple camera but I'd like to know what's going on and why I have to do it this way. I've been scouring google for days, and found a few promising beginner level ones. I've yet to really study them in earnest. If you search my blog you'll find several blog posts with the links. A s earch for "HLSL" should do it, or click the XNA category (I haven't categorised the HLSL specific ones properly yet). Here's the link: http://sharky.bluecog.co.nz I'm also just starting to learn effect and I'm looking for the same kind of info. The ...Show All
wolf777 Platform options only at project creation?
Hi, Like most I have talked with, I am doing most of my development / debugging on the PC and then deploying to the XBox360. One thing I have been unable to do is change the platform of a particular project. Instead, I have to have 2 projects and I literally just copy the files over or include from a common directory (where it seems to copy locally to that project directory for the c# using directives). In the project properties, the drop down box for platform only allows either x86 or xbox360 depending on what type of project you start, not both. Can I change the platform of a particular project from x86 to x360 The Windows Game Library can be added as a reference to an XBox 360 Game Project. From reading about the CLR, I assume this wi ...Show All
h goldstand Runtime model loading
I am trying to make a level editor with XNA. Unfortunately, I've run into a little snag. I need to load a model from a user chosen location, but as far as i know models need to be first loaded into the programming solution before they can be loaded through the content manager. Is there anyway to do this at runtime fora model thats not part of the solution I've looked at this problem too. I experimented and found that all you really need is to build the 3d model into the format recognized by the Content Pipeline. When you run your app, you get .xnb files that you then load using ContentManager.Load<Model>("mymodel"). Since you can type what you want into model name parameter, you can dynam ...Show All
Tbom7 2D sprite textures with c++
I first made a tileset of random size and store it in my texture interface, then displayed one of the sprites on it, but the sizes do not match. What I displayed on the screen seems like it was enlarged. I remember reading somewhere that all bitmaps we store in textures have to have sizes to the power of 2, so I changed the size of my bitmap tileset to 640x640. But still, the sprite is of different size on screen. Can anyone tell me why is that Yea, I was thinking more as a dividend of 2. I used D3DXCreateTextureFromFileEX(...). My graphics card's up to date I think, it's a GeForce 6800 Ultra. So it seems like the function call stretches my image to the next size of power 2. Everything's working an ...Show All
sandipan Future D3DX's not supporting SM1.x??
I saw this in the October SDK readme October 2006 DirectX readme! wrote: Preview Release of the new HLSL Shader Compiler for Direct3D 9 Targets This release has a beta version of d3dx9d_31_beta.dll that includes the Direct3D 10 HLSL compiler enabled for Direct3D 9 targets (shader models 2.0 and later). The new compiler has no support for 1_x targets. This debug-only DLL allows developers to utilize the new Direct3D 10 HLSL compiler for their Direct3D 9 shaders, and will become the default compiler for all Direct3D shaders. Please try the new compiler by building your application with d3dx9d_31_beta.dll instead of d3dx9d_31.dll. Does this mean in future SDKs SM 1.1 will not be supported any more, or is this limitation j ...Show All
Demix shader debuging not using pix.
Hi, I want to debug a shader in visual studio 2005. I understood that the shader debug featue is not working in 2005 and that I should use PIX instead. the problem is that I am using a A commercial game engine and the game crashes every time I try to run it with PIX. Is there any other way for me to debug my shaders Thanks. Hi jack, thanks for the quick reply. The problem is that I have a shader that I wrote with Render Monkey and it works just fine there. I tried to migrate it to work with the game engine I am working with and it seems like either the vertex data or the matrices ware not passed to the shader as I wanted. therefor printf won't do the job cause I am not the one sending this d ...Show All
qrli Skydomes
How would I render a sky dome with XNA I was looking for sky domes - a semi-sphere dome with a single texture wrapped around. You mean something like this http://www.riemers.net/eng/Tutorials/XNA/Csharp/Series2/Skybox.php I'm using a skydome in my 4th series. Here's the chapter: XNA Skydome tutorial Is there any reason to favor boxes over domes, for say a spaceflight sim I would think the tradeoff is that a box involves fewer polygons, but a dome looks better. Then this one... ;) http://forums.microsoft.com/MSDN/ShowPost.aspx PostID=974491&SiteID=1 They are both the same concept... keep locked to the ca ...Show All
SankaraNarayanan Nagalingam Problems with bounding boxes collision
This may sound really stupid, but I'm new to this stuff, so if anyone could help ... I can't get collisions on bounding boxes. I tried first with moving objects, after no sucess on that I even tried to create two boxes on top of each other and call the Intersects() method, it will still return false. This is how my code looks like: BoundingBox bbtest = new BoundingBox(new Vector3(0.0f, 1.0f,0.0f), new Vector3(1.0f, 0.0f, 0.0f)); BoundingBox bbtest2 = new BoundingBox(new Vector3(0.0f, 1.0f, 0.0f), new Vector3(1.0f, 0.0f, 0.0f)); bool test3 = bbtest.Intersects(bbtest2); I gotta be doing something wrong here, it can't return false. Those boxes are both empty (zero volume). An empty box cannot inter ...Show All
Arunkjose Where can I download DirectX9/10 SDK for VB ?
I found one , however it documentation was for C++. Is a documentation of DirectX9/10 for VB exist OK Thanks for that Hope my link was helpful to you. cheers Look at "DirectX Documentation for Managed Languages" It exactly when I searched , they give a SDK in VB which includes: half working samples in VB and documentation in C++ Why Microsoft can't publish somthing that just working :\\ My problem as a newbie starting out with directX is to Know what version to start with.Im confused about the new Directx10 which supports Vista as some forum stuff I've read suggests it does not support XP ...Show All
