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

Side by Side Diff: talk/app/webrtc/java/android/org/webrtc/VideoRendererGui.java

Issue 1322703004: Do not explicitly delete OpenGL shaders in VideoRendererGui. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc@master
Patch Set: Created 5 years, 3 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 unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * libjingle 2 * libjingle
3 * Copyright 2014 Google Inc. 3 * Copyright 2014 Google Inc.
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions are met: 6 * modification, are permitted provided that the following conditions are met:
7 * 7 *
8 * 1. Redistributions of source code must retain the above copyright notice, 8 * 1. Redistributions of source code must retain the above copyright notice,
9 * this list of conditions and the following disclaimer. 9 * this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright notice, 10 * 2. Redistributions in binary form must reproduce the above copyright notice,
(...skipping 442 matching lines...) Expand 10 before | Expand all | Expand 10 after
453 public static synchronized void dispose() { 453 public static synchronized void dispose() {
454 if (instance == null){ 454 if (instance == null){
455 return; 455 return;
456 } 456 }
457 Log.d(TAG, "VideoRendererGui.dispose"); 457 Log.d(TAG, "VideoRendererGui.dispose");
458 synchronized (instance.yuvImageRenderers) { 458 synchronized (instance.yuvImageRenderers) {
459 for (YuvImageRenderer yuvImageRenderer : instance.yuvImageRenderers) { 459 for (YuvImageRenderer yuvImageRenderer : instance.yuvImageRenderers) {
460 yuvImageRenderer.release(); 460 yuvImageRenderer.release();
461 } 461 }
462 instance.yuvImageRenderers.clear(); 462 instance.yuvImageRenderers.clear();
463 if (instance.drawer != null) {
464 instance.drawer.release();
465 }
466 } 463 }
467 instance.surface = null; 464 instance.surface = null;
468 eglContext = null; 465 eglContext = null;
469 eglContextReady = null; 466 eglContextReady = null;
470 instance = null; 467 instance = null;
471 } 468 }
472 469
473 /** 470 /**
474 * Creates VideoRenderer with top left corner at (x, y) and resolution 471 * Creates VideoRenderer with top left corner at (x, y) and resolution
475 * (width, height). All parameters are in percentage of screen resolution. 472 * (width, height). All parameters are in percentage of screen resolution.
(...skipping 159 matching lines...) Expand 10 before | Expand all | Expand 10 after
635 GLES20.glViewport(0, 0, screenWidth, screenHeight); 632 GLES20.glViewport(0, 0, screenWidth, screenHeight);
636 GLES20.glClear(GLES20.GL_COLOR_BUFFER_BIT); 633 GLES20.glClear(GLES20.GL_COLOR_BUFFER_BIT);
637 synchronized (yuvImageRenderers) { 634 synchronized (yuvImageRenderers) {
638 for (YuvImageRenderer yuvImageRenderer : yuvImageRenderers) { 635 for (YuvImageRenderer yuvImageRenderer : yuvImageRenderers) {
639 yuvImageRenderer.draw(drawer); 636 yuvImageRenderer.draw(drawer);
640 } 637 }
641 } 638 }
642 } 639 }
643 640
644 } 641 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698