Commit 3dc78697 authored by Mueller-Trapet's avatar Mueller-Trapet

Merge branch 'master' of https://git.rwth-aachen.de/ita/toolbox

parents 2382f5ad 9a3b2ff8
......@@ -120,7 +120,7 @@ end
datumDerMessung = datestr(x(1).datenum, 'dd.mm.yyyy');
% TODO: in GUI auswhlen
protocolPath = [ita_toolbox_path filesep 'applications' filesep 'Kundt' filesep 'Protocol' filesep];
protocolPath = [ita_toolbox_path filesep 'applications' filesep 'Measurement' filesep 'ImpedanceTube' filesep 'Protocol' filesep];
if strcmpi(protocolLanguage, 'german')
templateFileName = [protocolPath 'KundtGermanTemplate.tex'];
......
......@@ -10,8 +10,7 @@ function varargout = surf(this, varargin)
% [input,sArgs] = ita_parse_arguments(sArgs,varargin);
numArgIn = nargin;
titleString = [];
% check if SH coefs are given
if numel(varargin{1}) > 0 &&...
......@@ -25,7 +24,6 @@ if numel(varargin{1}) > 0 &&...
nSHGrid = size(this.Y,2);
nSHData = size(varargin{1}(:),1);
if nSHGrid ~= nSHData
% error('the spherical harmonics dimensions don''t fit');
% TODO make autofit
if nSHGrid > nSHData
varargin{1} = [varargin{1}(:); zeros(nSHGrid - nSHData,1)];
......@@ -49,7 +47,7 @@ end
hFig = {surf@itaCoordinates(this, varargin{:})};
% set title
if numel(titleString)
if ~isempty(titleString)
title(titleString);
end
......
classdef itaVA < handle
%ITAVA Remote interface for VA real-time auralization servers
%ITAVA Remote network interface to VA (Virtual Acoustics), the real-time
%auralization software made by ITA.
%
% This class realizes a remote connection to a VA real-time
% auralization server and implements the full VA core interface
% in Matlab. This way you connect to an auralization server
% and control all of its features to perform a real-time
% auralization. In order to get understand to the concepts behind VA
% please refer to the VA documentation.
% in Matlab. You can connect to to the server
% and control all of its features to perform real-time
% auralization, including live tracking if available.
% In order to get understand to the concepts behind VA
% please refer to the VA documentation or have a look at the example scripts.
%
% Usage & examples:
% See also: itaVA_example_simple, itaVA_example_tracked_listener,
% itaVA_example_generic_path_renderer, itaVA_example_random_numbers
%
% Quick usage:
%
% - Create an interface and connect to the server running on the
% same computer (localhost)
%
% va = itaVA('localhost');
% va = itaVA;
% va.connect;
%
% If no error occurs, you can then use the interface to work with
% the VA server. Best practice is to reset it first:
%
% va.reset
% the VA server.
%
% Then you can call other methods. For instance create a sound
% Now, you can call other methods. For instance create a sound
% source:
%
% sourceID = va.createSoundSource('Virtual sound source')
% sourceID = va.createSoundSource( 'My Matlab virtual sound source' )
%
% When everything is done, do not forget to close the connection.
% You can call disconnect on the instance or simply clear it:
%
% clear va
%
% - You can find more examples in the demo files
%
% Questions? Contact the author: Frank.Wefers@akustik.rwth-aachen.de
%
% Otherwise => Enjoy!
%
properties(Hidden = true, Access = private)
handle = int32(0); % Connection handle
% Connection defaults
DEFAULT_SERVER_PORT = 12340;
end
methods(Static)
function [ ok ] = check_for_mex_file()
% Checks if VAMatlab executable can be found.
if ~exist( 'VAMatlab', 'file' )
disp( 'Matlab binding for VA not complete (missing VAMatlab executable).' )
% file dialog
itaVA_setup()
% Re-check
ok = exist( 'VAMatlab', 'file' ) > 0;
else
ok = true;
end
end
function [version] = getVersion()
% Return the version of the VA Matlab interface
%
......@@ -55,6 +70,11 @@ classdef itaVA < handle
% Return values:
%
% version [string] Version string
if ~itaVA.check_for_mex_file()
error( 'Matlab binding for VA requires VAMatlab executable.' );
end
version = VAMatlab('getVersion');
end
......@@ -74,6 +94,11 @@ classdef itaVA < handle
% - If you do not want any messages from the extension
% set the verbose mode to 'quiet'
%
if ~itaVA.check_for_mex_file()
error( 'Matlab binding for VA requires VAMatlab executable.' );
end
VAMatlab('setVerboseMode', mode);
end
end
......@@ -100,6 +125,10 @@ classdef itaVA < handle
% core = itaVA('localhost:12340');
%
if ~itaVA.check_for_mex_file()
error( 'Matlab binding for VA requires VAMatlab executable.' );
end
if (nargin > 0)
this.connect(addressstring)
end
......
......@@ -2,7 +2,7 @@
va = itaVA( 'localhost' )
va.reset();
X = va.createAudiofileSignalSource( '$(VADataDir)\Audiofiles\Bauer.wav' );
X = va.createAudiofileSignalSource( 'Audiofiles/Bauer.wav' );
va.setAudiofileSignalSourcePlaybackAction( X, 'play' );
va.setAudiofileSignalSourceIsLooping( X, true );
S = va.createSoundSource( 'itaVA_Source' );
......@@ -14,7 +14,7 @@ mMods = va.enumerateModules;
modname = 'none';
for n = size( mMods, 1 )
if strcmp( 'GenericPath', mMods(n).name(1:11) )
if strcmp( 'PrototypeGenericPath', mMods(n).name( 1:size( 'PrototypeGenericPath', 2 ) ) )
modname = mMods(n).name;
break; % use first one found
end
......
This diff is collapsed.
if ~exist( 'VAServer.exe', 'file' )
itaVA_setup
end
[ basepath, basename, ext ]= fileparts( which( 'VAServer.exe') );
[ va_basepath, ~, ~ ]= fileparts( basepath );
conf_path1 = fullfile( 'conf', 'VACore.ini' );
conf_path2 = fullfile( pwd, 'MyVACore.ini' ); % also absolute path possible
va_args = [ 'localhost:12340 ' conf_path1 ];
os_call = [ which( 'VAServer.exe') ' ' va_args ' &' ];
return_to_dir = pwd;
cd( va_basepath );
[ status, cmdout ] = system( os_call );
cd( return_to_dir );
% After connect, also add the folder with your data like this
% va.add
\ No newline at end of file
......@@ -74,7 +74,7 @@ else
if ~isempty(sArgs.radius)
r = sArgs.radius;
else
r = data;
r = data.';
end
isComplex = ~all(isreal(r));% & min(r(:)) < 0;
if isComplex
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment