Home | History | Annotate | Download | only in image

Lines Matching refs:Image

5 // An Image wraps an image any flavor, be it platform-native GdkBitmap/NSImage,
6 // or a SkBitmap. This also provides easy conversion to other image types
11 // tied to the lifetime of the Image's internal storage. To allow Images to be
12 // cheaply passed around by value, the actual image data is stored in a ref-
17 // Attempting to use an empty Image will result in a crash.
52 class GFX_EXPORT Image {
63 // Creates an empty image with no representations.
64 Image();
66 // Creates a new image by copying the raw PNG-encoded input for use as the
68 explicit Image(const std::vector<ImagePNGRep>& image_reps);
70 // Creates a new image by copying the ImageSkia for use as the default
72 explicit Image(const ImageSkia& image);
75 // Does not retain |image|; expects to take ownership.
76 explicit Image(UIImage* image);
78 // Does not retain |image|; expects to take ownership.
81 explicit Image(NSImage* image);
84 // Initializes a new Image by AddRef()ing |other|'s internal storage.
85 Image(const Image& other);
88 Image& operator=(const Image& other);
90 // Deletes the image and, if the only owner of the storage, all of its cached
92 ~Image();
94 // Creates an image from the passed in 1x bitmap.
95 // WARNING: The resulting image will be pixelated when painted on a high
97 static Image CreateFrom1xBitmap(const SkBitmap& bitmap);
99 // Creates an image from the PNG encoded input.
102 // gfx::Image image =
103 // Image::CreateFrom1xPNGBytes(&png.front(), png.size());
104 static Image CreateFrom1xPNGBytes(const unsigned char* input,
107 // Creates an image from the PNG encoded input.
108 static Image CreateFrom1xPNGBytes(
111 // Converts the Image to the desired representation and stores it internally.
113 // the Image. Must only be called if IsEmpty() is false.
123 // unavailable, either because the image has no data for 1x or because it is
128 // Same as ToSkBitmap(), but returns a null SkBitmap if this image is empty.
132 // image is empty.
136 // Same as ToSkBitmap(), but returns nil if this image is empty.
144 // converted representations, rather than a limitation imposed by Image) and
161 // Returns true if this Image has no representations.
164 // Width and height of image in DIP coordinate system.
169 // Swaps this image's internal representations with |other|.
170 void SwapRepresentations(gfx::Image* other);
191 // Internal class that holds all the representations. This allows the Image to