0
$\begingroup$

I am trying to get an old xaml exporter working in blender 2.79.

I have managed to get it showing up in the add-ons list but it when trying to enable it, i get a bunch of errors. I think the Blender API has changed because it won't import Blender. What can I do (not a python programmer) Or if anyone knows of a Xaml Exporter thats working, let me know.

bl_info = {
    "name": "XAML format (.xaml)",
    "author": "Daniel Lehenbauer and Robert Hogue",
    "version": (0, 0, 48),
    "blender": (2, 71, 0),
    "location": "File > Export > XAML",
    "description": "Export mesh to XAML",
    "warning": "",
    "wiki_url": "https://archive.codeplex.com/?p=xamlexporter",
    "category": "Import-Export"}

from io import StringIO
from math import *

# ERROR HERE
import Blender
from Blender import Scene
from Blender import Texture
from Blender import Mathutils
from Blender import Lamp
import BPyMesh
import BPyObject

I have done some more work on it. The code is on PasteBin I am getting the error shown in the image. enter image description here

$\endgroup$
  • 1
    $\begingroup$ The import Blender is an indicator the addon is older than 2.5 (when bpy module was introduced) Could update the addon, or install blender 2.49b 8*( $\endgroup$ – batFINGER Feb 17 '18 at 8:41
  • $\begingroup$ This one is obvious (old Blender version - Blender module was replaced by bpy module), but posting error messages will help indicating the problem in future. As for making this addon updated for current Blender version - surely doable, but there are many API changes since pre-2.5 version) $\endgroup$ – kilbee Feb 17 '18 at 11:50
  • $\begingroup$ Okay, so I guess its a complete rewrite. I will think about if I want to do that (since I don't know python). $\endgroup$ – Haydn Feb 18 '18 at 2:27
1
$\begingroup$

3D in XAML is pretty much a dead since Microsoft dropped support for it.

I rewrote the script from scratch. You can the script from my GitLab page which includes install and usage instructions as well as the license (MIT).

$\endgroup$
  • $\begingroup$ Excelllent. Could you give a quick run down on addon install and usage in answer? (Recall XAML was such a big thing in Vista, don't see it that much since I moved to ubuntu) $\endgroup$ – batFINGER Oct 13 '18 at 10:20
  • 1
    $\begingroup$ Link only answers are forbidden and your answer is in danger of getting removed. Please see the comment above and edit accordingly. Thanks! :) You can post the entire script here so if your gitlab account goes it might be helpful to someone else in the future. $\endgroup$ – iKlsR Oct 13 '18 at 17:41

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.