IPipeline.cs 2.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273
  1. using Ryujinx.Graphics.GAL.Blend;
  2. using Ryujinx.Graphics.GAL.Color;
  3. using Ryujinx.Graphics.GAL.DepthStencil;
  4. using Ryujinx.Graphics.GAL.InputAssembler;
  5. using Ryujinx.Graphics.Shader;
  6. namespace Ryujinx.Graphics.GAL
  7. {
  8. public interface IPipeline
  9. {
  10. void BindBlendState(int index, BlendDescriptor blend);
  11. void BindIndexBuffer(BufferRange buffer, IndexType type);
  12. void BindImage(int index, ShaderStage stage, ITexture texture);
  13. void BindProgram(IProgram program);
  14. void BindSampler(int index, ShaderStage stage, ISampler sampler);
  15. void BindTexture(int index, ShaderStage stage, ITexture texture);
  16. void BindStorageBuffer(int index, ShaderStage stage, BufferRange buffer);
  17. void BindUniformBuffer(int index, ShaderStage stage, BufferRange buffer);
  18. void BindVertexAttribs(VertexAttribDescriptor[] vertexAttribs);
  19. void BindVertexBuffers(VertexBufferDescriptor[] vertexBuffers);
  20. void ClearRenderTargetColor(int index, uint componentMask, ColorF color);
  21. void ClearRenderTargetColor(int index, uint componentMask, ColorSI color);
  22. void ClearRenderTargetColor(int index, uint componentMask, ColorUI color);
  23. void ClearRenderTargetDepthStencil(
  24. float depthValue,
  25. bool depthMask,
  26. int stencilValue,
  27. int stencilMask);
  28. void Dispatch(int groupsX, int groupsY, int groupsZ);
  29. void Draw(int vertexCount, int instanceCount, int firstVertex, int firstInstance);
  30. void DrawIndexed(
  31. int indexCount,
  32. int instanceCount,
  33. int firstIndex,
  34. int firstVertex,
  35. int firstInstance);
  36. void SetBlendColor(ColorF color);
  37. void SetDepthBias(PolygonModeMask enables, float factor, float units, float clamp);
  38. void SetDepthTest(DepthTestDescriptor depthTest);
  39. void SetFaceCulling(bool enable, Face face);
  40. void SetFrontFace(FrontFace frontFace);
  41. void SetPrimitiveRestart(bool enable, int index);
  42. void SetPrimitiveTopology(PrimitiveTopology topology);
  43. void SetRenderTargetColorMasks(uint[] componentMask);
  44. void SetRenderTargets(ITexture[] colors, ITexture depthStencil);
  45. void SetStencilTest(StencilTestDescriptor stencilTest);
  46. void SetViewports(int first, Viewport[] viewports);
  47. void TextureBarrier();
  48. void TextureBarrierTiled();
  49. }
  50. }