Jump to content

  • Log In with Google      Sign In   
  • Create Account

FREE SOFTWARE GIVEAWAY

We have 4 x Pro Licences (valued at $59 each) for 2d modular animation software Spriter to give away in this Thursday's GDNet Direct email newsletter.


Read more in this forum topic or make sure you're signed up (from the right-hand sidebar on the homepage) and read Thursday's newsletter to get in the running!


Curin

Member Since 26 Feb 2013
Offline Last Active Dec 11 2014 02:00 PM

Topics I've Started

WPF, Directx 11 Effect passes

08 December 2014 - 04:26 PM

     I have converted the sample from Directx10 SlimDX to work with Directx11. The initial testing was promising witht the fact that I can assign the base color, but when I try to run an effect the program doesn't actually draw the vertices.

 

The render code is as follows

public void Render(int arg)
        {
            D3DDevice.ImmediateContext.OutputMerger.SetTargets(SampleDepthView, SampleRenderView);
            D3DDevice.ImmediateContext.Rasterizer.SetViewports(new Viewport(0, 0, WindowWidth, WindowHeight, 0.0f, 1.0f));

            D3DDevice.ImmediateContext.ClearDepthStencilView(SampleDepthView, DepthStencilClearFlags.Depth | DepthStencilClearFlags.Stencil, 1.0f, 0);
            float c = ((float)(arg % 1000)) / 999.0f;
            D3DDevice.ImmediateContext.ClearRenderTargetView(SampleRenderView, new SlimDX.Color4(1.0f, c, c, c));

            D3DDevice.ImmediateContext.InputAssembler.InputLayout = SampleLayout;
            D3DDevice.ImmediateContext.InputAssembler.PrimitiveTopology = PrimitiveTopology.TriangleList;
            D3DDevice.ImmediateContext.InputAssembler.SetVertexBuffers(0, new VertexBufferBinding(SampleVertices, 32, 0));

            EffectTechnique technique = SampleEffect.GetTechniqueByIndex(0);
            EffectPass pass = technique.GetPassByIndex(0);

            for (int i = 0; i < technique.Description.PassCount; ++i)
            {
                pass.Apply(D3DDevice.ImmediateContext);
                D3DDevice.ImmediateContext.Draw(3, 0);
            }

            D3DDevice.ImmediateContext.Flush();
        }

If anyone can help me find out what is wrong. I know that the shader I'm using works as I have used it in place of the minitri11 sample's shader and it worked fine.

 

 

Thanks in advance,

Curin


Fullscreen Alt-Tab out Problem

19 April 2013 - 05:16 PM

So I've used Slimdx Directx 11 and am getting used to it, but a problem aroused from going fullscreen. When I tab out to look at my code it goes back to a windowed mode which is clear(Which as far as I've heard is normal), but then I have no way to regain control of the form. Does anyone know how to deal with this?


Multiple Monitor Fullscreen windows

03 March 2013 - 04:41 PM

In Slimdx, I'm trying to find out how to make a window go fullscreen to a specific monitor with no luck so far. Any help would be appreciated.

 

Thanks in advance =)


Xna commands for slimdx

26 February 2013 - 06:51 PM

     I've heard there was a library that mimicked the xna classes in slimdx. I want to know if anyone knows where I can find this library or something similar. Any help would be appreciated.

 

Thank you in advance,

Curin


PARTNERS