Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(223)

Unified Diff: ppapi/proxy/video_decoder_resource_unittest.cc

Issue 496203002: Pepper: PPB_VideoDecoder software-only mode. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Address comments. Created 6 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ppapi/proxy/video_decoder_resource.cc ('k') | ppapi/tests/test_video_decoder.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ppapi/proxy/video_decoder_resource_unittest.cc
diff --git a/ppapi/proxy/video_decoder_resource_unittest.cc b/ppapi/proxy/video_decoder_resource_unittest.cc
index b9f0e7918d44e5d1cd840d234a4afa84b8b25002..fa6e89f985ddcec71f7d0a80b956dfb0a3fcb10f 100644
--- a/ppapi/proxy/video_decoder_resource_unittest.cc
+++ b/ppapi/proxy/video_decoder_resource_unittest.cc
@@ -26,7 +26,6 @@ namespace proxy {
namespace {
-const PP_Bool kAllowSoftwareFallback = PP_TRUE;
const PP_Resource kGraphics3D = 7;
const uint32_t kShmSize = 256;
const size_t kDecodeBufferSize = 16;
@@ -59,9 +58,9 @@ class MockCompletionCallback {
class VideoDecoderResourceTest : public PluginProxyTest {
public:
VideoDecoderResourceTest()
- : decoder_iface_(thunk::GetPPB_VideoDecoder_0_1_Thunk()) {}
+ : decoder_iface_(thunk::GetPPB_VideoDecoder_0_2_Thunk()) {}
- const PPB_VideoDecoder_0_1* decoder_iface() const { return decoder_iface_; }
+ const PPB_VideoDecoder_0_2* decoder_iface() const { return decoder_iface_; }
void SendReply(const ResourceMessageCallParams& params,
int32_t result,
@@ -117,7 +116,7 @@ class VideoDecoderResourceTest : public PluginProxyTest {
decoder,
graphics3d.get(),
PP_VIDEOPROFILE_H264MAIN,
- PP_TRUE /* allow_software_fallback */,
+ PP_HARDWAREACCELERATION_WITHFALLBACK,
PP_MakeOptionalCompletionCallback(&MockCompletionCallback::Callback,
&cb));
if (result != PP_OK_COMPLETIONPENDING)
@@ -299,7 +298,7 @@ class VideoDecoderResourceTest : public PluginProxyTest {
return true;
}
- const PPB_VideoDecoder_0_1* decoder_iface_;
+ const PPB_VideoDecoder_0_2* decoder_iface_;
char decode_buffer_[kDecodeBufferSize];
};
@@ -315,7 +314,7 @@ TEST_F(VideoDecoderResourceTest, Initialize) {
decoder.get(),
0 /* invalid 3d graphics */,
PP_VIDEOPROFILE_H264MAIN,
- kAllowSoftwareFallback,
+ PP_HARDWAREACCELERATION_WITHFALLBACK,
PP_MakeOptionalCompletionCallback(&MockCompletionCallback::Callback,
&cb));
ASSERT_EQ(PP_ERROR_BADRESOURCE, result);
@@ -328,7 +327,7 @@ TEST_F(VideoDecoderResourceTest, Initialize) {
decoder.get(),
1 /* non-zero resource */,
static_cast<PP_VideoProfile>(-1),
- kAllowSoftwareFallback,
+ PP_HARDWAREACCELERATION_WITHFALLBACK,
PP_MakeOptionalCompletionCallback(&MockCompletionCallback::Callback,
&cb));
ASSERT_EQ(PP_ERROR_BADARGUMENT, result);
@@ -342,7 +341,7 @@ TEST_F(VideoDecoderResourceTest, Initialize) {
decoder.get(),
graphics3d.get(),
PP_VIDEOPROFILE_H264MAIN,
- kAllowSoftwareFallback,
+ PP_HARDWAREACCELERATION_WITHFALLBACK,
PP_MakeOptionalCompletionCallback(&MockCompletionCallback::Callback,
&cb));
ASSERT_EQ(PP_OK_COMPLETIONPENDING, result);
@@ -353,7 +352,7 @@ TEST_F(VideoDecoderResourceTest, Initialize) {
decoder.get(),
graphics3d.get(),
PP_VIDEOPROFILE_H264MAIN,
- kAllowSoftwareFallback,
+ PP_HARDWAREACCELERATION_WITHFALLBACK,
PP_MakeOptionalCompletionCallback(&MockCompletionCallback::Callback,
&cb));
ASSERT_EQ(PP_ERROR_INPROGRESS, result);
« no previous file with comments | « ppapi/proxy/video_decoder_resource.cc ('k') | ppapi/tests/test_video_decoder.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698