//
// Copyright (C) 2021 The Android Open Source Project
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
//      http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.

// @generated by protoc-gen-es v2.2.2 with parameter "target=ts"
// @generated from file protos/perfetto/metrics/android/camera_metric.proto (package perfetto.protos, syntax proto2)
/* eslint-disable */

import type { GenFile, GenMessage } from "@bufbuild/protobuf/codegenv1";
import { fileDesc, messageDesc } from "@bufbuild/protobuf/codegenv1";
import type { Message } from "@bufbuild/protobuf";

/**
 * Describes the file protos/perfetto/metrics/android/camera_metric.proto.
 */
export const file_protos_perfetto_metrics_android_camera_metric: GenFile = /*@__PURE__*/
  fileDesc("CjNwcm90b3MvcGVyZmV0dG8vbWV0cmljcy9hbmRyb2lkL2NhbWVyYV9tZXRyaWMucHJvdG8SD3BlcmZldHRvLnByb3RvcyKNAQoTQW5kcm9pZENhbWVyYU1ldHJpYxJECg5nY19yc3NfYW5kX2RtYRgBIAEoCzIsLnBlcmZldHRvLnByb3Rvcy5BbmRyb2lkQ2FtZXJhTWV0cmljLkNvdW50ZXIaMAoHQ291bnRlchILCgNtaW4YASABKAESCwoDbWF4GAIgASgBEgsKA2F2ZxgDIAEoAQ");

/**
 * @generated from message perfetto.protos.AndroidCameraMetric
 */
export type AndroidCameraMetric = Message<"perfetto.protos.AndroidCameraMetric"> & {
  /**
   * Counter for the sum of DMA and RSS across GCA, cameraserver
   * and HAL. This provides a single number for the memory
   * pressure using the camera is putting on the rest of the
   * system.
   *
   * Note: this number assumes that all DMA pressure is coming
   * from the camera as this is usually a pretty good
   * approximation. Being more accurate here would increase the
   * complexity of the metric significantly.
   *
   * Note: if there are multiple GCA/cameraserver/HAL processes
   * in the trace, this metric will simply take the latest
   * one in the trace and ignore the others.
   *
   * @generated from field: optional perfetto.protos.AndroidCameraMetric.Counter gc_rss_and_dma = 1;
   */
  gcRssAndDma?: AndroidCameraMetric_Counter;
};

/**
 * Describes the message perfetto.protos.AndroidCameraMetric.
 * Use `create(AndroidCameraMetricSchema)` to create a new message.
 */
export const AndroidCameraMetricSchema: GenMessage<AndroidCameraMetric> = /*@__PURE__*/
  messageDesc(file_protos_perfetto_metrics_android_camera_metric, 0);

/**
 * @generated from message perfetto.protos.AndroidCameraMetric.Counter
 */
export type AndroidCameraMetric_Counter = Message<"perfetto.protos.AndroidCameraMetric.Counter"> & {
  /**
   * @generated from field: optional double min = 1;
   */
  min: number;

  /**
   * @generated from field: optional double max = 2;
   */
  max: number;

  /**
   * @generated from field: optional double avg = 3;
   */
  avg: number;
};

/**
 * Describes the message perfetto.protos.AndroidCameraMetric.Counter.
 * Use `create(AndroidCameraMetric_CounterSchema)` to create a new message.
 */
export const AndroidCameraMetric_CounterSchema: GenMessage<AndroidCameraMetric_Counter> = /*@__PURE__*/
  messageDesc(file_protos_perfetto_metrics_android_camera_metric, 0, 0);

