기술 자료

Unity Engine

Unity Engine

IsAttached()

Returns true if running via PIX and in a development build.
읽는 시간 1분최근 업데이트: 한 달 전

Definition

public static bool IsAttached()

Returns

Type

Description

bool

Examples

using UnityEngine;using UnityEngine.Rendering;public class PixControl : MonoBehaviour{ public int frameCaptureCount = 1; int frameCount = 0; bool capturing = false; void Awake() { if (PIX.IsAttached()) { PIX.BeginGPUCapture(); capturing = true; } } void Update() { if (frameCount > frameCaptureCount && capturing) { PIX.EndGPUCapture(); capturing = false; } frameCount++; }}