Ticket #195: ContextModel.patch
File ContextModel.patch, 1.2 KB (added by Heiner Kirchhoffer, 14 years ago) |
---|
-
ContextModel.h
45 45 46 46 #include "CommonDef.h" 47 47 48 48 #if UNINIT_CTX_CHECK 49 #include<assert.h> 50 #endif 49 51 // ==================================================================================================================== 50 52 // Class definition 51 53 // ==================================================================================================================== … … 54 56 class ContextModel 55 57 { 56 58 public: 59 #if UNINIT_CTX_CHECK 60 ContextModel () { m_ucState = 126; } 61 #else 57 62 ContextModel () { m_ucState = 0; } 63 #endif 58 64 ~ContextModel () {} 59 65 66 #if UNINIT_CTX_CHECK 67 UChar getState () { assert( m_ucState != 126 ); return ( m_ucState >> 1 ); } ///< get current state 68 #else 60 69 UChar getState () { return ( m_ucState >> 1 ); } ///< get current state 70 #endif 61 71 UChar getMps () { return ( m_ucState & 1 ); } ///< get curret MPS 62 72 63 73 Void init ( Int iQp,