Esempio n. 1
0
        /// <summary>
        /// Initializes a new instance of the NativeList class.
        /// </summary>
        /// <param name="listPtr">The pointer to use for the list.</param>
        public NativeList(IntPtr listPtr)
        {
            this.Ptr = listPtr;
            IHbFunctionsProvider hbFunctionsProvider = new HbFunctionsProvider();

            hbFunctions = hbFunctionsProvider.GetHbFunctionsWrapper();
        }
Esempio n. 2
0
        /// <summary>
        /// Initializes this instance.
        /// </summary>
        /// <param name="verbosity">
        /// The code for the logging verbosity to use.
        /// </param>
        /// <param name="noHardware">
        /// True disables hardware init.
        /// </param>
        public void Initialize(int verbosity, bool noHardware)
        {
            IHbFunctionsProvider hbFunctionsProvider = new HbFunctionsProvider();

            hbFunctions = hbFunctionsProvider.GetHbFunctionsWrapper();

            HandBrakeUtils.EnsureGlobalInit(noHardware);

            HandBrakeUtils.RegisterLogger();
            this.Handle = hbFunctions.hb_init(verbosity, update_check: 0);
        }
Esempio n. 3
0
        /// <summary>
        /// Initializes a new instance of the <see cref="HBVideoEncoder"/> class.
        /// </summary>
        /// <param name="compatibleContainers">
        /// The compatible containers.
        /// </param>
        /// <param name="displayName">
        /// The display name.
        /// </param>
        /// <param name="id">
        /// The id.
        /// </param>
        /// <param name="shortName">
        /// The short name.
        /// </param>
        public HBVideoEncoder(int compatibleContainers, string displayName, int id, string shortName)
        {
            IHbFunctionsProvider hbFunctionsProvider = new HbFunctionsProvider();

            hbFunctions = hbFunctionsProvider.GetHbFunctionsWrapper();

            this.CompatibleContainers = compatibleContainers;
            this.DisplayName          = displayName;
            this.Id        = id;
            this.ShortName = shortName;
        }
        /// <summary>
        /// Initializes static members of the HandBrakeEncoderHelpers class.
        /// </summary>
        static HandBrakeEncoderHelpers()
        {
            IHbFunctionsProvider hbFunctionsProvider = new HbFunctionsProvider();

            hbFunctions = hbFunctionsProvider.GetHbFunctionsWrapper();

            if (!HandBrakeUtils.IsInitialised())
            {
                throw new Exception("Please Initialise with HandBrakeUtils.EnsureGlobalInit before using!");
            }
        }
Esempio n. 5
0
        /// <summary>
        /// Initializes static members of the HandBrakeUnitConversionHelpers class.
        /// </summary>
        static HandBrakeUnitConversionHelpers()
        {
            IHbFunctionsProvider hbFunctionsProvider = new HbFunctionsProvider();

            hbFunctions = hbFunctionsProvider.GetHbFunctionsWrapper();

            if (!HandBrakeUtils.IsInitialised())
            {
                throw new Exception("Please Initialise with HandBrakeUtils.EnsureGlobalInit before using!");
            }

            VideoRates = new Dictionary <double, int>();
            foreach (var framerate in HandBrakeEncoderHelpers.VideoFramerates)
            {
                VideoRates.Add(double.Parse(framerate.Name, CultureInfo.InvariantCulture), framerate.Rate);
            }
        }
Esempio n. 6
0
        static HandBrakeUtils()
        {
            IHbFunctionsProvider hbFunctionsProvider = new HbFunctionsProvider();

            hbFunctions = hbFunctionsProvider.GetHbFunctionsWrapper();
        }
Esempio n. 7
0
        static HandBrakeFilterHelpers()
        {
            IHbFunctionsProvider hbFunctionsProvider = new HbFunctionsProvider();

            hbFunctions = hbFunctionsProvider.GetHbFunctionsWrapper();
        }
Esempio n. 8
0
        static HandBrakeLanguagesHelper()
        {
            IHbFunctionsProvider hbFunctionsProvider = new HbFunctionsProvider();

            hbFunctions = hbFunctionsProvider.GetHbFunctionsWrapper();
        }
Esempio n. 9
0
        /// <summary>
        /// Creates a new list in unmanaged memory.
        /// </summary>
        /// <returns>The created list.</returns>
        public static NativeList CreateList()
        {
            IHbFunctionsProvider hbFunctionsProvider = new HbFunctionsProvider();

            return(new NativeList(hbFunctionsProvider.GetHbFunctionsWrapper().hb_list_init()));
        }
Esempio n. 10
0
        static VersionHelper()
        {
            IHbFunctionsProvider hbFunctionsProvider = new HbFunctionsProvider();

            hbFunctions = hbFunctionsProvider.GetHbFunctionsWrapper();
        }
Esempio n. 11
0
        static InteropUtilities()
        {
            IHbFunctionsProvider hbFunctionsProvider = new HbFunctionsProvider();

            hbFunctions = hbFunctionsProvider.GetHbFunctionsWrapper();
        }
Esempio n. 12
0
        static HandBrakePresetService()
        {
            IHbFunctionsProvider hbFunctionsProvider = new HbFunctionsProvider();

            hbFunctions = hbFunctionsProvider.GetHbFunctionsWrapper();
        }
Esempio n. 13
0
        static SystemInfo()
        {
            IHbFunctionsProvider hbFunctionsProvider = new HbFunctionsProvider();

            hbFunctions = hbFunctionsProvider.GetHbFunctionsWrapper();
        }