Merged with trunk
git-svn-id: svn://localhost/ardour2/branches/midi@628 d708f5d6-7413-0410-9779-e7cbd77b26cf
This commit is contained in:
parent
6a1f2919f2
commit
13532c8500
|
@ -1,3 +1 @@
|
|||
Last merged with trunk revision:
|
||||
|
||||
610
|
||||
Last merged with trunk revision: 627
|
||||
|
|
42
SConstruct
42
SConstruct
|
@ -14,7 +14,7 @@ import SCons.Node.FS
|
|||
SConsignFile()
|
||||
EnsureSConsVersion(0, 96)
|
||||
|
||||
version = '2.0beta1'
|
||||
version = '2.0beta2'
|
||||
|
||||
subst_dict = { }
|
||||
|
||||
|
@ -25,20 +25,20 @@ subst_dict = { }
|
|||
opts = Options('scache.conf')
|
||||
opts.AddOptions(
|
||||
('ARCH', 'Set architecture-specific compilation flags by hand (all flags as 1 argument)',''),
|
||||
BoolOption('SYSLIBS', 'USE AT YOUR OWN RISK: CANCELS ALL SUPPORT FROM ARDOUR AUTHORS: Use existing system versions of various libraries instead of internal ones', 0),
|
||||
BoolOption('COREAUDIO', 'Compile with Apple\'s CoreAudio library', 0),
|
||||
BoolOption('DEBUG', 'Set to build with debugging information and no optimizations', 0),
|
||||
PathOption('DESTDIR', 'Set the intermediate install "prefix"', '/'),
|
||||
EnumOption('DIST_TARGET', 'Build target for cross compiling packagers', 'auto', allowed_values=('auto', 'i386', 'i686', 'x86_64', 'powerpc', 'tiger', 'panther', 'none' ), ignorecase=2),
|
||||
BoolOption('DMALLOC', 'Compile and link using the dmalloc library', 0),
|
||||
BoolOption('FFT_ANALYSIS', 'Include FFT analysis window', 0),
|
||||
BoolOption('FPU_OPTIMIZATION', 'Build runtime checked assembler code', 1),
|
||||
BoolOption('LIBLO', 'Compile with support for liblo library', 1),
|
||||
BoolOption('NLS', 'Set to turn on i18n support', 1),
|
||||
PathOption('PREFIX', 'Set the install "prefix"', '/usr/local'),
|
||||
BoolOption('VST', 'Compile with support for VST', 0),
|
||||
BoolOption('VERSIONED', 'Add version information to ardour/gtk executable name inside the build directory', 0),
|
||||
EnumOption('DIST_TARGET', 'Build target for cross compiling packagers', 'auto', allowed_values=('auto', 'i386', 'i686', 'x86_64', 'powerpc', 'tiger', 'panther', 'none' ), ignorecase=2),
|
||||
BoolOption('FPU_OPTIMIZATION', 'Build runtime checked assembler code', 1),
|
||||
BoolOption('FFT_ANALYSIS', 'Include FFT analysis window', 0),
|
||||
BoolOption('SURFACES', 'Build support for control surfaces', 0),
|
||||
BoolOption('DMALLOC', 'Compile and link using the dmalloc library', 0),
|
||||
BoolOption('LIBLO', 'Compile with support for liblo library', 1),
|
||||
BoolOption('COREAUDIO', 'Compile with Apple\'s CoreAudio library -- UNSTABLE', 0)
|
||||
BoolOption('SYSLIBS', 'USE AT YOUR OWN RISK: CANCELS ALL SUPPORT FROM ARDOUR AUTHORS: Use existing system versions of various libraries instead of internal ones', 0),
|
||||
BoolOption('VERSIONED', 'Add version information to ardour/gtk executable name inside the build directory', 0),
|
||||
BoolOption('VST', 'Compile with support for VST', 0)
|
||||
)
|
||||
|
||||
#----------------------------------------------------------------------
|
||||
|
@ -58,8 +58,8 @@ class LibraryInfo(Environment):
|
|||
self.Append (LINKFLAGS = other.get('LINKFLAGS', []))
|
||||
self.Replace(LIBPATH = list(Set(self.get('LIBPATH', []))))
|
||||
self.Replace(CPPPATH = list(Set(self.get('CPPPATH',[]))))
|
||||
#doing LINKFLAGS breaks -framework
|
||||
#doing LIBS break link order dependency
|
||||
#doing LINKFLAGS breaks -framework
|
||||
#doing LIBS break link order dependency
|
||||
|
||||
|
||||
env = LibraryInfo (options = opts,
|
||||
|
@ -408,10 +408,6 @@ libraries['pbd3'] = LibraryInfo (LIBS='pbd', LIBPATH='#libs/pbd3', CPPPATH='#
|
|||
libraries['gtkmm2ext'] = LibraryInfo (LIBS='gtkmm2ext', LIBPATH='#libs/gtkmm2ext', CPPPATH='#libs/gtkmm2ext')
|
||||
#libraries['cassowary'] = LibraryInfo(LIBS='cassowary', LIBPATH='#libs/cassowary', CPPPATH='#libs/cassowary')
|
||||
|
||||
libraries['fst'] = LibraryInfo()
|
||||
if env['VST']:
|
||||
libraries['fst'].ParseConfig('pkg-config --cflags --libs libfst')
|
||||
|
||||
#
|
||||
# Check for libusb
|
||||
|
||||
|
@ -539,6 +535,9 @@ if env['SYSLIBS']:
|
|||
'libs/ardour'
|
||||
]
|
||||
|
||||
if env['VST']:
|
||||
subdirs = ['libs/fst'] + subdirs + ['vst']
|
||||
|
||||
gtk_subdirs = [
|
||||
# 'libs/flowcanvas',
|
||||
'libs/gtkmm2ext',
|
||||
|
@ -592,6 +591,9 @@ else:
|
|||
'libs/ardour'
|
||||
]
|
||||
|
||||
if env['VST']:
|
||||
subdirs = ['libs/fst'] + subdirs + ['vst']
|
||||
|
||||
gtk_subdirs = [
|
||||
'libs/glibmm2',
|
||||
'libs/gtkmm2/pango',
|
||||
|
@ -794,10 +796,12 @@ if env['DEBUG'] == 1:
|
|||
else:
|
||||
env.Append(CCFLAGS=" ".join (opt_flags))
|
||||
|
||||
env.Append(CCFLAGS="-Wall")
|
||||
#
|
||||
# warnings flags
|
||||
#
|
||||
|
||||
if env['VST']:
|
||||
env.Append(CCFLAGS="-DVST_SUPPORT")
|
||||
env.Append(CCFLAGS="-Wall")
|
||||
env.Append(CXXFLAGS="-Woverloaded-virtual")
|
||||
|
||||
if env['LIBLO']:
|
||||
env.Append(CCFLAGS="-DHAVE_LIBLO")
|
||||
|
|
|
@ -58,9 +58,6 @@ if gtkardour['FFT_ANALYSIS']:
|
|||
gtkardour.Merge ([libraries['fftw3f']])
|
||||
gtkardour.Append(CCFLAGS='-DFFT_ANALYSIS')
|
||||
|
||||
if gtkardour['VST']:
|
||||
gtkardour.Merge ([ libraries['fst']])
|
||||
|
||||
skipped_files=Split("""
|
||||
connection_editor.cc
|
||||
""")
|
||||
|
@ -203,15 +200,16 @@ itest.cc
|
|||
""")
|
||||
|
||||
extra_sources = []
|
||||
|
||||
vst_files = [ 'vst_pluginui.cc' ]
|
||||
|
||||
if env['VST']:
|
||||
extra_sources += vst_files
|
||||
|
||||
extra_sources += vst_files
|
||||
gtkardour.Append (CCFLAGS="-DVST_SUPPORT", CPPPATH="#libs/fst")
|
||||
|
||||
if env['FFT_ANALYSIS']:
|
||||
extra_sources += fft_analysis_files
|
||||
|
||||
|
||||
intl_files += extra_sources
|
||||
|
||||
gtkardour.Append(CCFLAGS="-D_REENTRANT -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE")
|
||||
|
@ -226,6 +224,8 @@ gtkardour.VersionBuild(['version.cc','version.h'], 'SConscript')
|
|||
executable = 'ardour.bin'
|
||||
|
||||
ardour = gtkardour.Program(target = executable, source = gtkardour_files + extra_sources)
|
||||
ardourlib = gtkardour.SharedLibrary(target = 'ardourgtk', source = gtkardour_files + extra_sources)
|
||||
|
||||
mtest = gtkardour.Program(target = 'mtest', source = mtest_files)
|
||||
itest = gtkardour.Program(target = 'itest', source = itest_files)
|
||||
|
||||
|
@ -235,21 +235,28 @@ my_subst_dict['%INSTALL_PREFIX%'] = install_prefix
|
|||
ardoursh = env.SubstInFile ('ardour.sh','ardour.sh.in', SUBST_DICT = my_subst_dict);
|
||||
env.AddPostAction (ardoursh, Chmod ('$TARGET', 0755))
|
||||
|
||||
Default(ardour)
|
||||
if env['VST']:
|
||||
Default(ardourlib)
|
||||
# the library - into the library dir
|
||||
env.Alias('install', env.Install(os.path.join(install_prefix, 'lib/ardour2'), ardourlib))
|
||||
else:
|
||||
|
||||
if env['VERSIONED']:
|
||||
Default (env.VersionedExecutable ('tagged_executable', ardour))
|
||||
if env['VERSIONED']:
|
||||
Default (env.VersionedExecutable ('tagged_executable', ardour))
|
||||
else:
|
||||
Default(ardour)
|
||||
|
||||
#install
|
||||
|
||||
# the executable - into the library dir
|
||||
env.Alias('install', env.Install(os.path.join(install_prefix, 'lib/ardour2'), ardour))
|
||||
# the script - into the bin dir
|
||||
env.Alias('install', env.InstallAs(os.path.join(install_prefix, 'bin')+'/ardour2', ardoursh))
|
||||
|
||||
if env['NLS']:
|
||||
Export('gtkardour', 'intl_files')
|
||||
SConscript ('po/SConscript')
|
||||
Export('gtkardour', 'intl_files')
|
||||
SConscript ('po/SConscript')
|
||||
|
||||
#install
|
||||
|
||||
# the executable - into the library dir
|
||||
env.Alias('install', env.Install(os.path.join(install_prefix, 'lib/ardour2'), ardour))
|
||||
# the script - into the bin dir
|
||||
env.Alias('install', env.InstallAs(os.path.join(install_prefix, 'bin')+'/ardour2', ardoursh))
|
||||
# configuration files
|
||||
env.Alias('install', env.Install(os.path.join(config_prefix, 'ardour2'), 'ardour2_ui.rc'))
|
||||
env.Alias('install', env.Install(os.path.join(config_prefix, 'ardour2'), 'ardour.menus'))
|
||||
|
@ -259,6 +266,7 @@ env.Alias('install', env.Install(os.path.join(config_prefix, 'ardour2'), 'ardour
|
|||
env.Alias('install', env.Install(os.path.join(install_prefix, 'share/ardour2'), 'splash.ppm'))
|
||||
env.Alias('install', env.Install(os.path.join(install_prefix, 'share/ardour2/pixmaps'), pixmap_files))
|
||||
|
||||
|
||||
#dist
|
||||
env.Alias ('tarball', env.Distribute (env['DISTTREE'],
|
||||
[ 'SConscript',
|
||||
|
|
|
@ -28,6 +28,7 @@
|
|||
|
||||
#include <pbd/xml++.h>
|
||||
#include "prompter.h"
|
||||
#include "selectable.h"
|
||||
|
||||
namespace ARDOUR {
|
||||
class Session;
|
||||
|
@ -37,7 +38,7 @@ namespace ARDOUR {
|
|||
* AxisView defines the abstract base class for time-axis trackviews and routes.
|
||||
*
|
||||
*/
|
||||
class AxisView : public virtual sigc::trackable
|
||||
class AxisView : public virtual Selectable
|
||||
{
|
||||
public:
|
||||
/**
|
||||
|
@ -51,12 +52,6 @@ class AxisView : public virtual sigc::trackable
|
|||
|
||||
virtual string name() const = 0;
|
||||
|
||||
virtual void set_selected (bool yn) {
|
||||
if (yn != _selected) {
|
||||
_selected = yn;
|
||||
}
|
||||
}
|
||||
|
||||
virtual bool marked_for_display() const { return _marked_for_display; }
|
||||
|
||||
virtual void set_marked_for_display (bool yn) {
|
||||
|
@ -65,7 +60,6 @@ class AxisView : public virtual sigc::trackable
|
|||
}
|
||||
}
|
||||
|
||||
virtual bool selected() const { return _selected; }
|
||||
sigc::signal<void> Hiding;
|
||||
sigc::signal<void> GoingAway;
|
||||
|
||||
|
|
|
@ -389,7 +389,11 @@ gnome_canvas_waveview_ensure_cache (GnomeCanvasWaveView *waveview, gulong start_
|
|||
/* but make sure it doesn't extend beyond the end of the source material */
|
||||
|
||||
rf3 = (gulong) (waveview->sourcefile_length_function (waveview->data_src, waveview->samples_per_unit)) + 1;
|
||||
rf3 -= new_cache_start;
|
||||
if (rf3 < new_cache_start) {
|
||||
rf3 = 0;
|
||||
} else {
|
||||
rf3 -= new_cache_start;
|
||||
}
|
||||
|
||||
#if DEBUG_CACHE
|
||||
fprintf (stderr, "\n\nAVAILABLE FRAMES = %lu of %lu, start = %lu, sstart = %lu, cstart = %lu\n",
|
||||
|
@ -405,8 +409,8 @@ gnome_canvas_waveview_ensure_cache (GnomeCanvasWaveView *waveview, gulong start_
|
|||
|
||||
#if DEBUG_CACHE
|
||||
fprintf (stderr, "new cache = %lu - %lu\n", new_cache_start, new_cache_end);
|
||||
fprintf(stderr,"required_cach_entries = %lu, samples_per_unit = %f\n",
|
||||
required_cache_entries,waveview->samples_per_unit);
|
||||
fprintf(stderr,"required_cach_entries = %lu, samples_per_unit = %f req frames = %lu\n",
|
||||
required_cache_entries,waveview->samples_per_unit, required_frames);
|
||||
#endif
|
||||
|
||||
if (required_cache_entries > cache->allocated) {
|
||||
|
@ -514,8 +518,8 @@ gnome_canvas_waveview_ensure_cache (GnomeCanvasWaveView *waveview, gulong start_
|
|||
|
||||
// fprintf(stderr,"length == %lu\n",waveview->length_function (waveview->data_src));
|
||||
// required_frames = MIN (waveview->length_function (waveview->data_src) - new_cache_start, required_frames);
|
||||
|
||||
npeaks = (gulong) floor (required_frames / waveview->samples_per_unit);
|
||||
npeaks = MAX (1, npeaks);
|
||||
required_frames = npeaks * waveview->samples_per_unit;
|
||||
|
||||
#if DEBUG_CACHE
|
||||
|
@ -532,11 +536,15 @@ gnome_canvas_waveview_ensure_cache (GnomeCanvasWaveView *waveview, gulong start_
|
|||
// start_sample, end_sample);
|
||||
#endif
|
||||
|
||||
waveview->peak_function (waveview->data_src, npeaks, new_cache_start, required_frames, cache->data + offset, waveview->channel,waveview->samples_per_unit);
|
||||
if (required_frames) {
|
||||
waveview->peak_function (waveview->data_src, npeaks, new_cache_start, required_frames, cache->data + offset, waveview->channel,waveview->samples_per_unit);
|
||||
|
||||
/* take into account any copied peaks */
|
||||
|
||||
npeaks += copied;
|
||||
/* take into account any copied peaks */
|
||||
|
||||
npeaks += copied;
|
||||
} else {
|
||||
npeaks = copied;
|
||||
}
|
||||
|
||||
if (npeaks < cache->allocated) {
|
||||
#if DEBUG_CACHE
|
||||
|
|
|
@ -50,7 +50,7 @@ CrossfadeView::CrossfadeView (ArdourCanvas::Group *parent,
|
|||
AudioRegionView& rview)
|
||||
|
||||
|
||||
: TimeAxisViewItem ("xf.name()", *parent, tv, spu, basic_color, xf.position(),
|
||||
: TimeAxisViewItem ("xfade" /*xf.name()*/, *parent, tv, spu, basic_color, xf.position(),
|
||||
xf.overlap_length(), TimeAxisViewItem::Visibility (TimeAxisViewItem::ShowFrame)),
|
||||
crossfade (xf),
|
||||
left_view (lview),
|
||||
|
@ -91,13 +91,6 @@ CrossfadeView::~CrossfadeView ()
|
|||
GoingAway (this) ; /* EMIT_SIGNAL */
|
||||
}
|
||||
|
||||
std::string
|
||||
CrossfadeView::get_item_name ()
|
||||
{
|
||||
return "xfade";
|
||||
// return crossfade.name();
|
||||
}
|
||||
|
||||
void
|
||||
CrossfadeView::reset_width_dependent_items (double pixel_width)
|
||||
{
|
||||
|
|
|
@ -46,7 +46,6 @@ struct CrossfadeView : public TimeAxisViewItem
|
|||
AudioRegionView& left_view; // and these too
|
||||
AudioRegionView& right_view;
|
||||
|
||||
std::string get_item_name();
|
||||
void set_height (double);
|
||||
|
||||
bool valid() const { return _valid; }
|
||||
|
|
|
@ -195,7 +195,7 @@ Editor::set_mouse_mode (MouseMode m, bool force)
|
|||
*/
|
||||
|
||||
for (TrackSelection::iterator i = selection->tracks.begin(); i != selection->tracks.end(); ++i) {
|
||||
if ((*i)->selected()) {
|
||||
if ((*i)->get_selected()) {
|
||||
(*i)->show_selection (selection->time);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1091,7 +1091,7 @@ ImageFrameSocketHandler::handle_item_selected(const char* msg)
|
|||
}
|
||||
else
|
||||
{
|
||||
ifv->set_selected(true, this) ;
|
||||
ifv->set_selected(true) ;
|
||||
ifta->get_view()->set_selected_imageframe_view(iftag, ifv) ;
|
||||
|
||||
thePublicEditor.scroll_timeaxis_to_imageframe_item(ifv) ;
|
||||
|
|
|
@ -365,11 +365,11 @@ ImageFrameTimeAxisView::set_selected_imageframe_view(ImageFrameTimeAxisGroup* if
|
|||
|
||||
if(selected_imageframe_view)
|
||||
{
|
||||
selected_imageframe_view->set_selected(false, this) ;
|
||||
selected_imageframe_view->set_selected(false) ;
|
||||
}
|
||||
|
||||
selected_imageframe_view = ifv ;
|
||||
selected_imageframe_view->set_selected(true, this) ;
|
||||
selected_imageframe_view->set_selected(true) ;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -386,7 +386,7 @@ ImageFrameTimeAxisView::clear_selected_imageframe_item(bool clear_group)
|
|||
|
||||
if(selected_imageframe_view)
|
||||
{
|
||||
selected_imageframe_view->set_selected(false, this) ;
|
||||
selected_imageframe_view->set_selected(false) ;
|
||||
}
|
||||
selected_imageframe_view = 0 ;
|
||||
}
|
||||
|
|
|
@ -172,16 +172,15 @@ delete imageframe;
|
|||
* @return true if the position change was a success, false otherwise
|
||||
*/
|
||||
bool
|
||||
ImageFrameView::set_position(jack_nframes_t pos, void* src)
|
||||
ImageFrameView::set_position(jack_nframes_t pos, void* src, double* delta)
|
||||
{
|
||||
jack_nframes_t old_pos = frame_position ;
|
||||
|
||||
// do the standard stuff
|
||||
bool ret = TimeAxisViewItem::set_position(pos, src) ;
|
||||
bool ret = TimeAxisViewItem::set_position(pos, src, delta) ;
|
||||
|
||||
// everything went ok with the standard stuff?
|
||||
if(ret)
|
||||
{
|
||||
if (ret) {
|
||||
/* move each of our associated markers with this ImageFrameView */
|
||||
for (MarkerViewList::iterator i = marker_view_list.begin(); i != marker_view_list.end(); ++i)
|
||||
{
|
||||
|
|
|
@ -91,7 +91,7 @@ class ImageFrameView : public TimeAxisViewItem
|
|||
* @param src the identity of the object that initiated the change
|
||||
* @return true if the position change was a success, false otherwise
|
||||
*/
|
||||
virtual bool set_position(jack_nframes_t pos, void* src) ;
|
||||
virtual bool set_position(jack_nframes_t pos, void* src, double* delta = 0) ;
|
||||
|
||||
/**
|
||||
* Sets the duration of this item
|
||||
|
|
|
@ -361,6 +361,7 @@ To create it from the command line, start ardour as \"ardour --new %1"), path)
|
|||
return true;
|
||||
}
|
||||
|
||||
|
||||
int
|
||||
main (int argc, char *argv[])
|
||||
{
|
||||
|
|
|
@ -125,7 +125,6 @@ MixerStrip::MixerStrip (Mixer_UI& mx, Session& sess, Route& rt, bool in_mixer)
|
|||
output_button.set_name ("MixerIOButton");
|
||||
output_label.set_name ("MixerIOButtonLabel");
|
||||
|
||||
|
||||
_route.meter_change.connect (mem_fun(*this, &MixerStrip::meter_changed));
|
||||
meter_point_button.add (meter_point_label);
|
||||
meter_point_button.set_name ("MixerStripMeterPreButton");
|
||||
|
|
|
@ -127,7 +127,7 @@ Panner2d::reset (uint32_t n_inputs)
|
|||
}
|
||||
|
||||
void
|
||||
Panner2d::on_size_allocate (Gtk::Allocation alloc)
|
||||
Panner2d::on_size_allocate (Gtk::Allocation& alloc)
|
||||
{
|
||||
width = alloc.get_width();
|
||||
height = alloc.get_height();
|
||||
|
|
|
@ -78,7 +78,7 @@ class Panner2d : public Gtk::DrawingArea
|
|||
bool on_button_press_event (GdkEventButton *);
|
||||
bool on_button_release_event (GdkEventButton *);
|
||||
bool on_motion_notify_event (GdkEventMotion *);
|
||||
void on_size_allocate (Gtk::Allocation alloc);
|
||||
void on_size_allocate (Gtk::Allocation& alloc);
|
||||
|
||||
private:
|
||||
struct Target {
|
||||
|
|
|
@ -53,8 +53,6 @@ class RedirectAutomationLine : public AutomationLine
|
|||
|
||||
void view_to_model_y (double&);
|
||||
void model_to_view_y (double&);
|
||||
void change_model (uint32_t, double x, double y);
|
||||
void change_model_range (uint32_t, uint32_t, double delta);
|
||||
};
|
||||
|
||||
#endif /* __ardour_gtk_region_gain_line_h__ */
|
||||
|
|
|
@ -1234,12 +1234,6 @@ AudioRegionView::set_waveform_shape (WaveformShape shape)
|
|||
}
|
||||
}
|
||||
|
||||
std::string
|
||||
AudioRegionView::get_item_name ()
|
||||
{
|
||||
return region.name();
|
||||
}
|
||||
|
||||
void
|
||||
AudioRegionView::move (double x_delta, double y_delta)
|
||||
{
|
||||
|
|
|
@ -63,7 +63,6 @@ class AudioRegionView : public TimeAxisViewItem
|
|||
bool is_valid() const { return valid; }
|
||||
void set_valid (bool yn) { valid = yn; }
|
||||
|
||||
std::string get_item_name();
|
||||
void set_height (double);
|
||||
void set_samples_per_unit (double);
|
||||
bool set_duration (jack_nframes_t, void*);
|
||||
|
|
|
@ -21,7 +21,9 @@
|
|||
#ifndef __ardour_gtk_selectable_h__
|
||||
#define __ardour_gtk_selectable_h__
|
||||
|
||||
class Selectable
|
||||
#include <sigc++/signal.h>
|
||||
|
||||
class Selectable : public virtual sigc::trackable
|
||||
{
|
||||
public:
|
||||
Selectable() {
|
||||
|
@ -30,10 +32,20 @@ class Selectable
|
|||
|
||||
virtual ~Selectable() {}
|
||||
|
||||
virtual void set_selected (bool) {
|
||||
_selected = true;
|
||||
virtual void set_selected (bool yn) {
|
||||
if (yn != _selected) {
|
||||
_selected = true;
|
||||
Selected (_selected); /* EMIT_SIGNAL */
|
||||
}
|
||||
}
|
||||
|
||||
bool get_selected() const {
|
||||
return _selected;
|
||||
}
|
||||
|
||||
/** Emitted when the selected status of this Selectable changes */
|
||||
sigc::signal<void, bool> Selected ;
|
||||
|
||||
protected:
|
||||
bool _selected;
|
||||
};
|
||||
|
|
|
@ -548,7 +548,7 @@ StreamView::set_selected_regionviews (AudioRegionSelection& regions)
|
|||
}
|
||||
|
||||
// cerr << "\tregion " << (*i)->region.name() << " selected = " << selected << endl;
|
||||
(*i)->set_selected (selected, this);
|
||||
(*i)->set_selected (selected);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -484,26 +484,14 @@ TimeAxisViewItem::get_item_name() const
|
|||
* @param src the identity of the object that initiated the change
|
||||
*/
|
||||
void
|
||||
TimeAxisViewItem::set_selected(bool yn, void* src)
|
||||
TimeAxisViewItem::set_selected(bool yn)
|
||||
{
|
||||
if (_selected != yn) {
|
||||
_selected = yn ;
|
||||
Selectable::set_selected (yn);
|
||||
set_frame_color ();
|
||||
Selected (_selected) ; /* EMIT_SIGNAL */
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns whether this item is currently selected.
|
||||
*
|
||||
* @return true if this item is currently selected, false otherwise
|
||||
*/
|
||||
bool
|
||||
TimeAxisViewItem::get_selected() const
|
||||
{
|
||||
return (_selected) ;
|
||||
}
|
||||
|
||||
void
|
||||
TimeAxisViewItem::set_should_show_selection (bool yn)
|
||||
{
|
||||
|
|
|
@ -21,8 +21,6 @@
|
|||
#ifndef __gtk_ardour_time_axis_view_item_h__
|
||||
#define __gtk_ardour_time_axis_view_item_h__
|
||||
|
||||
#include <sigc++/signal.h>
|
||||
|
||||
#include <jack/jack.h>
|
||||
#include <string>
|
||||
|
||||
|
@ -38,7 +36,7 @@ class TimeAxisView;
|
|||
* A base class for 'items' that may appear upon a TimeAxisView
|
||||
*
|
||||
*/
|
||||
class TimeAxisViewItem : public sigc::trackable, public Selectable
|
||||
class TimeAxisViewItem : public Selectable
|
||||
{
|
||||
public:
|
||||
virtual ~TimeAxisViewItem() ;
|
||||
|
@ -170,9 +168,8 @@ class TimeAxisViewItem : public sigc::trackable, public Selectable
|
|||
* Set to true to indicate that this item is currently selected
|
||||
*
|
||||
* @param yn true if this item is currently selected
|
||||
* @param src the identity of the object that initiated the change
|
||||
*/
|
||||
virtual void set_selected(bool yn, void* src) ;
|
||||
virtual void set_selected(bool yn) ;
|
||||
|
||||
/**
|
||||
* Set to true to indicate that this item should show its selection status
|
||||
|
@ -181,13 +178,6 @@ class TimeAxisViewItem : public sigc::trackable, public Selectable
|
|||
*/
|
||||
virtual void set_should_show_selection (bool yn) ;
|
||||
|
||||
/**
|
||||
* Returns whether this item is currently selected.
|
||||
*
|
||||
* @return true if this item is currently selected, false otherwise
|
||||
*/
|
||||
bool get_selected() const ;
|
||||
|
||||
//---------------------------------------------------------------------------------------//
|
||||
// Parent Component Methods
|
||||
|
||||
|
@ -319,10 +309,6 @@ class TimeAxisViewItem : public sigc::trackable, public Selectable
|
|||
/** Emitted when the mionimum item duration is changed */
|
||||
sigc::signal<void,jack_nframes_t,void*> MinDurationChanged ;
|
||||
|
||||
/** Emitted when the selected status of this item changes */
|
||||
sigc::signal<void, bool> Selected ;
|
||||
|
||||
|
||||
protected:
|
||||
|
||||
enum Visibility {
|
||||
|
|
|
@ -104,6 +104,7 @@ extra_sources = [ ]
|
|||
|
||||
if ardour['VST']:
|
||||
extra_sources += vst_files
|
||||
ardour.Append(CCFLAGS="-DVST_SUPPORT", CPPPATH="#libs/fst")
|
||||
|
||||
if ardour['LIBLO']:
|
||||
extra_sources += osc_files
|
||||
|
@ -179,15 +180,14 @@ if conf.CheckCHeader('/System/Library/Frameworks/CoreMIDI.framework/Headers/Core
|
|||
if conf.CheckCHeader('/System/Library/Frameworks/AudioToolbox.framework/Headers/ExtendedAudioFile.h') and ardour['COREAUDIO'] == 1:
|
||||
ardour.Append(CXXFLAGS="-DHAVE_COREAUDIO")
|
||||
ardour.Append(LINKFLAGS="-framework AudioToolbox")
|
||||
extra_sources += coreaudio_files
|
||||
|
||||
|
||||
if env['CONFIG_ARCH'] == 'apple':
|
||||
# this next line avoids issues with circular dependencies between libardour and libardour_cp.
|
||||
# it is based on the (entirely reasonable) assumption that a system with CoreAudio is OS X
|
||||
#
|
||||
print 'APPLE CONFIG'
|
||||
ardour.Append(LINKFLAGS='-undefined suppress -flat_namespace')
|
||||
extra_sources += coreaudio_files
|
||||
|
||||
ardour = conf.Finish ()
|
||||
|
||||
|
|
|
@ -20,12 +20,12 @@
|
|||
#ifndef __coreaudio_source_h__
|
||||
#define __coreaudio_source_h__
|
||||
|
||||
#include <ardour/externalsource.h>
|
||||
#include <ardour/audiofilesource.h>
|
||||
#include <AudioToolbox/ExtendedAudioFile.h>
|
||||
|
||||
namespace ARDOUR {
|
||||
|
||||
class CoreAudioSource : public ExternalSource {
|
||||
class CoreAudioSource : public AudioFileSource {
|
||||
public:
|
||||
CoreAudioSource (const string& path_plus_channel, bool build_peak = true);
|
||||
CoreAudioSource (const XMLNode&);
|
||||
|
|
|
@ -48,7 +48,7 @@ class DestructiveFileSource : public SndFileSource {
|
|||
static void setup_standard_crossfades (jack_nframes_t sample_rate);
|
||||
|
||||
protected:
|
||||
jack_nframes_t write_unlocked (Sample *src, jack_nframes_t start, jack_nframes_t cnt, char * workbuf);
|
||||
jack_nframes_t write_unlocked (Sample *src, jack_nframes_t cnt, char * workbuf);
|
||||
|
||||
private:
|
||||
static jack_nframes_t xfade_frames;
|
||||
|
|
|
@ -321,7 +321,6 @@ public:
|
|||
|
||||
Change restore_state (State&);
|
||||
StateManager::State* state_factory (std::string why) const;
|
||||
void send_state_changed();
|
||||
|
||||
bool get_midi_node_info (XMLNode * node, MIDI::eventType & ev, MIDI::channel_t & chan, MIDI::byte & additional);
|
||||
bool set_midi_node_info (XMLNode * node, MIDI::eventType ev, MIDI::channel_t chan, MIDI::byte additional);
|
||||
|
|
|
@ -233,7 +233,6 @@ class Region : public Stateful, public StateManager
|
|||
/* state management */
|
||||
|
||||
void send_change (Change);
|
||||
void send_state_changed ();
|
||||
|
||||
/* derived classes need these during their own state management calls */
|
||||
|
||||
|
|
|
@ -95,7 +95,7 @@ class Route : public IO
|
|||
virtual bool can_record() const { return false; }
|
||||
virtual void set_record_enable (bool yn, void *src) {}
|
||||
virtual bool record_enabled() const { return false; }
|
||||
virtual void transport_stopped (bool abort, bool did_locate, bool flush_redirects);
|
||||
virtual void handle_transport_stopped (bool abort, bool did_locate, bool flush_redirects);
|
||||
virtual void set_pending_declick (int);
|
||||
|
||||
/* end of vfunc-based API */
|
||||
|
|
|
@ -792,7 +792,9 @@ AudioSource::do_build_peak (jack_nframes_t first_frame, jack_nframes_t cnt)
|
|||
|
||||
frames_to_read = min (frames_per_peak, cnt);
|
||||
|
||||
if ((frames_read = read_unlocked (buf, current_frame, frames_to_read, workbuf)) != frames_to_read) {
|
||||
/* lock for every read */
|
||||
|
||||
if ((frames_read = read (buf, current_frame, frames_to_read, workbuf)) != frames_to_read) {
|
||||
error << string_compose(_("%1: could not write read raw data for peak computation (%2)"), _name, strerror (errno)) << endmsg;
|
||||
goto out;
|
||||
}
|
||||
|
|
|
@ -28,19 +28,19 @@
|
|||
using namespace ARDOUR;
|
||||
|
||||
CoreAudioSource::CoreAudioSource (const XMLNode& node)
|
||||
: ExternalSource (node)
|
||||
: AudioFileSource (node)
|
||||
{
|
||||
init (_name, true);
|
||||
SourceCreated (this); /* EMIT SIGNAL */
|
||||
AudioSourceCreated (this); /* EMIT SIGNAL */
|
||||
}
|
||||
|
||||
CoreAudioSource::CoreAudioSource (const string& idstr, bool build_peak)
|
||||
: ExternalSource(idstr, build_peak)
|
||||
: AudioFileSource(idstr, build_peak)
|
||||
{
|
||||
init (idstr, build_peak);
|
||||
|
||||
if (build_peak) {
|
||||
SourceCreated (this); /* EMIT SIGNAL */
|
||||
AudioSourceCreated (this); /* EMIT SIGNAL */
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -255,7 +255,7 @@ DestructiveFileSource::crossfade (Sample* data, jack_nframes_t cnt, int fade_in,
|
|||
}
|
||||
|
||||
jack_nframes_t
|
||||
DestructiveFileSource::write_unlocked (Sample* data, jack_nframes_t start, jack_nframes_t cnt, char * workbuf)
|
||||
DestructiveFileSource::write_unlocked (Sample* data, jack_nframes_t cnt, char * workbuf)
|
||||
{
|
||||
jack_nframes_t old_file_pos;
|
||||
|
||||
|
@ -319,9 +319,7 @@ DestructiveFileSource::write_unlocked (Sample* data, jack_nframes_t start, jack_
|
|||
}
|
||||
|
||||
old_file_pos = file_pos;
|
||||
if (file_pos + cnt > _length) {
|
||||
_length = file_pos + cnt;
|
||||
}
|
||||
update_length (file_pos, cnt);
|
||||
file_pos += cnt;
|
||||
|
||||
if (_build_peakfiles) {
|
||||
|
|
|
@ -2443,12 +2443,6 @@ IO::state_factory (std::string why) const
|
|||
return state;
|
||||
}
|
||||
|
||||
void
|
||||
IO::send_state_changed ()
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
/**
|
||||
Update the peak meters.
|
||||
|
||||
|
|
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
|
@ -2002,7 +2002,7 @@ Route::set_active (bool yn)
|
|||
}
|
||||
|
||||
void
|
||||
Route::transport_stopped (bool abort_ignored, bool did_locate, bool can_flush_redirects)
|
||||
Route::handle_transport_stopped (bool abort_ignored, bool did_locate, bool can_flush_redirects)
|
||||
{
|
||||
jack_nframes_t now = _session.transport_frame();
|
||||
|
||||
|
|
|
@ -3606,7 +3606,9 @@ Session::write_one_audio_track (AudioTrack& track, jack_nframes_t start, jack_nf
|
|||
jack_nframes_t to_do;
|
||||
vector<Sample*> buffers;
|
||||
char * workbuf = 0;
|
||||
const jack_nframes_t chunk_size = (256 * 1024)/4;
|
||||
|
||||
// any bigger than this seems to cause stack overflows in called functions
|
||||
const jack_nframes_t chunk_size = (128 * 1024)/4;
|
||||
|
||||
g_atomic_int_set (&processing_prohibited, 1);
|
||||
|
||||
|
|
|
@ -907,7 +907,7 @@ Session::send_midi_time_code_for_cycle(jack_nframes_t nframes)
|
|||
|
||||
if (_mtc_port == 0 || !send_mtc || transmitting_smpte_time.negative
|
||||
/*|| (next_quarter_frame_to_send < 0)*/ ) {
|
||||
printf("(MTC) Not sending MTC\n");
|
||||
//printf("(MTC) Not sending MTC\n");
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
@ -1035,13 +1035,13 @@ Session::deliver_mmc (MIDI::MachineControl::Command cmd, jack_nframes_t where)
|
|||
SMPTE::Time smpte;
|
||||
|
||||
if (_mmc_port == 0 || !send_mmc) {
|
||||
cerr << "Not delivering MMC " << _mmc_port << " - " << send_mmc << endl;
|
||||
//cerr << "Not delivering MMC " << _mmc_port << " - " << send_mmc << endl;
|
||||
return;
|
||||
}
|
||||
|
||||
mmc_buffer[nbytes++] = cmd;
|
||||
|
||||
cerr << "delivering MMC, cmd = " << hex << (int) cmd << dec << endl;
|
||||
//cerr << "delivering MMC, cmd = " << hex << (int) cmd << dec << endl;
|
||||
|
||||
switch (cmd) {
|
||||
case MachineControl::cmdLocate:
|
||||
|
@ -1090,9 +1090,9 @@ Session::deliver_mmc (MIDI::MachineControl::Command cmd, jack_nframes_t where)
|
|||
// FIXME: timestamp correct? [DR]
|
||||
if (!_mmc_port->midimsg (mmc_buffer, sizeof (mmc_buffer), where - _transport_frame)) {
|
||||
error << string_compose(_("MMC: cannot send command %1%2%3"), &hex, cmd, &dec) << endmsg;
|
||||
} else {
|
||||
} /*else {
|
||||
cerr << "Sending MMC\n";
|
||||
}
|
||||
}*/
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -1210,8 +1210,8 @@ Session::update_latency_compensation (bool with_stop, bool abort)
|
|||
|
||||
for (RouteList::iterator i = routes.begin(); i != routes.end(); ++i) {
|
||||
if (with_stop) {
|
||||
(*i)->transport_stopped (abort, (post_transport_work & PostTransportLocate),
|
||||
(!(post_transport_work & PostTransportLocate) || pending_locate_flush));
|
||||
(*i)->handle_transport_stopped (abort, (post_transport_work & PostTransportLocate),
|
||||
(!(post_transport_work & PostTransportLocate) || pending_locate_flush));
|
||||
}
|
||||
|
||||
jack_nframes_t old_latency = (*i)->signal_latency ();
|
||||
|
|
|
@ -81,8 +81,6 @@ SndFileSource::SndFileSource (string idstr, SampleFormat sfmt, HeaderFormat hf,
|
|||
|
||||
init (idstr);
|
||||
|
||||
cerr << "creating " << idstr << " hf = " << hf << endl;
|
||||
|
||||
switch (hf) {
|
||||
case CAF:
|
||||
fmt = SF_FORMAT_CAF;
|
||||
|
@ -174,7 +172,7 @@ SndFileSource::SndFileSource (string idstr, SampleFormat sfmt, HeaderFormat hf,
|
|||
}
|
||||
|
||||
if (_build_peakfiles) {
|
||||
if (initialize_peakfile (false, _path)) {
|
||||
if (initialize_peakfile (true, _path)) {
|
||||
sf_close (sf);
|
||||
sf = 0;
|
||||
throw failed_constructor ();
|
||||
|
@ -187,14 +185,6 @@ SndFileSource::SndFileSource (string idstr, SampleFormat sfmt, HeaderFormat hf,
|
|||
HeaderPositionOffsetChanged.connect (mem_fun (*this, &AudioFileSource::handle_header_position_change));
|
||||
}
|
||||
|
||||
if (_build_peakfiles) {
|
||||
if (initialize_peakfile (false, _path)) {
|
||||
sf_close (sf);
|
||||
sf = 0;
|
||||
throw failed_constructor ();
|
||||
}
|
||||
}
|
||||
|
||||
AudioSourceCreated (this); /* EMIT SIGNAL */
|
||||
}
|
||||
|
||||
|
@ -310,7 +300,7 @@ SndFileSource::read_unlocked (Sample *dst, jack_nframes_t start, jack_nframes_t
|
|||
|
||||
if (file_cnt) {
|
||||
|
||||
if (sf_seek (sf, (off_t) start, SEEK_SET) < 0) {
|
||||
if (sf_seek (sf, (sf_count_t) start, SEEK_SET|SFM_READ) != (sf_count_t) start) {
|
||||
char errbuf[256];
|
||||
sf_error_str (0, errbuf, sizeof (errbuf) - 1);
|
||||
error << string_compose(_("SndFileSource: could not seek to frame %1 within %2 (%3)"), start, _name.substr (1), errbuf) << endmsg;
|
||||
|
@ -505,7 +495,7 @@ SndFileSource::set_header_timeline_position ()
|
|||
jack_nframes_t
|
||||
SndFileSource::write_float (Sample* data, jack_nframes_t frame_pos, jack_nframes_t cnt)
|
||||
{
|
||||
if (sf_seek (sf, frame_pos, SEEK_SET) != frame_pos) {
|
||||
if (sf_seek (sf, frame_pos, SEEK_SET|SFM_WRITE) != frame_pos) {
|
||||
error << string_compose (_("%1: cannot seek to %2"), _path, frame_pos) << endmsg;
|
||||
return 0;
|
||||
}
|
||||
|
|
|
@ -177,7 +177,7 @@ tokenize_fullpath (string fullpath, string& path, string& name)
|
|||
int
|
||||
touch_file (string path)
|
||||
{
|
||||
int fd = open (path.c_str(), O_RDONLY|O_CREAT);
|
||||
int fd = open (path.c_str(), O_RDWR|O_CREAT, 0660);
|
||||
if (fd >= 0) {
|
||||
close (fd);
|
||||
return 0;
|
||||
|
|
|
@ -7,7 +7,7 @@ msgid ""
|
|||
msgstr ""
|
||||
"Project-Id-Version: 0.99beta23\n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2006-04-25 17:46-0400\n"
|
||||
"POT-Creation-Date: 2006-06-20 16:25-0400\n"
|
||||
"PO-Revision-Date: 2005-01-11\n"
|
||||
"Last-Translator: Muadibas\n"
|
||||
"Language-Team: Hellenic(Greek) <LL@li.org>\n"
|
||||
|
@ -15,7 +15,7 @@ msgstr ""
|
|||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
|
||||
#: libs/gtkmm2ext/barcontroller.cc:431 libs/gtkmm2ext/bindable_button.cc:131
|
||||
#: libs/gtkmm2ext/barcontroller.cc:432 libs/gtkmm2ext/bindable_button.cc:131
|
||||
#: libs/gtkmm2ext/controller.cc:50 libs/gtkmm2ext/slider_controller.cc:132
|
||||
msgid "operate MIDI controller now"
|
||||
msgstr "λειτουργία ελεγκτή MIDI τώρα"
|
||||
|
|
|
@ -6,7 +6,7 @@ msgid ""
|
|||
msgstr ""
|
||||
"Project-Id-Version: gtkmm2ext\n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2006-04-25 17:46-0400\n"
|
||||
"POT-Creation-Date: 2006-06-20 16:25-0400\n"
|
||||
"PO-Revision-Date: 2004-02-13 00:35+0300\n"
|
||||
"Last-Translator: Alex Krohn alexkrohn@fastmail.fm\n"
|
||||
"Language-Team: Spanish\n"
|
||||
|
@ -14,7 +14,7 @@ msgstr ""
|
|||
"Content-Type: text/plain; charset=ISO-8859-1\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
|
||||
#: libs/gtkmm2ext/barcontroller.cc:431 libs/gtkmm2ext/bindable_button.cc:131
|
||||
#: libs/gtkmm2ext/barcontroller.cc:432 libs/gtkmm2ext/bindable_button.cc:131
|
||||
#: libs/gtkmm2ext/controller.cc:50 libs/gtkmm2ext/slider_controller.cc:132
|
||||
msgid "operate MIDI controller now"
|
||||
msgstr "Operar controladora de MIDI ahora"
|
||||
|
|
|
@ -7,7 +7,7 @@ msgid ""
|
|||
msgstr ""
|
||||
"Project-Id-Version: gtkmm2ext\n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2006-04-25 17:46-0400\n"
|
||||
"POT-Creation-Date: 2006-06-20 16:25-0400\n"
|
||||
"PO-Revision-Date: 2004-05-17 20:36+0200\n"
|
||||
"Last-Translator: Chris Ross <chris.ross@tebibyte.org>\n"
|
||||
"Language-Team: Portuguese\n"
|
||||
|
@ -15,7 +15,7 @@ msgstr ""
|
|||
"Content-Type: text/plain; charset=ISO-8859-15\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
|
||||
#: libs/gtkmm2ext/barcontroller.cc:431 libs/gtkmm2ext/bindable_button.cc:131
|
||||
#: libs/gtkmm2ext/barcontroller.cc:432 libs/gtkmm2ext/bindable_button.cc:131
|
||||
#: libs/gtkmm2ext/controller.cc:50 libs/gtkmm2ext/slider_controller.cc:132
|
||||
msgid "operate MIDI controller now"
|
||||
msgstr "Operar controladora de MIDI agora"
|
||||
|
|
|
@ -6,7 +6,7 @@ msgid ""
|
|||
msgstr ""
|
||||
"Project-Id-Version: gtkmm2ext\n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2006-04-25 17:46-0400\n"
|
||||
"POT-Creation-Date: 2006-06-20 16:25-0400\n"
|
||||
"PO-Revision-Date: 2004-02-13 00:35+0300\n"
|
||||
"Last-Translator: Igor Blinov pitstop@nm.ru\n"
|
||||
"Language-Team: Russian\n"
|
||||
|
@ -14,7 +14,7 @@ msgstr ""
|
|||
"Content-Type: text/plain; charset=koi8-r\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
|
||||
#: libs/gtkmm2ext/barcontroller.cc:431 libs/gtkmm2ext/bindable_button.cc:131
|
||||
#: libs/gtkmm2ext/barcontroller.cc:432 libs/gtkmm2ext/bindable_button.cc:131
|
||||
#: libs/gtkmm2ext/controller.cc:50 libs/gtkmm2ext/slider_controller.cc:132
|
||||
msgid "operate MIDI controller now"
|
||||
msgstr "×ËÌÀÞÉÔØ MIDI-ËÏÎÔÒÏÌÌÅÒ"
|
||||
|
|
|
@ -1150,7 +1150,7 @@ sf_seek (SNDFILE *sndfile, sf_count_t offset, int whence)
|
|||
** it makes sense.
|
||||
*/
|
||||
if (((whence & SFM_MASK) == SFM_WRITE && psf->mode == SFM_READ) ||
|
||||
((whence & SFM_MASK) == SFM_WRITE && psf->mode == SFM_WRITE))
|
||||
((whence & SFM_MASK) == SFM_READ && psf->mode == SFM_WRITE))
|
||||
{ psf->error = SFE_WRONG_SEEK ;
|
||||
return PSF_SEEK_ERROR ;
|
||||
} ;
|
||||
|
@ -1210,10 +1210,25 @@ sf_seek (SNDFILE *sndfile, sf_count_t offset, int whence)
|
|||
if (psf->error)
|
||||
return PSF_SEEK_ERROR ;
|
||||
|
||||
#ifdef ECDL_ORIGINAL#
|
||||
if (seek_from_start < 0 || seek_from_start > psf->sf.frames)
|
||||
{ psf->error = SFE_BAD_SEEK ;
|
||||
return PSF_SEEK_ERROR ;
|
||||
} ;
|
||||
#else
|
||||
if (((whence & SFM_MASK) == SFM_WRITE) || (psf->mode == SFM_WRITE || psf->mode == SFM_RDWR))
|
||||
{ if (seek_from_start < 0 /* || (seek_from_start > psf->sf.frames && post-audio chunks exist) */ )
|
||||
{ psf->error = SFE_BAD_SEEK ;
|
||||
return PSF_SEEK_ERROR ;
|
||||
}
|
||||
}
|
||||
else /* seek for reading */
|
||||
{ if (seek_from_start < 0 || seek_from_start > psf->sf.frames)
|
||||
{ psf->error = SFE_BAD_SEEK ;
|
||||
return PSF_SEEK_ERROR ;
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
if (psf->seek)
|
||||
{ int new_mode = (whence & SFM_MASK) ? (whence & SFM_MASK) : psf->mode ;
|
||||
|
@ -1234,6 +1249,7 @@ sf_seek (SNDFILE *sndfile, sf_count_t offset, int whence)
|
|||
break ;
|
||||
} ;
|
||||
|
||||
|
||||
psf->last_op = new_mode ;
|
||||
|
||||
return retval ;
|
||||
|
|
|
@ -539,7 +539,6 @@ wav_read_header (SF_PRIVATE *psf, int *blockalign, int *framesperblock)
|
|||
break ;
|
||||
|
||||
case bext_MARKER :
|
||||
parsestage |= HAVE_other ;
|
||||
|
||||
psf_binheader_readf (psf, "4", &dword) ;
|
||||
if (dword < WAV_BEXT_CHUNK_SIZE)
|
||||
|
|
Loading…
Reference in New Issue