Hash :
0be050a4
Author :
Date :
2020-09-23T15:12:56
Pass GL_VERSION info through ANGLE's GL_RENDERER string Chrome needs ANGLE to pass through the underlying driver vendor and version, which cannot always be determined by the SystemInfo library. This is done by construction GL_RENDERER in the frontend through combining GL_VENDOR, GL_RENDERER, and GL_VERSION from the backends. Example changes are in the doc: https://docs.google.com/document/d/1p0dvrLlu8NKhO-RCU5gqlQ_LvcQj-ZqhvfwSk1n3Sz8/edit?usp=sharing Bug: chromium:1126526 Bug: chromium:1131248 Bug: chromium:1134669 Bug: chromium:1169861 Change-Id: Ia618ebcd7f3caaeb376b4b6a03446732efdaeecb Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/2427383 Commit-Queue: Jonah Ryan-Davis <jonahr@google.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>
//
// Copyright 2020 The ANGLE Project Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
//
// driver_utils_d3d.cpp: Information specific to the D3D driver
#include "libANGLE/renderer/d3d/driver_utils_d3d.h"
namespace rx
{
std::string GetDriverVersionString(LARGE_INTEGER driverVersion)
{
std::stringstream versionString;
uint64_t intVersion = driverVersion.QuadPart;
constexpr uint64_t kMask16 = std::numeric_limits<uint16_t>::max();
versionString << ((intVersion >> 48) & kMask16) << ".";
versionString << ((intVersion >> 32) & kMask16) << ".";
versionString << ((intVersion >> 16) & kMask16) << ".";
versionString << (intVersion & kMask16);
return versionString.str();
}
} // namespace rx