0001 function [obj] = brain_file_maker_view3d(obj, brain_file, area_file, act_file)
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012
0013
0014
0015
0016
0017
0018
0019
0020
0021
0022 if ~exist('obj', 'var'), error('obj is a required parameter.'); end
0023 if ~exist('brain_file', 'var') || exist(brain_file, 'file') ~= 2
0024 error('brain_file is a required parameter.');
0025 end
0026 if ~exist('area_file', 'var')
0027 error('area_file is a required parameter.');
0028 end
0029 if ~exist('act_file', 'var')
0030 error('act_file is a required parameter.');
0031 end
0032
0033
0034
0035
0036 command = ['job_view_cortex_init(''', brain_file, ''''];
0037 if exist(area_file, 'file')
0038 command = [command ', ''--area'', ''' area_file, ''''];
0039 end
0040 if exist(act_file, 'file')
0041 command = [command ', ''--act'', ''', act_file, ''''];
0042 end
0043 command = [command, ');'];
0044
0045 eval(command);
0046 obj.view3d = gcf;
0047
0048
0049
0050
0051 if nargout ~= 1
0052 error('function caller should receive obj.');
0053 end