跳到主要内容

SystemInfo🧪

SystemInfo 域定义了用于查询底层系统信息的方法和事件。

EN
The SystemInfo domain defines methods and events for querying low-level system information.

✅️️ Methods

🔨SystemInfo.getFeatureState

返回关于功能状态的信息。

EN
Returns information about the feature state.
参数必填标记类型描述原文
featureState✔️string
返回对象类型描述原文
featureEnabledboolean

🔨SystemInfo.getInfo

返回有关系统的信息。

EN
Returns information about the system.
返回对象类型描述原文
gpuGPUInfo系统上GPU的相关信息。
ENInformation about the GPUs on the system.
modelNamestring一个平台相关的机器型号描述。在Mac OS上,例如,这是'MacBookPro'。如果不支持,将为空字符串。
ENA platform-dependent description of the model of the machine. On Mac OS, this is, for example, 'MacBookPro'. Will be the empty string if not supported.
modelVersionstring机器版本的一个平台相关描述。例如,在Mac OS上,这可能是'10.1'。如果不支持,将是一个空字符串。
ENA platform-dependent description of the version of the machine. On Mac OS, this is, for example, '10.1'. Will be the empty string if not supported.
commandLinestring用于启动浏览器的命令行字符串。如果不支持,则为空字符串。
ENThe command line string used to launch the browser. Will be the empty string if not supported.

🔨SystemInfo.getProcessInfo

返回有关所有正在运行的进程的信息。

EN
Returns information about all running processes.
返回对象类型描述原文
processInfoarray[ProcessInfo]一组进程信息块。
ENAn array of process info blocks.

✅️️ Types

📌SystemInfo.GPUDevice

描述单个图形处理器(GPU)。

EN
Describes a single graphics processor (GPU).

返回类型:object

属性必填标记类型描述原文
vendorId✔️numberGPU供应商的PCI ID(如果可用);否则为0。
ENPCI ID of the GPU vendor, if available; 0 otherwise.
deviceId✔️numberGPU设备的PCI ID(如果可用);否则为0。
ENPCI ID of the GPU device, if available; 0 otherwise.
subSysIdnumberGPU 的子系统 ID,仅在 Windows 上可用。
ENSub sys ID of the GPU, only available on Windows.
revisionnumberGPU的修订版本,仅适用于Windows。
ENRevision of the GPU, only available on Windows.
vendorString✔️stringGPU供应商的字符串描述,如果PCI ID不可用。
ENString description of the GPU vendor, if the PCI ID is not available.
deviceString✔️stringGPU设备的字符串描述,如果PCI ID不可用。
ENString description of the GPU device, if the PCI ID is not available.
driverVendor✔️stringGPU驱动供应商的字符串描述。
ENString description of the GPU driver vendor.
driverVersion✔️stringGPU驱动版本的字符串描述。
ENString description of the GPU driver version.

📌SystemInfo.GPUInfo

提供有关系统上GPU的信息。

EN
Provides information about the GPU(s) on the system.

返回类型:object

属性必填标记类型描述原文
devices✔️array[GPUDevice]系统中的图形设备。元素0是主GPU。
ENThe graphics devices on the system. Element 0 is the primary GPU.
auxAttributesobject一个可选的字典,包含额外的GPU相关属性。
ENAn optional dictionary of additional GPU related attributes.
featureStatusobject一个可选的图形特性及其状态字典。
ENAn optional dictionary of graphics features and their status.
driverBugWorkarounds✔️array[string]一个可选的GPU驱动错误规避方案数组。
ENAn optional array of GPU driver bug workarounds.
videoDecoding✔️array[VideoDecodeAcceleratorCapability]支持的加速视频解码能力。
ENSupported accelerated video decoding capabilities.
videoEncoding✔️array[VideoEncodeAcceleratorCapability]支持的加速视频编码能力。
ENSupported accelerated video encoding capabilities.

📌SystemInfo.ImageType

给定图像的图像格式。
允许的值:jpegwebpunknown

EN
Image format of a given image.
Allowed Values: jpeg, webp, unknown

返回类型:string


📌SystemInfo.ProcessInfo

表示进程信息。

EN
Represents process info.

返回类型:object

属性必填标记类型描述原文
type✔️string指定进程类型。
ENSpecifies process type.
id✔️integer指定进程ID。
ENSpecifies process id.
cpuTime✔️number指定自进程启动以来,该进程所有线程的累计CPU使用时间(以秒为单位)。
ENSpecifies cumulative CPU usage in seconds across all threads of the process since the process start.

📌SystemInfo.Size

描述一个实体的宽度和高度尺寸。

EN
Describes the width and height dimensions of an entity.

返回类型:object

属性必填标记类型描述原文
width✔️integer宽度(以像素为单位)。
ENWidth in pixels.
height✔️integer高度(以像素为单位)。
ENHeight in pixels.

📌SystemInfo.SubsamplingFormat

给定图像的像素YUV子采样类型。
允许值:yuv420yuv422yuv444

EN
YUV subsampling type of the pixels of a given image.
Allowed Values: yuv420, yuv422, yuv444

返回类型:string


📌SystemInfo.VideoDecodeAcceleratorCapability

描述一个支持的视频解码配置文件及其关联的最小和最大分辨率。

EN
Describes a supported video decoding profile with its associated minimum and maximum resolutions.

返回类型:object

属性必填标记类型描述原文
profile✔️string支持的视频编解码器配置文件,例如 ''VP9 Profile 2''。
ENVideo codec profile that is supported, e.g. VP9 Profile 2.
maxResolution✔️Size此 |profile| 支持的最大视频尺寸(以像素为单位)。
ENMaximum video dimensions in pixels supported for this |profile|.
minResolution✔️Size此 |profile| 支持的最小视频尺寸(以像素为单位)。
ENMinimum video dimensions in pixels supported for this |profile|.

📌SystemInfo.VideoEncodeAcceleratorCapability

描述一个支持的视频编码配置文件,包括其关联的最大分辨率和最大帧率。

EN
Describes a supported video encoding profile with its associated maximum resolution and maximum framerate.

返回类型:object

属性必填标记类型描述原文
profile✔️stringVideo codec profile that is supported, e.g H264 Main.
ENVideo codec profile that is supported, e.g H264 Main.
maxResolution✔️Size此 |profile| 支持的最大视频尺寸(以像素为单位)。
ENMaximum video dimensions in pixels supported for this |profile|.
maxFramerateNumerator✔️integer此 |profile| 支持的最大编码帧率(以每秒帧数为单位),以分数的分子和分母表示,例如 24/1 fps、24000/1001 fps 等。
ENMaximum encoding framerate in frames per second supported for this |profile|, as fraction's numerator and denominator, e.g. 24/1 fps, 24000/1001 fps, etc.
maxFramerateDenominator✔️integer