diff Engine/Graphics/RenderD3D11.h @ 2524:c7264ab7132f

Main menu rendered using d3d11
author a.parshin
date Fri, 10 Oct 2014 17:42:05 +0300
parents c532d5242055
children 4cc81f981afb
line wrap: on
line diff
--- a/Engine/Graphics/RenderD3D11.h	Thu Oct 09 23:33:36 2014 +0300
+++ b/Engine/Graphics/RenderD3D11.h	Fri Oct 10 17:42:05 2014 +0300
@@ -74,8 +74,8 @@
   virtual void EndScene();
   virtual void ScreenFade(unsigned int color, float t);
 
-  virtual void SetTextureClipRect(unsigned int uX, unsigned int uY, unsigned int uZ, unsigned int uW);
-  virtual void ResetTextureClipRect();
+  virtual void SetUIClipRect(unsigned int uX, unsigned int uY, unsigned int uZ, unsigned int uW);
+  virtual void ResetUIClipRect();
   virtual void CreditsTextureScroll(unsigned int pX, unsigned int pY, int move_X, int move_Y, RGBTexture *pTexture);
   
   virtual void DrawTextureNew(float u, float v, struct Texture *);
@@ -85,7 +85,7 @@
 
   virtual void ZBuffer_Fill_2(signed int a2, signed int a3, struct Texture *pTexture, int a5);
   virtual void DrawMaskToZBuffer(signed int uOutX, unsigned int uOutY, struct Texture *pTexture, int zVal);
-  virtual void DrawTextureTransparent(unsigned int uX, unsigned int uY, struct Texture *pTexture);
+  virtual void DrawTextureIndexedAlpha(unsigned int uX, unsigned int uY, struct Texture *pTexture);
   virtual void DrawAura(unsigned int a2, unsigned int a3, struct Texture *a4, struct Texture *a5, int a6, int a7, int a8);
   virtual void _4A65CC(unsigned int x, unsigned int y, struct Texture *a4, struct Texture *a5, int a6, int a7, int a8);
 
@@ -165,6 +165,11 @@
 
 
   protected:
+    void DrawTexture(float u, float v, int texture_width, int texture_height, ID3D11ShaderResourceView *srv, ID3D11BlendState *blend);
+    void PrepareTexture(struct RGBTexture *p);
+    void PrepareTextureIndexed(struct Texture *p);
+    ID3D11ShaderResourceView *PrepareFontTexture(unsigned char *pFontPixels, unsigned int uCharWidth, unsigned int uCharHeight, unsigned short *pFontPalette, unsigned short uFaceColor, unsigned short uShadowColor);
+
     OSWindow *window;
 
     IDXGISwapChain          *pSwapChain;
@@ -182,5 +187,12 @@
     ID3D11InputLayout       *ui_layout;
     ID3D11Buffer            *ui_vb;
     ID3D11DepthStencilState *ui_depthstencil;
-    ID3D11BlendState        *ui_blend;
+    ID3D11BlendState        *ui_blend_solid;
+    ID3D11BlendState        *ui_blend_alpha;
+    ID3D11RasterizerState   *ui_rasterizer;
+    D3D11_RECT               ui_clip_rect;
+
+    
+    RenderHWLContainer pD3DBitmaps;
+    RenderHWLContainer pD3DSprites;
 };