tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

RenderTargetD3D.cpp (737B)


      1 //
      2 // Copyright 2012 The ANGLE Project Authors. All rights reserved.
      3 // Use of this source code is governed by a BSD-style license that can be
      4 // found in the LICENSE file.
      5 //
      6 
      7 // RenderTargetD3D.cpp: Implements serial handling for rx::RenderTargetD3D
      8 
      9 #include "libANGLE/renderer/d3d/RenderTargetD3D.h"
     10 
     11 namespace rx
     12 {
     13 unsigned int RenderTargetD3D::mCurrentSerial = 1;
     14 
     15 RenderTargetD3D::RenderTargetD3D() : mSerial(issueSerials(1)) {}
     16 
     17 RenderTargetD3D::~RenderTargetD3D() {}
     18 
     19 unsigned int RenderTargetD3D::getSerial() const
     20 {
     21    return mSerial;
     22 }
     23 
     24 unsigned int RenderTargetD3D::issueSerials(unsigned int count)
     25 {
     26    unsigned int firstSerial = mCurrentSerial;
     27    mCurrentSerial += count;
     28    return firstSerial;
     29 }
     30 
     31 }  // namespace rx