Home | History | Annotate | Download | only in cloud_print
      1 // Copyright 2013 The Chromium Authors. All rights reserved.
      2 // Use of this source code is governed by a BSD-style license that can be
      3 // found in the LICENSE file.
      4 
      5 #include "chrome/utility/cloud_print/bitmap_image.h"
      6 
      7 namespace cloud_print {
      8 
      9 namespace {
     10 const uint8 kCurrentlySupportedNumberOfChannels = 4;
     11 }
     12 
     13 BitmapImage::BitmapImage(const gfx::Size& size,
     14                          Colorspace colorspace)
     15     : size_(size),
     16       colorspace_(colorspace),
     17       data_(new uint8[size.GetArea() * channels()]) {
     18 }
     19 
     20 BitmapImage::~BitmapImage() {
     21 }
     22 
     23 uint8 BitmapImage::channels() const {
     24   return kCurrentlySupportedNumberOfChannels;
     25 }
     26 
     27 }  // namespace cloud_print
     28