Esempio n. 1
0
        /// <summary>
        /// Rounds height upto value divisible by 16,
        /// or 32 in the case where picstruct is MFX_PICSTRUCT_PROGRESSIVE
        /// </summary>
        /// <param name="height"></param>
        /// <param name="picstruct">Used to decide 16 or 32 for rounding up</param>
        /// <returns></returns>
        public static ushort AlignHeightTo32or16(int height, PicStruct picstruct)
        {
            ushort v =
                (PicStruct.MFX_PICSTRUCT_PROGRESSIVE == picstruct) ?
                (ushort)QuickSyncStatic.ALIGN16(height) :
                (ushort)QuickSyncStatic.ALIGN32(height);

            return(v);
        }