OLD | NEW |
1 /* | 1 /* |
2 * libjingle | 2 * libjingle |
3 * Copyright 2013 Google Inc. | 3 * Copyright 2013 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 118 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
129 | 129 |
130 public synchronized void expectFramesDelivered(int count) { | 130 public synchronized void expectFramesDelivered(int count) { |
131 assertFalse(RENDER_TO_GUI); | 131 assertFalse(RENDER_TO_GUI); |
132 expectedFramesDelivered += count; | 132 expectedFramesDelivered += count; |
133 } | 133 } |
134 | 134 |
135 @Override | 135 @Override |
136 public synchronized void renderFrame(VideoRenderer.I420Frame frame) { | 136 public synchronized void renderFrame(VideoRenderer.I420Frame frame) { |
137 setSize(frame.rotatedWidth(), frame.rotatedHeight()); | 137 setSize(frame.rotatedWidth(), frame.rotatedHeight()); |
138 --expectedFramesDelivered; | 138 --expectedFramesDelivered; |
| 139 VideoRenderer.renderFrameDone(frame); |
139 } | 140 } |
140 | 141 |
141 public synchronized void expectSignalingChange(SignalingState newState) { | 142 public synchronized void expectSignalingChange(SignalingState newState) { |
142 expectedSignalingChanges.add(newState); | 143 expectedSignalingChanges.add(newState); |
143 } | 144 } |
144 | 145 |
145 @Override | 146 @Override |
146 public synchronized void onSignalingChange(SignalingState newState) { | 147 public synchronized void onSignalingChange(SignalingState newState) { |
147 assertEquals(expectedSignalingChanges.removeFirst(), newState); | 148 assertEquals(expectedSignalingChanges.removeFirst(), newState); |
148 } | 149 } |
(...skipping 594 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
743 TreeSet<String> threads = new TreeSet<String>(); | 744 TreeSet<String> threads = new TreeSet<String>(); |
744 // This pokes at /proc instead of using the Java APIs because we're also | 745 // This pokes at /proc instead of using the Java APIs because we're also |
745 // looking for libjingle/webrtc native threads, most of which won't have | 746 // looking for libjingle/webrtc native threads, most of which won't have |
746 // attached to the JVM. | 747 // attached to the JVM. |
747 for (String threadId : (new File("/proc/self/task")).list()) { | 748 for (String threadId : (new File("/proc/self/task")).list()) { |
748 threads.add(threadId); | 749 threads.add(threadId); |
749 } | 750 } |
750 return threads; | 751 return threads; |
751 } | 752 } |
752 } | 753 } |
OLD | NEW |