SHARE
TWEET

Structures.h

a guest May 1st, 2019 77 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. #pragma once
  2.  
  3. #include <D3DX10math.h>
  4. #include <string>
  5. #include <vector>
  6.  
  7. using namespace std;
  8.  
  9. struct VertexType {
  10.     D3DXVECTOR4 position;
  11.     D3DXVECTOR4 normal;
  12.     D3DXVECTOR2 texCoord;
  13. };
  14.  
  15. struct Mesh {
  16.     string material;
  17.     vector<VertexType> vertices;
  18. };
  19.  
  20. struct Material {
  21.     Material(string matName) {
  22.         name = matName;
  23.     };
  24.     string name;
  25.     string type;
  26.     D3DXVECTOR3 Ka;
  27.     D3DXVECTOR3 Kd;
  28.     D3DXVECTOR3 Ks;
  29.     D3DXVECTOR3 Ke;
  30.     float Ns;
  31.     float Tr;
  32.     float d;
  33.     string map_Ka;
  34.     string map_Kd;
  35.     string map_Ks;
  36.     string map_Ns;
  37.     string map_d;
  38.     string map_bump;
  39. };
  40.  
  41. struct cbShaderMaterial {
  42.     D3DXVECTOR3 Ka;
  43.     D3DXVECTOR3 Kd;
  44.     D3DXVECTOR3 Ks;
  45.     D3DXVECTOR3 Ke;
  46.     float Ns;
  47.     float Tr;
  48.     float d;
  49.     float bias; // для деления нацело на 16
  50. };
  51.  
  52. struct MatrixBufferType {
  53.     D3DXMATRIX world;
  54.     D3DXMATRIX view;
  55.     D3DXMATRIX projection;
  56. };
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top