mirror of
https://github.com/intel/compute-runtime.git
synced 2026-01-06 10:26:29 +08:00
Change-Id: Iece2fbdadefe338384f8961eef2720ff9b381e23 Signed-off-by: Maciej Dziuban <maciej.dziuban@intel.com>
28 lines
481 B
C++
28 lines
481 B
C++
/*
|
|
* Copyright (C) 2020 Intel Corporation
|
|
*
|
|
* SPDX-License-Identifier: MIT
|
|
*
|
|
*/
|
|
|
|
#pragma once
|
|
|
|
#include "opencl/source/sharings/gl/gl_sharing.h"
|
|
|
|
#include "gl_types.h"
|
|
|
|
namespace NEO {
|
|
class GLContextGuard {
|
|
public:
|
|
GLContextGuard() = delete;
|
|
GLContextGuard(GLSharingFunctions &sharingFcns);
|
|
~GLContextGuard();
|
|
|
|
protected:
|
|
GLSharingFunctions *sharingFunctions;
|
|
|
|
GLContext currentContextHandle;
|
|
GLDisplay currentDisplayHandle;
|
|
};
|
|
} // namespace NEO
|