---
title: "glDepthFunc(_:)"
framework: OpenGL ES
role: symbol
role_heading: Function
platforms: [iOS 3.0+, iPadOS 3.0+, Mac Catalyst 3.0+, tvOS 9.0+]
path: "opengles/gldepthfunc(_:)"
---

# glDepthFunc(_:)

## Declaration

```swift
func glDepthFunc(_ func: GLenum)
```
