use of blue.BlueData in project blue by kunstmusik.
the class MixerTopComponent method reinitialize.
protected void reinitialize() {
BlueProject project = BlueProjectManager.getInstance().getCurrentProject();
BlueData data = null;
channelGroupsPanel.removeAll();
if (project != null) {
data = project.getData();
for (ChannelList list : data.getMixer().getChannelListGroups()) {
ChannelListPanel panel = new ChannelListPanel();
channelGroupsPanel.add(panel);
panel.setChannelList(list, data.getMixer().getSubChannels());
panel.revalidate();
}
channelGroupsPanel.add(channelsPanel);
channelGroupsPanel.add(subChannelsPanel);
setMixer(data.getMixer());
setArrangement(data.getArrangement());
}
channelGroupsPanel.revalidate();
channelGroupsPanel.repaint();
}
use of blue.BlueData in project blue by kunstmusik.
the class MidiInputEngine method reinitialize.
protected void reinitialize() {
BlueProject project = BlueProjectManager.getInstance().getCurrentProject();
BlueData data = null;
if (project != null) {
data = project.getData();
arrangement = data.getArrangement().getArrangement();
processor = data.getMidiInputProcessor();
}
}
use of blue.BlueData in project blue by kunstmusik.
the class ParameterTimeManagerImpl method getTime.
@Override
public double getTime() {
if (RealtimeRenderManager.getInstance().isAuditioning()) {
return -1.0f;
}
BlueProject project = BlueProjectManager.getInstance().getCurrentProject();
if (project == null) {
return -1.0f;
}
BlueData data = project.getData();
if (data == null) {
return -1.0f;
}
double val = data.getRenderStartTime();
return val;
}
use of blue.BlueData in project blue by kunstmusik.
the class ReplaceWithBufferSoundObjectAction method actionPerformed.
@Override
public void actionPerformed(ActionEvent e) {
ScoreController.ScoreObjectBuffer buffer = ScoreController.getInstance().getScoreObjectBuffer();
List<Layer> layers = scorePath.getAllLayers();
BlueData data = BlueProjectManager.getInstance().getCurrentBlueData();
SoundObjectLibrary sObjLib = data.getSoundObjectLibrary();
List<Instance> instances = new ArrayList<>();
ReplaceScoreObjectEdit top = null;
for (SoundObject sObj : soundObjects) {
SoundObject replacement = getReplacementObject(buffer, instances);
replacement.setStartTime(sObj.getStartTime());
replacement.setSubjectiveDuration(sObj.getSubjectiveDuration());
ScoreObjectLayer layer = (ScoreObjectLayer) findLayerForSoundObject(layers, sObj);
layer.remove(sObj);
layer.add(replacement);
ReplaceScoreObjectEdit edit = new ReplaceScoreObjectEdit(layer, sObj, replacement);
if (top == null) {
top = edit;
} else {
top.addEdit(edit);
}
}
// FIXME - this part is not undoable...
sObjLib.checkAndAddInstanceSoundObjects(instances);
BlueUndoManager.setUndoManager("score");
BlueUndoManager.addEdit(top);
}
use of blue.BlueData in project blue by kunstmusik.
the class CSDUtilityTest method testParseCsScore_multiLine.
@Test
public void testParseCsScore_multiLine() {
BlueData data = new BlueData();
String score1 = "i1 0 2 3 4 5\n6 7 8 9\n8.8 8\n";
score1 += "i1 2 3 4 5\n";
score1 += "i1 2 3 4 5\n";
score1 += "\"test\" 1 2 3 4 5\n";
String score2 = "f1 0 3 4\n 5 6 7\n";
String score = score1 + score2;
int importMode = CSDUtility.IMPORT_GLOBAL;
CSDUtility.parseCsScore(data, score, importMode);
assertEquals(score1, data.getGlobalOrcSco().getGlobalSco());
assertEquals(score2, data.getTableSet().getTables());
}
Aggregations