direct3d

ID3DXAnimationController.RegisterAnimationSet - How exactly is this supposed to work?

I have a mesh file that contains the skinned mesh that I want, and then a bunch of separate animation files that contain various AnimationSets. I'd like to have my program dynamically build the list of AnimationSets available to a mesh at run-time. I know I can combine these into one mesh file using MView, but that isn't practical for wh...

What are possible causes of IDirect3DVertexBuffer9::Lock failing?

In error reports from some I have quite often seen following behaviour: IDirect3DVertexBuffer9::Lock fails, returned error code is D3DERR_NOTAVAILABLE. Once this happens, quite frequently (but not always) it is followed by CreateTexture or CreateVertexBuffer failing with error D3DERR_OUTOFVIDEOMEMORY. What are possible reasons for vert...

Rendering decals on 3d meshes

As in question, what are the best techniques for rendering lots (lots!) of decals on multiple meshes (which can move) and on terrain? ...

VMR9 Renderless mode device resetting problem

Hi all, I'm struggling with this problem for a week.. I hope I can state the problem clear enough: So, I setup my custom allocator/presenter and in InitializeDevice() I create the textures for VMR9 Then, VMR9 calls my PresentImage() function everytime it has a new frame. I display render this texture onto a quad and Present() it. If ...

DirectX capabilities on different graphics cards

I'm writing a Direct3D application, using DirectX 9. Although it works on my PC, I need to make it work on a wide range of systems. I need to know what capabilities I can expect to see on other systems. Is there a list of the DirectX capabilities that graphics cards support? I've found one site, which I'll post as an answer, but it's...

Dynamically generate Triangle Lists for a Complex 3D Mesh

In my application, I have the shape and dimensions of a complex 3D solid (say a Cylinder Block) taken from user input. I need to construct vertex and index buffers for it. Since the dimensions are taken from user input, I cannot user Blender or 3D Max to manually create my model. What is the textbook method to dynamically generate such ...

What is the Mclip matrix after the projection matrix and before the viewport scale matrix in D3D9?

I thought I understood perfectly how the vertices go through the 3d pipeline but in this article http://msdn.microsoft.com/en-us/library/ee418867%28VS.85%29.aspx a new matrix multiplication appears appears that makes the transition from projection space to clip space. I thought that projection space = clip space ( as in the case of Open...

When using Direct3D, how much math is being done on the CPU?

Context: I'm just starting out. I'm not even touching the Direct3D 11 API, and instead looking at understanding the pipeline, etc. From looking at documentation and information floating around the web, it seems like some calculations are being handled by the application. That, is, instead of simply presenting matrices to multiply to the...

Implement a 3D paint application: how to start?

Hello, I want to implement a paint-like application, which will enable kids to create and work with 3 dimensional objects. How can I start? What is the right approach? WPF, OpenGL, or Direct3D? (I prefer C# solutions, but C++ is OK also). Thank you all in advance! --NewB ...

Get image data for Direct3d rendering stream

I would like to get at the raw image data, as in a pointed to a byte array or something like that, of the image output from a direct3d app without actually rendering it to the monitor. I need to do this so that I can render direct3d as a directshow source filter Visual studio 2008 c++ ...

How to read direct3d texture pixels

So I have a x8r8g8b8 formatted IDirect3DSurface9 that contains the contents of the back buffer. When I call LockRect on it I get access to a struct containing pBits, a pointer to the pixels I assume, and and integer Pitch (which I am very unclear about its purpose). How to read the individual pixels? Visual Studio 2008 C++ ...

Can I tell direct3d to render with alpha channel?

I need to composite direct3d renders on top of a video feed, the way i have it setup the format i get the data in is 32 bit xrgb with a byte for red green blue and a throw away. Can I get it to render with an alpha channel so i can use it for better blending? ...

Using a 3D texture slice as a 2D texture input.

Hello, I am trying to do something with Ogre using 3D textures. I would like to update a 3D-texture by going through it slice-by-slice and recalculating the color values. However, in each step I also need to access the previous slice somehow to read the values. Setting up a slice as a render target is easy, but is it possible to feed su...

Clipplanes, vertex shaders and hardware vertex processing in Direct3D 9

Hi, I have an issue with clipplanes in my application that I can reproduce in a sample from DirectX SDK (February 2010). I added a clipplane to the HLSLwithoutEffects sample: ... D3DXPLANE g_Plane( 0.0f, 1.0f, 0.0f, 0.0f ); ... void SetupClipPlane(const D3DXMATRIXA16 & view, const D3DXMATRIXA16 & proj) { D3DXMATRIXA16 m = view...

Advanced Text Rendering with Direct3D

Hello guys, Let me shortly describe the "battlefield" of my task: Multi-room audio/video chat with more than 1M users; Custom Direct3D renderer; What I need to implement is TextOverVideo feature. The Text itself goes via network and is to be rendered on the recipient side with Direct3D renderer. AFAIK, it is commonly used in game de...

Is there any way to access the compiled shader code from a D3DXEffectCompiler

I'm currently writing a tool for pre-compiling our D3D9 shader code (will be using the ID3DXEffect in-game). I'm doing this through the ID3DXEffectCompiler interface and calling CompileEffect and I can do all of this without creating a IDirect3DDevice9 object (or even linking against d3d9.lib). The only problem is that I would like to a...

how do i extract vertex data from an fbx file

hi, im tryin to extract vertice and uv map informatie from a fbx file created with 3ds max 2010. All i could get from the file are good vertice and polygon index data but wrong uv maps. Can please someone help me pointing in a good direction or give me a tutorial. Thanks for ready this. ...

Error_1_The name 'MainForm_ResizeMove' does not exist in the current context

Hi, I tried to recreate the BitmapMixer sample from Directshow.NET in VS 2010 (The original sample works fine) and got the following errors in the Form1.cs Error 1 The name 'MainForm_ResizeMove' does not exist in the current context C:\Documents and Settings\TLNA\my documents\visual studio 2010\Projects\mybitmapMixer\myBitmapMixe...

Is there an equivalent of D3DXMatrixRotationYawPitchRoll() for iphone developers?

The D3DXMatrixRotationYawPitchRoll() function builds a matrix with a specified yaw, pitch, and roll. Is there an equivalent function for iphone developers?? I found a beautiful little sample project for drawing a winding road or rollercoaster here. It's not a lot of code, and the comments seem mostly understandable, but the code is re...

Shared Resources in SlimDX with DX10

I'm trying out the shared resources feature of DX10, as I needed this for one of my project. But I'm can't find much sample or code especially using SlimDX. According to DX10 documentation, I just need to specified the resources as Shared, then I can open it using OpenSharedResource() from another application. With a simple test applicat...