render to menual allocated buffer ??

It may be my crazy thought, but am I able to let DirectX render images to the system buffer i created


Answer this question

render to menual allocated buffer ??

  • EGH25091970

    I know it could be difficult, but I am requested to Render a 3D scene with alpha to a video output, that request data transfer from the RenderTarget Surface to the DirectDraw Suface with Overlay. the problem is.

    Direct3D Surfaces and DirectDraw Surfaces are not mixable. I know that. so I have try to lock both of the surface and do a memcpy.

    every one knows this is a large cost to the CPU time.

    so if I can direct Direct3D to render to a shared buffer binded to a DirectDraw Surface, It will save a lot of time.

    so if Anybody knows how, I'am on my knees...



  • Ragna

    I do not know if you can, but I can tell you why it could be bad.

    Getting data from the card to the system memory is slow (i learned) and on most scenes you will have a fair amount of overdraw, unless you manually sort the objects and only render faces which are the closest in a particular direction.

    If you for example have on average four overdraws for every pixel in the display, then you will transfer four times the visible data to system memory.

    If you let the card render locally and do its overdrawing there, then you can avoid the extra transfer.

    Besides.. if the card needs to do blending and/or depth testing, then it will even need to read back that data from system memory, do its calculations and write new data back.


  • CharlesCook

    This is not possible at all.

    If you want render to a surface you have to create it as render target or create a texture with the render target usage flag.

    Render targets can only be in the default memory pool.



  • render to menual allocated buffer ??