5.23.2 Headless configuration file reference

The headless configuration file is formatted as JSON. The top-level object contains a single key, processes, which is an array of JSON objects, with each object corresponding to a configuration for an individual process.

Important:

Configuration file items are case-sensitive. Make sure that keys and values are typed exactly as shown.

Table 5-1 Configuration file keys reference

Key Type Accepted values Description
name String A valid process name, or package name on Android. Name of the process. This key is required.
config String fullTrace, everything, balanced, functionsOnly, legacy. Default = legacy. Preset config name.
customConfig Object A valid customConfig object, see Custom config reference. You can use the preset as-is with no changes. Custom configuration of resources per API.
traceDirectory String A valid filesystem path. See 5.23.1 File locations. Directory used for creating headless trace files.
frameCaptures Object A valid frameCaptures object. See Frame captures reference. Allows setting frame captures frame numbers and modes.
disconnectBeforeFrame Integer A valid frame number. Number of the frame to disconnect and disable tracing before.

Custom config reference

The customConfig object contains keys for each API. Values are objects containing Boolean keys specifying whether resources are enabled for that API. All keys are optional.

For an example of how to format this object, see Example configuration file.

Note:

Custom configuration resource toggles are always applied after the preset. A preset can therefore be applied first and then modified by applying the changes made by the custom preset on top. For example, after applying the Everything preset and a custom config with gles.shaderSources disabled, the resulting config has all resources except OpenGL ES shader sources enabled.

customConfig object keys

clOpenCL config object.
glesOpenGL ES config object.
vulkanVulkan config object.

OpenCL config object keys

  • programSources
  • explicitMemory

OpenGL ES config object keys

  • shaderSources
  • shaderUniforms
  • shaderBinaries
  • textureContents
  • explicitBuffers
  • implicitBuffers
  • outputBuffers

Vulkan config object keys

  • shaderBinaries
  • implicitMemory

Frame captures reference

The frameCaptures configuration object contains keys for each frame capture mode. All keys are optional.

The frameCaptures object keys are:

  • default
  • overdraw
  • fragmentCount
  • shaderMap
  • allAttachments

All these keys are integer arrays.

For an example of how to format this object, see Example configuration file.

Example configuration file

This topic shows an example of a headless configuration file.

{
  "processes": [
    {
      "name": "com.example.application",
      "customConfig": {
        "cl": {
          "programSources": false,
          "explicitMemory": false
        },
        "gles": {
          "shaderSources": false,
          "shaderUniforms": false,
          "shaderBinaries": false,
          "textureContents": false,
          "explicitBuffers": false,
          "implicitBuffers": false,
          "outputBuffers": false
        },
        "vulkan": {
          "shaderBinaries": false,
          "implicitMemory": false
        }
      }
    },
    {
      "name": "cube",
      "config": "fullTrace",
      "customConfig": {
        "gles": {
          "outputBuffers": true
        }
      },
      "frameCaptures": {
        "default": [50],
        "overdraw": [65, 81],
        "allAttachments": [22],
        "shaderMap": [25, 33],
        "fragmentCount": [70, 73, 76, 80, 90]
      },
      "disconnectBeforeFrame": 50
    },
    {
      "name": "com.sample.teapot",
      "traceDirectory": "/some/path/"
    }
  ]
}
Non-Confidential - RELPDF file icon PDF version101545__00_en
Copyright © 2020–2022, 2024 Arm Limited or its affiliates. All rights reserved.