OLD | NEW |
---|---|
1 /* | 1 /* |
2 * Copyright (C) Research In Motion Limited 2009-2010. All rights reserved. | 2 * Copyright (C) Research In Motion Limited 2009-2010. All rights reserved. |
3 * | 3 * |
4 * This library is free software; you can redistribute it and/or | 4 * This library is free software; you can redistribute it and/or |
5 * modify it under the terms of the GNU Library General Public | 5 * modify it under the terms of the GNU Library General Public |
6 * License as published by the Free Software Foundation; either | 6 * License as published by the Free Software Foundation; either |
7 * version 2 of the License, or (at your option) any later version. | 7 * version 2 of the License, or (at your option) any later version. |
8 * | 8 * |
9 * This library is distributed in the hope that it will be useful, | 9 * This library is distributed in the hope that it will be useful, |
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of | 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of |
(...skipping 186 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
197 // this frame is a blank frame, so it can again be decoded alone. | 197 // this frame is a blank frame, so it can again be decoded alone. |
198 // Otherwise, the previous frame contributes to this frame. | 198 // Otherwise, the previous frame contributes to this frame. |
199 return (prevBuffer->originalFrameRect().contains(IntRect(IntPoint(), siz e())) | 199 return (prevBuffer->originalFrameRect().contains(IntRect(IntPoint(), siz e())) |
200 || (prevBuffer->requiredPreviousFrameIndex() == kNotFound)) ? kNotFo und : prevFrame; | 200 || (prevBuffer->requiredPreviousFrameIndex() == kNotFound)) ? kNotFo und : prevFrame; |
201 default: | 201 default: |
202 ASSERT_NOT_REACHED(); | 202 ASSERT_NOT_REACHED(); |
203 return kNotFound; | 203 return kNotFound; |
204 } | 204 } |
205 } | 205 } |
206 | 206 |
207 ImagePlanes::ImagePlanes() | |
208 { | |
209 for (int i = 0; i < 3; ++i) { | |
210 m_planes[i] = 0; | |
211 m_rowBytes[i] = 0; | |
212 } | |
213 } | |
214 | |
215 void ImagePlanes::set(void* planes[3], size_t rowBytes[3]) | |
Noel Gordon
2014/07/28 07:29:07
setPlanes
sugoi1
2014/08/19 20:28:47
Done.
| |
216 { | |
217 for (int i = 0; i < 3; ++i) { | |
218 m_planes[i] = planes[i]; | |
219 m_rowBytes[i] = rowBytes[i]; | |
220 } | |
221 } | |
222 | |
223 void* ImagePlanes::plane(int i) | |
224 { | |
225 ASSERT((i >= 0) && i < 3); | |
226 return m_planes[i]; | |
227 } | |
228 | |
229 size_t ImagePlanes::rowBytes(int i) const | |
230 { | |
231 ASSERT((i >= 0) && i < 3); | |
232 return m_rowBytes[i]; | |
233 } | |
234 | |
207 } // namespace blink | 235 } // namespace blink |
OLD | NEW |