OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2007, 2008, 2009, 2010 Apple Inc. All rights reserved. | 2 * Copyright (C) 2007, 2008, 2009, 2010 Apple Inc. All rights reserved. |
3 * | 3 * |
4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
5 * modification, are permitted provided that the following conditions | 5 * modification, are permitted provided that the following conditions |
6 * are met: | 6 * are met: |
7 * 1. Redistributions of source code must retain the above copyright | 7 * 1. Redistributions of source code must retain the above copyright |
8 * notice, this list of conditions and the following disclaimer. | 8 * notice, this list of conditions and the following disclaimer. |
9 * 2. Redistributions in binary form must reproduce the above copyright | 9 * 2. Redistributions in binary form must reproduce the above copyright |
10 * notice, this list of conditions and the following disclaimer in the | 10 * notice, this list of conditions and the following disclaimer in the |
(...skipping 305 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
316 return false; | 316 return false; |
317 | 317 |
318 return webMediaPlayer()->copyVideoTextureToPlatformTexture( | 318 return webMediaPlayer()->copyVideoTextureToPlatformTexture( |
319 gl, texture, premultiplyAlpha, flipY); | 319 gl, texture, premultiplyAlpha, flipY); |
320 } | 320 } |
321 | 321 |
322 bool HTMLVideoElement::texImageImpl( | 322 bool HTMLVideoElement::texImageImpl( |
323 WebMediaPlayer::TexImageFunctionID functionID, | 323 WebMediaPlayer::TexImageFunctionID functionID, |
324 GLenum target, | 324 GLenum target, |
325 gpu::gles2::GLES2Interface* gl, | 325 gpu::gles2::GLES2Interface* gl, |
| 326 GLuint texture, |
326 GLint level, | 327 GLint level, |
327 GLint internalformat, | 328 GLint internalformat, |
328 GLenum format, | 329 GLenum format, |
329 GLenum type, | 330 GLenum type, |
330 GLint xoffset, | 331 GLint xoffset, |
331 GLint yoffset, | 332 GLint yoffset, |
332 GLint zoffset, | 333 GLint zoffset, |
333 bool flipY, | 334 bool flipY, |
334 bool premultiplyAlpha) { | 335 bool premultiplyAlpha) { |
335 if (!webMediaPlayer()) | 336 if (!webMediaPlayer()) |
336 return false; | 337 return false; |
337 return webMediaPlayer()->texImageImpl( | 338 return webMediaPlayer()->texImageImpl( |
338 functionID, target, gl, level, internalformat, format, type, xoffset, | 339 functionID, target, gl, texture, level, internalformat, format, type, |
339 yoffset, zoffset, flipY, premultiplyAlpha); | 340 xoffset, yoffset, zoffset, flipY, premultiplyAlpha); |
340 } | 341 } |
341 | 342 |
342 bool HTMLVideoElement::hasAvailableVideoFrame() const { | 343 bool HTMLVideoElement::hasAvailableVideoFrame() const { |
343 if (!webMediaPlayer()) | 344 if (!webMediaPlayer()) |
344 return false; | 345 return false; |
345 | 346 |
346 return webMediaPlayer()->hasVideo() && | 347 return webMediaPlayer()->hasVideo() && |
347 webMediaPlayer()->getReadyState() >= | 348 webMediaPlayer()->getReadyState() >= |
348 WebMediaPlayer::ReadyStateHaveCurrentData; | 349 WebMediaPlayer::ReadyStateHaveCurrentData; |
349 } | 350 } |
(...skipping 122 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
472 return ScriptPromise(); | 473 return ScriptPromise(); |
473 if (!ImageBitmap::isResizeOptionValid(options, exceptionState)) | 474 if (!ImageBitmap::isResizeOptionValid(options, exceptionState)) |
474 return ScriptPromise(); | 475 return ScriptPromise(); |
475 return ImageBitmapSource::fulfillImageBitmap( | 476 return ImageBitmapSource::fulfillImageBitmap( |
476 scriptState, | 477 scriptState, |
477 ImageBitmap::create(this, cropRect, | 478 ImageBitmap::create(this, cropRect, |
478 eventTarget.toLocalDOMWindow()->document(), options)); | 479 eventTarget.toLocalDOMWindow()->document(), options)); |
479 } | 480 } |
480 | 481 |
481 } // namespace blink | 482 } // namespace blink |
OLD | NEW |