i wrote this Java Tool to Export WRL-Format to DAE-Format but doesn't work!! Only Blender ist started, and nothing else. And I don't no why. Someone can help me please
Java-Code:
Code: Select all
public class Converter {
/**
* @param args
*/
public static void main(String[] args) {
Runtime rt = Runtime.getRuntime();
String[] callAndArgs1 = {"C:\\Program Files\\Blender Foundation/Blender/blender.exe", "C:\\Users\\Desktop\\Scripting.py" };
try {
Process child = rt.exec(callAndArgs1);
child.waitFor();
System.out.println("Blender:: Process exit code is:" + child.exitValue());
}
catch(IOException e) {
System.err.println(
"Blender:: IOException starting process!");
}
catch(InterruptedException e) {
System.err.println(
"Blender:: Interrupted waiting for process!");
}
}
Code: Select all
# -*- coding: utf-8 -*-
import bpy
bpy.ops.object.select_all(action='TOGGLE')
bpy.ops.object.delete(use_global=False)
bpy.ops.import_scene.x3d(filepath="C:\\3D-Data\\test.wrl", filter_glob="*.wrl", axis_forward='Y', axis_up='Z')
bpy.ops.wm.collada_export(filepath="C:\\3D-Data\\test.dae")
bpy.ops.file.execute()
bpy.ops.wm.quit_blender()


-------------------------------------------------------------------------------
Another Question: How cann I export via Scripting (Python command) with Blender all drawings (with the same format (WRL)) from a odner together to a new format (DAE) and keep the same original filename (drawingname)? how can i do it? (please, which commands(scripting))
Thanks!!
Armand