modules/video_coding refactorings
The main purpose was the interface-> include rename, but other files were also moved, eliminating the "main" dir. To avoid breaking downstream, the "interface" directories were copied into a new "video_coding/include" dir. The old headers got pragma warnings added about deprecation (a very short deprecation since I plan to remove them as soon downstream is updated). Other files also moved: video_coding/main/source -> video_coding video_coding/main/test -> video_coding/test BUG=webrtc:5095 TESTED=Passing compile-trybots with --clobber flag: git cl try --clobber --bot=win_compile_rel --bot=linux_compile_rel --bot=android_compile_rel --bot=mac_compile_rel --bot=ios_rel --bot=linux_gn_rel --bot=win_x64_gn_rel --bot=mac_x64_gn_rel --bot=android_gn_rel -m tryserver.webrtc R=stefan@webrtc.org, tommi@webrtc.org Review URL: https://codereview.webrtc.org/1417283007 . Cr-Commit-Position: refs/heads/master@{#10694}
This commit is contained in:
62
webrtc/modules/video_coding/test/plotTimingTest.m
Normal file
62
webrtc/modules/video_coding/test/plotTimingTest.m
Normal file
@ -0,0 +1,62 @@
|
||||
function plotTimingTest(filename)
|
||||
fid=fopen(filename);
|
||||
|
||||
%DEBUG ; ( 9:53:33:859 | 0) VIDEO:-1 ; 7132; Stochastic test 1
|
||||
%DEBUG ; ( 9:53:33:859 | 0) VIDEO CODING:-1 ; 7132; Frame decoded: timeStamp=3000 decTime=10 at 10012
|
||||
%DEBUG ; ( 9:53:33:859 | 0) VIDEO:-1 ; 7132; timeStamp=3000 clock=10037 maxWaitTime=0
|
||||
%DEBUG ; ( 9:53:33:859 | 0) VIDEO:-1 ; 7132; timeStampMs=33 renderTime=54
|
||||
line = fgetl(fid);
|
||||
decTime = [];
|
||||
waitTime = [];
|
||||
renderTime = [];
|
||||
foundStart = 0;
|
||||
testName = 'Stochastic test 1';
|
||||
while ischar(line)
|
||||
if length(line) == 0
|
||||
line = fgetl(fid);
|
||||
continue;
|
||||
end
|
||||
lineOrig = line;
|
||||
line = line(72:end);
|
||||
if ~foundStart
|
||||
if strncmp(line, testName, length(testName))
|
||||
foundStart = 1;
|
||||
end
|
||||
line = fgetl(fid);
|
||||
continue;
|
||||
end
|
||||
[p, count] = sscanf(line, 'Frame decoded: timeStamp=%lu decTime=%d maxDecTime=%d, at %lu');
|
||||
if count == 4
|
||||
decTime = [decTime; p'];
|
||||
line = fgetl(fid);
|
||||
continue;
|
||||
end
|
||||
[p, count] = sscanf(line, 'timeStamp=%u clock=%u maxWaitTime=%u');
|
||||
if count == 3
|
||||
waitTime = [waitTime; p'];
|
||||
line = fgetl(fid);
|
||||
continue;
|
||||
end
|
||||
[p, count] = sscanf(line, 'timeStamp=%u renderTime=%u');
|
||||
if count == 2
|
||||
renderTime = [renderTime; p'];
|
||||
line = fgetl(fid);
|
||||
continue;
|
||||
end
|
||||
line = fgetl(fid);
|
||||
end
|
||||
fclose(fid);
|
||||
|
||||
% Compensate for wrap arounds and start counting from zero.
|
||||
timeStamps = waitTime(:, 1);
|
||||
tsDiff = diff(timeStamps);
|
||||
wrapIdx = find(tsDiff < 0);
|
||||
timeStamps(wrapIdx+1:end) = hex2dec('ffffffff') + timeStamps(wrapIdx+1:end);
|
||||
timeStamps = timeStamps - timeStamps(1);
|
||||
|
||||
figure;
|
||||
hold on;
|
||||
plot(timeStamps, decTime(:, 2), 'r');
|
||||
plot(timeStamps, waitTime(:, 3), 'g');
|
||||
plot(timeStamps(2:end), diff(renderTime(:, 2)), 'b');
|
||||
legend('Decode time', 'Max wait time', 'Render time diff');
|
||||
Reference in New Issue
Block a user