// Copyright © 2010-2016 The CefSharp Authors. All rights reserved. // // Use of this source code is governed by a BSD-style license that can be found in the LICENSE file. using CefSharp.Internals; namespace CefSharp.OffScreen { /// /// BitmapFactory. /// /// public class BitmapFactory : IBitmapFactory { /// /// The bitmap lock /// private readonly object bitmapLock; /// /// Initializes a new instance of the class. /// /// The lock object. public BitmapFactory(object lockObject) { bitmapLock = lockObject; } /// /// Create an instance of BitmapInfo based on the params /// /// create bitmap info for a popup (typically just a bool flag used internally) /// DPI scale /// newly created BitmapInfo BitmapInfo IBitmapFactory.CreateBitmap(bool isPopup, double dpiScale) { //The bitmap buffer is 32 BPP return new GdiBitmapInfo { IsPopup = isPopup, BitmapLock = bitmapLock }; } } }