Esempio n. 1
0
 public override int GetHashCode()
 {
     unchecked
     {
         var hashCode = (int)m_LoadAction;
         hashCode = (hashCode * 397) ^ (int)m_StoreAction;
         hashCode = (hashCode * 397) ^ (int)m_Format;
         hashCode = (hashCode * 397) ^ m_LoadStoreTarget.GetHashCode();
         hashCode = (hashCode * 397) ^ m_ResolveTarget.GetHashCode();
         hashCode = (hashCode * 397) ^ m_ClearColor.GetHashCode();
         hashCode = (hashCode * 397) ^ m_ClearDepth.GetHashCode();
         hashCode = (hashCode * 397) ^ (int)m_ClearStencil;
         return(hashCode);
     }
 }
Esempio n. 2
0
 /// <summary>
 /// Get the Instance ID of the RTHandle.
 /// </summary>
 /// <returns>The RTHandle Instance ID.</returns>
 public int GetInstanceID()
 {
     if (m_RT != null)
     {
         return(m_RT.GetInstanceID());
     }
     else if (m_ExternalTexture != null)
     {
         return(m_ExternalTexture.GetInstanceID());
     }
     else
     {
         return(m_NameID.GetHashCode()); // No instance ID so we return the hash code.
     }
 }