/[gr2lib]/trunk/gr2lib/CoreTypes.cs
ViewVC logotype

Diff of /trunk/gr2lib/CoreTypes.cs

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 8 by william, Wed Jul 14 06:19:08 2010 UTC revision 13 by william, Wed Jul 14 09:21:14 2010 UTC
# Line 2  Line 2 
2  using System.Collections.Generic;  using System.Collections.Generic;
3  using System.Text;  using System.Text;
4    
5    using gr2lib.core.typedefs;
6    
7  namespace gr2lib  namespace gr2lib.core.coretypes
8  {  {
9      namespace core    
10    
11        #region struct granny_file
12        /// <summary>
13        /// granny_file: update
14        /// </summary>
15        public struct granny_file
16      {      {
         namespace coretypes  
         {  
             #region typedefs  
             using granny_uint32 = System.UInt32;  
             using granny_uint16 = System.UInt16;  
             using granny_uint8 = System.Byte;  
   
             using granny_int32 = System.Int32;  
             using granny_int16 = System.Int16;  
             using granny_int8 = System.SByte;  
   
             using granny_bool32 = System.Int32;  
             using granny_real32 = System.Single;  
   
             using granny_real16 = System.UInt16;  
             using granny_uint32x = System.UInt32;  
             using granny_uint16x = System.UInt32;  
             using granny_uint8x = System.UInt32;  
   
             using granny_int32x = System.Int32;  
             using granny_int16x = System.Int32;  
             using granny_int8x = System.Int32;  
             using granny_bool32x = System.Int32;  
   
             using granny_real64x = System.Double;  
   
             using granny_real32x = System.Single;  
   
             using granny_triple = System.Single;//[3];          // declare type -> unsafe fixed  
             using granny_quad = System.Single;//[4];            // declare type -> unsafe fixed  
             using granny_matrix_3x3 = System.Single;//[3][3];   // declare type -> unsafe fixed  
             using granny_matrix_4x4 = System.Single;//[4][4];   // declare type -> unsafe fixed  
             using granny_matrix_3x4 = System.Single;//[3][4];   // declare type -> unsafe fixed  
             #endregion  
   
             #region struct granny_file  
             /// <summary>  
             /// granny_file: update  
             /// </summary>  
             public struct granny_file  
             {  
17  #pragma warning disable 0169  #pragma warning disable 0169
18                  bool IsByteReversed;          bool IsByteReversed;
19                  unsafe granny_grn_file_header* Header;          unsafe granny_grn_file_header* Header;
20                  unsafe granny_grn_file_magic_value* SourceMagicValue;          unsafe granny_grn_file_magic_value* SourceMagicValue;
21                  granny_int32x SectionCount;          granny_int32x SectionCount;
22                  unsafe void** Sections;          unsafe void** Sections;
23                  unsafe bool* Marshalled;          unsafe bool* Marshalled;
24                  unsafe bool* IsUserMemory;          unsafe bool* IsUserMemory;
25                  unsafe void* ConversionBuffer;          unsafe void* ConversionBuffer;
26  #pragma warning restore 0169  #pragma warning restore 0169
27              };      };
28              #endregion      #endregion
29    
30              #region struct granny_grn_reference      #region struct granny_grn_reference
31              /// <summary>      /// <summary>
32              /// granny_grn_reference: update      /// granny_grn_reference: update
33              /// </summary>      /// </summary>
34              public struct granny_grn_reference      public struct granny_grn_reference
35              {      {
36  #pragma warning disable 0169  #pragma warning disable 0169
37                  granny_uint32 SectionIndex;          granny_uint32 SectionIndex;
38                  granny_uint32 Offset;          granny_uint32 Offset;
39  #pragma warning restore 0169  #pragma warning restore 0169
40              };// GrannyAlignAttribute;      };// GrannyAlignAttribute;
41              #endregion      #endregion
42    
43              #region struct granny_grn_file_header      #region struct granny_grn_file_header
44              /// <summary>      /// <summary>
45              /// granny_grn_file_header: update      /// granny_grn_file_header: update
46              /// </summary>      /// </summary>
47              public struct granny_grn_file_header      public struct granny_grn_file_header
48              {      {
49            //public granny_grn_file_header()
50            //{
51            //    ExtraTags = new granny_uint32[GrannyGRNExtraTagCount];
52            //    ReservedUnused = granny_uint32[3];
53            //}
54  #pragma warning disable 0169  #pragma warning disable 0169
55                  granny_uint32 Version;          granny_uint32 Version;
56                  granny_uint32 TotalSize;          granny_uint32 TotalSize;
57                  granny_uint32 CRC;          granny_uint32 CRC;
58                  granny_uint32 SectionArrayOffset;          granny_uint32 SectionArrayOffset;
59                  granny_uint32 SectionArrayCount;          granny_uint32 SectionArrayCount;
60                  granny_grn_reference RootObjectTypeDefinition;          granny_grn_reference RootObjectTypeDefinition;
61                  granny_grn_reference RootObject;          granny_grn_reference RootObject;
62                  granny_uint32 TypeTag;          granny_uint32 TypeTag;
63                  private const int GrannyGRNExtraTagCount = 4;          private const int GrannyGRNExtraTagCount = 4;
64                  unsafe fixed granny_uint32 ExtraTags[GrannyGRNExtraTagCount];          unsafe granny_uint32* ExtraTags;
65                  granny_uint32 StringDatabaseCRC;          granny_uint32 StringDatabaseCRC;
66                  unsafe fixed granny_uint32 ReservedUnused[3];          unsafe granny_uint32* ReservedUnused;
67  #pragma warning restore 0169  #pragma warning restore 0169
68              };// GrannyAlignAttribute;      };// GrannyAlignAttribute;
69              #endregion      #endregion
70    
71              #region struct granny_grn_file_magic_value      #region struct granny_grn_file_magic_value
72              /// <summary>      /// <summary>
73              /// granny_grn_file_magic_value: update      /// granny_grn_file_magic_value: update
74              /// </summary>      /// </summary>
75              public struct granny_grn_file_magic_value      public struct granny_grn_file_magic_value
76              {      {
77            //static granny_grn_file_magic_value()
78            //{
79            //    MagicValue = granny_uint32[4];
80            //    Reserved = granny_uint32[2];
81            //}
82  #pragma warning disable 0169  #pragma warning disable 0169
83                  unsafe fixed granny_uint32 MagicValue[4];          unsafe granny_uint32* MagicValue;
84                  granny_uint32 HeaderSize;          granny_uint32 HeaderSize;
85                  granny_uint32 HeaderFormat;          granny_uint32 HeaderFormat;
86                  unsafe fixed granny_uint32 Reserved[2];          unsafe granny_uint32* Reserved;
87  #pragma warning restore 0169  #pragma warning restore 0169
88              };// GrannyAlignAttribute;      };// GrannyAlignAttribute;
89              #endregion      #endregion
         }  
     }  
90  }  }

Legend:
Removed from v.8  
changed lines
  Added in v.13

  ViewVC Help
Powered by ViewVC 1.1.22