コード例 #1
0
        /// <summary>
        /// Retrieves information on a plugin
        /// </summary>
        /// <param name="handle">The plugin handle</param>
        /// <returns>插件信息</returns>
        public static BASS_PLUGINFORM BASS_PluginGetInfo(int handle)
        {
            IntPtr ptr;

            if (Environment.Is64BitProcess)
            {
                ptr = BassX64.BASS_PluginGetInfo(handle);
            }
            else
            {
                ptr = BassX86.BASS_PluginGetInfo(handle);
            }

            if (ptr == IntPtr.Zero)
            {
                throw new ApplicationException("BASS_PluginGetInfo Fail," + BassErrorCode.GetErrorInfo());
            }

            return((BASS_PLUGINFORM)Marshal.PtrToStructure(ptr, typeof(BASS_PLUGININFO)));
        }