package national;
import java
import java
public class VideoProcess {
public static boolean processTransToImg
newimg){
System
>
List<String> commendF = new ArrayList<String>();
List<String> commendI=new java
commendF
commendF
commendF
commendF
commendF
commendF
commendF
commendF
commendF
commendF
commendF
commendF
commendF
commendF
commendF
commendF
(
commendF
commendF
commendI
commendI
commendI
commendI
commendI
commendI
commendI
commendI
commendI
commendI
commendI
commendI
commendI
try {
ProcessClass
ProcessClass
return true;
} catch (Exception e) {
e
return false;
}
}
public static void main(String[] args){
String oldfilepath =
String newfilename =
String newimg =
System
processTransToImg
System
}
}
package national;
import java
import java
import java
import java
public class ProcessClass{
public List<String> commendList = new ArrayList<String>();
public ProcessClass(List<String> commendList){
mendList = commendList;
}
//同步使只能有一個進程執行該方法(實現格式轉換進程完成後執行截圖進程操作)
public static synchronized Process exec(List<String> commendlist){
StringBuffer strBuf = new StringBuffer();
for(Iterator iter =erator();iter
String Strtemp = (String)iter
strBuf
strBuf
}
try {
return Runtime
} catch (IOException e) {
e
return null;
}
}
}
From:http://tw.wingwit.com/Article/program/Java/hx/201311/26925.html