mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-24 05:11:16 +00:00
Bug 1685183 Part 2: Remove scale factor from SurfaceDescriptorMacIOSurface. r=jgilbert
Differential Revision: https://phabricator.services.mozilla.com/D101227
This commit is contained in:
parent
e4fe1123e7
commit
069a9b5451
@ -92,8 +92,7 @@ Maybe<layers::SurfaceDescriptor>
|
||||
SharedSurface_IOSurface::ToSurfaceDescriptor() {
|
||||
const bool isOpaque = false; // RGBA
|
||||
return Some(layers::SurfaceDescriptorMacIOSurface(
|
||||
mIOSurf->GetIOSurfaceID(), mIOSurf->GetContentsScaleFactor(), isOpaque,
|
||||
mIOSurf->GetYUVColorSpace()));
|
||||
mIOSurf->GetIOSurfaceID(), isOpaque, mIOSurf->GetYUVColorSpace()));
|
||||
}
|
||||
|
||||
} // namespace gl
|
||||
|
@ -56,7 +56,6 @@ namespace layers {
|
||||
|
||||
[Comparable] struct SurfaceDescriptorMacIOSurface {
|
||||
uint32_t surfaceId;
|
||||
double scaleFactor;
|
||||
bool isOpaque;
|
||||
YUVColorSpace yUVColorSpace;
|
||||
};
|
||||
|
@ -50,17 +50,17 @@ MacIOSurfaceTextureData* MacIOSurfaceTextureData::Create(const IntSize& aSize,
|
||||
}
|
||||
|
||||
bool MacIOSurfaceTextureData::Serialize(SurfaceDescriptor& aOutDescriptor) {
|
||||
aOutDescriptor = SurfaceDescriptorMacIOSurface(
|
||||
mSurface->GetIOSurfaceID(), mSurface->GetContentsScaleFactor(),
|
||||
!mSurface->HasAlpha(), mSurface->GetYUVColorSpace());
|
||||
aOutDescriptor = SurfaceDescriptorMacIOSurface(mSurface->GetIOSurfaceID(),
|
||||
!mSurface->HasAlpha(),
|
||||
mSurface->GetYUVColorSpace());
|
||||
return true;
|
||||
}
|
||||
|
||||
void MacIOSurfaceTextureData::GetSubDescriptor(
|
||||
RemoteDecoderVideoSubDescriptor* const aOutDesc) {
|
||||
*aOutDesc = SurfaceDescriptorMacIOSurface(
|
||||
mSurface->GetIOSurfaceID(), mSurface->GetContentsScaleFactor(),
|
||||
!mSurface->HasAlpha(), mSurface->GetYUVColorSpace());
|
||||
*aOutDesc = SurfaceDescriptorMacIOSurface(mSurface->GetIOSurfaceID(),
|
||||
!mSurface->HasAlpha(),
|
||||
mSurface->GetYUVColorSpace());
|
||||
}
|
||||
|
||||
void MacIOSurfaceTextureData::FillInfo(TextureData::Info& aInfo) const {
|
||||
|
@ -19,9 +19,9 @@ MacIOSurfaceTextureHostOGL::MacIOSurfaceTextureHostOGL(
|
||||
TextureFlags aFlags, const SurfaceDescriptorMacIOSurface& aDescriptor)
|
||||
: TextureHost(aFlags) {
|
||||
MOZ_COUNT_CTOR(MacIOSurfaceTextureHostOGL);
|
||||
mSurface = MacIOSurface::LookupSurface(
|
||||
aDescriptor.surfaceId(), aDescriptor.scaleFactor(),
|
||||
!aDescriptor.isOpaque(), aDescriptor.yUVColorSpace());
|
||||
mSurface = MacIOSurface::LookupSurface(aDescriptor.surfaceId(),
|
||||
!aDescriptor.isOpaque(),
|
||||
aDescriptor.yUVColorSpace());
|
||||
if (!mSurface) {
|
||||
gfxCriticalNote << "Failed to look up MacIOSurface";
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user