Quellcodebibliothek Statistik Leitseite products/Sources/formale Sprachen/C/Firefox/gfx/angle/checkout/src/libANGLE/   (Browser von der Mozilla Stiftung Version 136.0.1©)  Datei vom 10.2.2025 mit Größe 2 kB image not shown  

Quelle  MemoryObject.cpp   Sprache: C

 
//
// Copyright 2019 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.
//
// MemoryObject.h: Implements the gl::MemoryObject class [EXT_external_objects]

#include "libANGLE/MemoryObject.h"

#include "common/angleutils.h"
#include "libANGLE/renderer/GLImplFactory.h"
#include "libANGLE/renderer/MemoryObjectImpl.h"

namespace gl
{

MemoryObject::MemoryObject(rx::GLImplFactory *factory, MemoryObjectID id)
    : RefCountObject(factory->generateSerial(), id),
      mImplementation(factory->createMemoryObject()),
      mImmutable(false),
      mDedicatedMemory(false),
      mProtectedMemory(false)
{}

MemoryObject::~MemoryObject() {}

void MemoryObject::onDestroy(const Context *context)
{
    mImplementation->onDestroy(context);
}

angle::Result MemoryObject::setDedicatedMemory(const Context *context, bool dedicatedMemory)
{
    ANGLE_TRY(mImplementation->setDedicatedMemory(context, dedicatedMemory));
    mDedicatedMemory = dedicatedMemory;
    return angle::Result::Continue;
}

angle::Result MemoryObject::setProtectedMemory(const Context *context, bool protectedMemory)
{
    ANGLE_TRY(mImplementation->setProtectedMemory(context, protectedMemory));
    mProtectedMemory = protectedMemory;
    return angle::Result::Continue;
}

angle::Result MemoryObject::importFd(Context *context,
                                     GLuint64 size,
                                     HandleType handleType,
                                     GLint fd)
{
    ANGLE_TRY(mImplementation->importFd(context, size, handleType, fd));
    mImmutable = true;
    return angle::Result::Continue;
}

angle::Result MemoryObject::importZirconHandle(Context *context,
                                               GLuint64 size,
                                               HandleType handleType,
                                               GLuint handle)
{
    ANGLE_TRY(mImplementation->importZirconHandle(context, size, handleType, handle));
    mImmutable = true;
    return angle::Result::Continue;
}

}  // namespace gl

Messung V0.5
C=92 H=91 G=91

¤ Dauer der Verarbeitung: 0.0 Sekunden  (vorverarbeitet)  ¤

*© Formatika GbR, Deutschland






Wurzel

Suchen

Beweissystem der NASA

Beweissystem Isabelle

NIST Cobol Testsuite

Cephes Mathematical Library

Wiener Entwicklungsmethode

Haftungshinweis

Die Informationen auf dieser Webseite wurden nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit, noch Qualität der bereit gestellten Informationen zugesichert.

Bemerkung:

Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.