IltmmCompressor::get_Reliability Example for C

// Selecting the first stable video compressor: 

L_MULTIMEDIATEX_API void IltmmCompressor_get_Reliability_Example (IltmmCapture* pCapture)
{
   // Selecting the first stable video compressor: 
   IltmmCompressors *pVideoCompressors;
   IltmmCompressor *pCompressor;
   long i, lCount, lReliability;


   IltmmCapture_get_VideoCompressors(pCapture, &pVideoCompressors);

   IltmmCompressors_get_Count(pVideoCompressors, &lCount);

   for ( i=0; i<lCount; i++ )
   {
      IltmmCompressors_put_Selection(pVideoCompressors, i);

      IltmmCompressors_Item(pVideoCompressors, i, &pCompressor);

      IltmmCompressor_get_Reliability(pCompressor, &lReliability);

      IltmmCompressor_Release(pCompressor);

      if( lReliability == ltmmCompressor_Reliability_Stable )
      {
         IltmmCompressors_put_Selection(pVideoCompressors, i);

         break;
      }
   }
}