/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ /* 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/. */
if (sd.type() != layers::SurfaceDescriptor::TSurfaceDescriptorDMABuf) { return Nothing();
}
return Some(sd);
}
void ExternalTextureDMABuf::GetSnapshot(const ipc::Shmem& aDestShmem, const gfx::IntSize& aSize) { const RefPtr<gfx::SourceSurface> surface = mSurface->GetAsSourceSurface(); if (!surface) {
MOZ_ASSERT_UNREACHABLE("unexpected to be called");
gfxCriticalNoteOnce << "Failed to get SourceSurface from DMABufSurface"; return;
}
const RefPtr<gfx::DataSourceSurface> dataSurface = surface->GetDataSurface(); if (!dataSurface) {
MOZ_ASSERT_UNREACHABLE("unexpected to be called"); return;
}
gfx::DataSourceSurface::ScopedMap map(dataSurface,
gfx::DataSourceSurface::READ); if (!map.IsMapped()) {
MOZ_ASSERT_UNREACHABLE("unexpected to be called"); return;
}
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 ist noch experimentell.