Anforderungen  |   Konzepte  |   Entwurf  |   Entwicklung  |   Qualitätssicherung  |   Lebenszyklus  |   Steuerung
 
 
 
 


Quelle  D3D11TextureWrapper.h   Sprache: C

 
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* vim:set ts=2 sw=2 sts=2 et cindent: */
/* This Source Code Form is subject to the terms of the Mozilla Public
 * License, v. 2.0. If a copy of the MPL was not distributed with this
 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */


#ifndef __D3D11TextureWrapper_h__
#define __D3D11TextureWrapper_h__

#include <functional>

#include "mozilla/UniquePtr.h"

struct AVFrame;
struct AVBufferRef;
struct ID3D11Texture2D;

namespace mozilla {

struct FFmpegLibWrapper;

// D3D11TextureWrapper manages the lifecycle of hardware buffers used
// by the FFVPX hardware decoder when zero-copy decoding is enabled. By
// adding a reference to the hardware buffer, it prevents the FFVPX decoder
// from reusing the buffer too early (while it is still being used for display),
// which can help avoid significant playback stutter.
class D3D11TextureWrapper final {
 public:
  D3D11TextureWrapper(AVFrame* aAVFrame, FFmpegLibWrapper* aLib,
                      ID3D11Texture2D* aTexture, unsigned int aArrayIdx,
                      std::function<void()>&& aReleaseMethod);
  D3D11TextureWrapper(D3D11TextureWrapper&& aWrapper) = delete;
  D3D11TextureWrapper(const D3D11TextureWrapper&& aWrapper) = delete;

  ~D3D11TextureWrapper();

  ID3D11Texture2D* GetTexture() const { return mTexture; }
  unsigned int GetArrayIdx() const { return mArrayIdx; }

 private:
  FFmpegLibWrapper* mLib;
  ID3D11Texture2D* mTexture;
  AVBufferRef* mHWAVBuffer;
  const unsigned int mArrayIdx;
  const std::function<void()> mReleaseMethod;
};

}  // namespace mozilla

#endif  // __D3D11TextureWrapper_h__

Messung V0.5
C=84 H=100 G=92

¤ Dauer der Verarbeitung: 0.3 Sekunden  ¤

*© 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.






                                                                                                                                                                                                                                                                                                                                                                                                     


Neuigkeiten

     Aktuelles
     Motto des Tages

Software

     Produkte
     Quellcodebibliothek

Aktivitäten

     Artikel über Sicherheit
     Anleitung zur Aktivierung von SSL

Muße

     Gedichte
     Musik
     Bilder

Jenseits des Üblichen ....

Besucherstatistik

Besucherstatistik

Monitoring

Montastic status badge