Skip to content

Commit edce7e9

Browse files
committed
* Finished Bento implementation.
* TAL Sampler * New: Conversion does not stop after first missing sample. All missing samples are logged. * Fixed: Could not read file when the program element had more than 200 attributes. * Fixed: Version 11 of the format has now a double to indicate of a layer is enabled or not which led to empty results.
1 parent 1b242ae commit edce7e9

7 files changed

Lines changed: 24 additions & 7 deletions

File tree

documentation/CHANGELOG.md

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Changes
22

3-
## 15.2.0 (unreleased)
3+
## 15.5.0
44

55
* Added support for 1010music Bento
66
* Fixed: The header of written FLAC files did not contain the sample length, which is valid but many readers rely on that value and crash otherwise.
@@ -13,6 +13,10 @@
1313
* MPC
1414
* New: The file version and source platform is now logged.
1515
* New: Improved check for valid loops. If none is present it is loaded from the WAV file if present.
16+
* TAL Sampler
17+
* New: Conversion does not stop after first missing sample. All missing samples are logged.
18+
* Fixed: Could not read file when the program element had more than 200 attributes.
19+
* Fixed: Version 11 of the format has now a double to indicate of a layer is enabled or not which led to empty results.
1620
* Yamaha YSFC
1721
* Fixed: End of loop was always set to the end of the sample.
1822

131 Bytes
Binary file not shown.

pom.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
<modelVersion>4.0.0</modelVersion>
66
<groupId>de.mossgrabers</groupId>
77
<artifactId>convertwithmoss</artifactId>
8-
<version>15.2.0</version>
8+
<version>15.5.0</version>
99
<packaging>jar</packaging>
1010
<name>ConvertWithMoss</name>
1111
<organization>
@@ -154,7 +154,7 @@
154154
<plugin>
155155
<groupId>org.panteleyev</groupId>
156156
<artifactId>jpackage-maven-plugin</artifactId>
157-
<version>1.7.2</version>
157+
<version>1.7.3</version>
158158
<configuration>
159159
<input>target/lib</input>
160160
<destination>target/release</destination>

src/main/java/de/mossgrabers/convertwithmoss/core/ConverterBackend.java

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -96,6 +96,9 @@ public ConverterBackend (final INotifier notifier)
9696
{
9797
this.notifier = notifier;
9898

99+
// Workaround for attribute limit of 200 which e.g. causes issues with TAL Sampler format
100+
System.setProperty ("jdk.xml.elementAttributeLimit", "1000");
101+
99102
this.detectors = new IDetector []
100103
{
101104
new BentoDetector (notifier),

src/main/java/de/mossgrabers/convertwithmoss/format/tal/TALSamplerDetector.java

Lines changed: 13 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
package de.mossgrabers.convertwithmoss.format.tal;
66

77
import java.io.File;
8+
import java.io.FileNotFoundException;
89
import java.io.IOException;
910
import java.io.StringReader;
1011
import java.util.ArrayList;
@@ -150,7 +151,7 @@ private List<IMultisampleSource> parseDescription (final File multiSampleFile, f
150151
final List<IGroup> groups = new ArrayList<> (4);
151152
for (int groupCounter = 0; groupCounter < 4; groupCounter++)
152153
// Group is disabled?
153-
if (XMLUtils.getIntegerAttribute (programElement, TALSamplerTag.PROGRAM_LAYER_ON + TALSamplerConstants.LAYERS[groupCounter], 0) == 1)
154+
if (XMLUtils.getDoubleAttribute (programElement, TALSamplerTag.PROGRAM_LAYER_ON + TALSamplerConstants.LAYERS[groupCounter], 0) > 0)
154155
{
155156
final Element groupElement = XMLUtils.getChildElementByName (programElement, TALSamplerTag.SAMPLE_LAYER + groupCounter);
156157
if (groupElement != null)
@@ -208,7 +209,16 @@ private ISampleZone parseSample (final File parentFolder, final Element programE
208209
if (XMLUtils.getIntegerAttribute (sampleElement, TALSamplerTag.IS_ROM_SAMPLE, 0) == 1)
209210
throw new IOException (Functions.getMessage ("IDS_TAL_ROM_SAMPLES_NOT_SUPPORTED", filename));
210211

211-
final ISampleZone zone = this.createSampleZone (new File (parentFolder, filename));
212+
final ISampleZone zone;
213+
try
214+
{
215+
zone = this.createSampleZone (new File (parentFolder, filename));
216+
}
217+
catch (final FileNotFoundException ex)
218+
{
219+
this.notifier.logError (ex, false);
220+
return null;
221+
}
212222

213223
zone.setGain (convertGain (XMLUtils.getDoubleAttribute (sampleElement, TALSamplerTag.VOLUME, 0)));
214224
zone.setPanning (XMLUtils.getDoubleAttribute (sampleElement, TALSamplerTag.PANNING, 0.5) * 2.0 - 1.0);
@@ -231,7 +241,7 @@ private ISampleZone parseSample (final File parentFolder, final Element programE
231241
zone.setVelocityLow (XMLUtils.getIntegerAttribute (sampleElement, TALSamplerTag.LO_VEL, -1));
232242
zone.setVelocityHigh (XMLUtils.getIntegerAttribute (sampleElement, TALSamplerTag.HI_VEL, -1));
233243

234-
// No note and velocity crossfades
244+
// No note and velocity cross-fades
235245

236246
if (XMLUtils.getIntegerAttribute (sampleElement, TALSamplerTag.LOOP_ENABLED, 0) == 1)
237247
{

src/main/resources/Strings.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
TITLE=ConvertWithMoss 15.2.0
1+
TITLE=ConvertWithMoss 15.5.0
22

33
##################################################################################
44
#
Binary file not shown.

0 commit comments

Comments
 (0)