not able to play video using parallel processing ,

2 次查看(过去 30 天)
Hello
parfor i = 1:2
if i == 1
Function_I
else
Function_II
end
end
disp('completed');
function [outputArg1] = Function_I(inputArg1)
%UNTITLED4 Summary of this function goes here
% Detailed explanation goes here
inputArg1=1;
breakcond=0;
save breakcond breakcond;
videoFReader = vision.VideoFileReader('viplanedeparture.mp4');
vidObj = VideoReader('viplanedeparture.mp4');
figure;
videoPlayer = vision.VideoPlayer;
while ~isDone(videoFReader)
videoFrame = step(videoFReader);
% imshow(videoFrame);
step(videoPlayer, videoFrame);
pause(0.1);
end
release(videoPlayer);
release(videoFReader);
outputArg1=1;
breakcond=1;
save breakcond breakcond;
end
Video Player requires Java and a display to run. This functionality is not supported
under the -nojvm or -nodisplay startup option.
Error in matlabshared.scopes.UnifiedSystemScope/launchScope (line 137)
hFramework = uiscopes.new(hScopeCfg);
Error in matlabshared.scopes.UnifiedSystemScope (line 23)
launchScope(obj);
Error in vision.VideoPlayer
Error in Function_I (line 10)
videoPlayer = vision.VideoPlayer;
Error in tetspar1 (line 2)
parfor i = 1:2
  1 个评论
Raymond Norris
Raymond Norris 2021-3-10
I'm unclear what your question/comment is. Your code requires Java, so why are you passing the -nojvm switch to MATLAB?

请先登录,再进行评论。

回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Code Generation, GPU, and Third-Party Support 的更多信息

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by