1 #include "automation.h"
3 #include "edlsession.h"
6 #include "playabletracks.h"
8 #include "preferences.h"
9 #include "renderengine.h"
13 #include "transportque.h"
16 PlayableTracks::PlayableTracks(RenderEngine *renderengine,
17 long current_position,
22 this->renderengine = renderengine;
23 this->data_type = data_type;
25 //printf("PlayableTracks::PlayableTracks 1 %d\n", renderengine->edl->tracks->total());
26 for(Track *current_track = renderengine->edl->tracks->first;
28 current_track = current_track->next)
30 if(is_playable(current_track, current_position, use_nudge))
32 //printf("PlayableTracks::PlayableTracks 1 %p %d %d\n", this, total, current_position);
33 append(current_track);
36 //printf("PlayableTracks::PlayableTracks %d %d %d\n", data_type, total, current_position);
39 PlayableTracks::~PlayableTracks()
44 int PlayableTracks::is_playable(Track *current_track,
49 int direction = renderengine->command->get_direction();
50 if(use_nudge) position += current_track->nudge;
54 if(current_track->data_type != data_type) result = 0;
57 // Track is off screen and not bounced to other modules
62 if(!current_track->plugin_used(position, direction) &&
63 !current_track->is_playable(position, direction))
68 if(!current_track->play)
75 // Test for playable edit
76 if(!current_track->playable_edit(position, direction))
78 // Test for playable effect
79 if(!current_track->is_synthesis(renderengine,
92 int PlayableTracks::is_listed(Track *track)
94 for(int i = 0; i < total; i++)
96 if(values[i] == track) return 1;