IPipeline.cs 3.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104
  1. using Ryujinx.Graphics.Shader;
  2. using System;
  3. namespace Ryujinx.Graphics.GAL
  4. {
  5. public interface IPipeline
  6. {
  7. void Barrier();
  8. void BeginTransformFeedback(PrimitiveTopology topology);
  9. void ClearBuffer(BufferHandle destination, int offset, int size, uint value);
  10. void ClearRenderTargetColor(int index, uint componentMask, ColorF color);
  11. void ClearRenderTargetDepthStencil(
  12. float depthValue,
  13. bool depthMask,
  14. int stencilValue,
  15. int stencilMask);
  16. void CommandBufferBarrier();
  17. void CopyBuffer(BufferHandle source, BufferHandle destination, int srcOffset, int dstOffset, int size);
  18. void DispatchCompute(int groupsX, int groupsY, int groupsZ);
  19. void Draw(int vertexCount, int instanceCount, int firstVertex, int firstInstance);
  20. void DrawIndexed(
  21. int indexCount,
  22. int instanceCount,
  23. int firstIndex,
  24. int firstVertex,
  25. int firstInstance);
  26. void EndTransformFeedback();
  27. void MultiDrawIndirectCount(BufferRange indirectBuffer, BufferRange parameterBuffer, int maxDrawCount, int stride);
  28. void MultiDrawIndexedIndirectCount(BufferRange indirectBuffer, BufferRange parameterBuffer, int maxDrawCount, int stride);
  29. void SetAlphaTest(bool enable, float reference, CompareOp op);
  30. void SetBlendState(int index, BlendDescriptor blend);
  31. void SetDepthBias(PolygonModeMask enables, float factor, float units, float clamp);
  32. void SetDepthClamp(bool clamp);
  33. void SetDepthMode(DepthMode mode);
  34. void SetDepthTest(DepthTestDescriptor depthTest);
  35. void SetFaceCulling(bool enable, Face face);
  36. void SetFrontFace(FrontFace frontFace);
  37. void SetIndexBuffer(BufferRange buffer, IndexType type);
  38. void SetImage(int binding, ITexture texture, Format imageFormat);
  39. void SetLogicOpState(bool enable, LogicalOp op);
  40. void SetLineParameters(float width, bool smooth);
  41. void SetPointParameters(float size, bool isProgramPointSize, bool enablePointSprite, Origin origin);
  42. void SetPrimitiveRestart(bool enable, int index);
  43. void SetPrimitiveTopology(PrimitiveTopology topology);
  44. void SetProgram(IProgram program);
  45. void SetRasterizerDiscard(bool discard);
  46. void SetRenderTargetScale(float scale);
  47. void SetRenderTargetColorMasks(ReadOnlySpan<uint> componentMask);
  48. void SetRenderTargets(ITexture[] colors, ITexture depthStencil);
  49. void SetSampler(int binding, ISampler sampler);
  50. void SetScissor(int index, bool enable, int x, int y, int width, int height);
  51. void SetStencilTest(StencilTestDescriptor stencilTest);
  52. void SetStorageBuffers(int first, ReadOnlySpan<BufferRange> buffers);
  53. void SetTexture(int binding, ITexture texture);
  54. void SetTransformFeedbackBuffers(ReadOnlySpan<BufferRange> buffers);
  55. void SetUniformBuffers(int first, ReadOnlySpan<BufferRange> buffers);
  56. void SetUserClipDistance(int index, bool enableClip);
  57. void SetVertexAttribs(ReadOnlySpan<VertexAttribDescriptor> vertexAttribs);
  58. void SetVertexBuffers(ReadOnlySpan<VertexBufferDescriptor> vertexBuffers);
  59. void SetViewports(int first, ReadOnlySpan<Viewport> viewports);
  60. void TextureBarrier();
  61. void TextureBarrierTiled();
  62. bool TryHostConditionalRendering(ICounterEvent value, ulong compare, bool isEqual);
  63. bool TryHostConditionalRendering(ICounterEvent value, ICounterEvent compare, bool isEqual);
  64. void EndHostConditionalRendering();
  65. void UpdateRenderScale(ShaderStage stage, ReadOnlySpan<float> scales, int textureCount, int imageCount);
  66. }
  67. }