final ISO9660RootDirectory root = new ISO9660RootDirectory();
try {
root.addContentsRecursively(src);
final StreamHandler streamHandler = new ISOImageFileHandler(dest);
CreateISO iso = new CreateISO(streamHandler, root);
iso.process(new ISO9660Config(), new RockRidgeConfig(), new JolietConfig(), null);
} catch (Exception e) {
throw new RuntimeException("failed to create image", e);
}
}