|
|
|
@ -17,8 +17,8 @@ import static com.dsideal.aiSupport.AiSupportApplication.getEnvPrefix;
|
|
|
|
|
/**
|
|
|
|
|
* 阿里云达摩院EMO视频合成API工具类
|
|
|
|
|
*/
|
|
|
|
|
public class DsEmoVideoSynthesis {
|
|
|
|
|
private static final Logger log = LoggerFactory.getLogger(DsEmoVideoSynthesis.class);
|
|
|
|
|
public class ImgSong {
|
|
|
|
|
private static final Logger log = LoggerFactory.getLogger(ImgSong.class);
|
|
|
|
|
private static final String API_URL = "https://dashscope.aliyuncs.com/api/v1/services/aigc/image2video/video-synthesis/";
|
|
|
|
|
private static final String API_KEY;
|
|
|
|
|
// 获取项目根目录路径
|
|
|
|
@ -267,9 +267,9 @@ public class DsEmoVideoSynthesis {
|
|
|
|
|
@SneakyThrows
|
|
|
|
|
public static void main(String[] args) {
|
|
|
|
|
// 图片URL
|
|
|
|
|
String imageUrl = "https://dsideal.obs.myhuaweicloud.com/HuangHai/%E5%A4%87%E4%BB%BD/p872922.png";
|
|
|
|
|
String imageUrl = "https://dsideal.obs.myhuaweicloud.com/HuangHai/%E5%A4%87%E4%BB%BD/p872311.png";
|
|
|
|
|
// 音频URL
|
|
|
|
|
String audioUrl = "https://dsideal.obs.myhuaweicloud.com/HuangHai/%E5%A4%87%E4%BB%BD/example.wav";
|
|
|
|
|
String audioUrl = "https://dsideal.obs.myhuaweicloud.com/HuangHai/%E5%A4%87%E4%BB%BD/p872311.wav";
|
|
|
|
|
|
|
|
|
|
// 比例
|
|
|
|
|
String ratio = "1:1";
|