directx 11 - Get ID3DXMesh from CDXUTSDKMesh -


In a DirectX 11 demo application, I use CDXUTSDKMesh for my static geometry Is loaded and has already been displayed.

I am using something related to precompressed radians transfer in this application. ID3DXPRTEngine Will be a very handy tool for the job Unfortunately, the D3X and DXUT seem to be very consistent.

ID3DXPRTEngine requires a single ID3DXMesh (multiple mash D3DXConcatenateMeshes no problem). What is an easy way to 'convert' for one or more ID3DXMesh examples? This can be done, but it is necessary that you can read raw top data, convert it to Direct3D 9.

Basically what you are trying to do is inter-operate with two different versions of the Direct3D API: version 9.0 and version 11.0 To do this, you need to do the following:

  1. Your honor Confirm the variants which do not have any custom semantics (i.e., D3d 11 allows a code like RANDOM_EYE_VEC )

  2. Confirm that you have the ability to read your top and face information in a byte buffer (i.e. one four indicator).

  3. A Direct 3D 9 Device and Direct 3D 11 devices.

  4. Open your trap, drag data into a byte buffer and create a ID3DXMesh with that data Object If you have more than 2 faces 16, you will need to split the trap into two or more meshes.

  5. Build PRT engines from Aries (SES), and run your PRT calculation.

  6. ID3DXBaseMesh :: GetVertexBuffer () using the new information from the trap (SAS) (This step is not completely the correct form I have never actually used the PRT engine.)

  7. Write the new data back in CDXUTSDKMesh .

    As you can tell, this process is long, there is a possibility of error, and it is very slow if you are doing it for offline device, then it is fine Maybe, but if it is used in real time, then you might have been better at writing your own PRT engine.

    In addition, if your mesh has a custom semantique (i.e. you use a shader which expects some data that was not part of the D3D 9 world) then this algorithm fails Will be done. The PRT engine uses a fixed function pipeline, so any new messages that take advantage of the D311 features which were not present back, they are not working here.

Comments

Popular posts from this blog

java - ImportError: No module named py4j.java_gateway -

python - Receiving "KeyError" after decoding json result from url -

.net - Creating a new Queue Manager and Queue in Websphere MQ (using C#) -