Skip to content
Snippets Groups Projects
Commit 82c72a34 authored by Ben Heasly's avatar Ben Heasly
Browse files

rtbCheckNativeDependencies avoid extra checks

parent fd9a4062
No related branches found
No related tags found
No related merge requests found
......@@ -27,12 +27,30 @@ openExr = checkSystem('OpenEXR', ...
'It looks like the OpenEXR library is not installed. Please visit http://www.openexr.com/. You might also try "sudo apt-get install openexr" or similar.');
%% OpenEXR is required.
if 0 ~= openExr.status
status = openExr.status;
result = openExr.result;
advice = openExr.advice;
return;
end
%% Check for Docker, the preferred way to obtain renderers.
docker = checkSystem('Docker', ...
'docker ps', ...
'It looks like Docker is not installed. Please visit https://github.com/RenderToolbox/RenderToolbox4/wiki/Docker.');
%% Docker can cover both renderers.
if 0 == docker.status
status = 0;
result = 'Local dependencies were found.';
advice = '';
return;
end
%% Check for a local installation of the Mitsuba renderer.
mitsuba = checkSystem('Mitsuba', ...
'which mitsuba', ...
......@@ -45,24 +63,6 @@ pbrt = checkSystem('PBRT', ...
'It looks like PBRT is not installed. Please visit https://github.com/ydnality/pbrt-v2-spectral. Or, consider installing Docker so that RenderToolbox can get PBRT for you.');
%% OpenEXR is required.
if 0 ~= openExr.status
status = openExr.status;
result = openExr.result;
advice = openExr.advice;
return;
end
%% Docker can cover both renderers.
if 0 == docker.status
status = 0;
result = 'OK.';
advice = '';
return;
end
%% Check for both renderers.
if 0 ~= mitsuba.status
status = mitsuba.status;
......@@ -81,7 +81,7 @@ end
%% Looks good from here.
status = 0;
result = 'OK.';
result = 'Local dependencies were found.';
advice = '';
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment