0
$\begingroup$

Currently when Blender loads an .x3d file it does not load the correct DEF attribute, i.e., each shape doesn't get its designated name, and instead is called ShapeIndexedFaceSetXXX.

Is there some way to fix this bug via Python scripting, or is it something deeper?

$\endgroup$
3
  • $\begingroup$ it is in python you can find it in ,\scripts\addons\io_scene_x3d\import_x3d.py $\endgroup$
    – Chebhou
    May 10, 2015 at 23:45
  • 1
    $\begingroup$ You should file a bug report olamundo: developer.blender.org , or, if you do fix it submit a bug patch. $\endgroup$
    – zeffii
    May 11, 2015 at 5:07
  • $\begingroup$ This question appears to be off-topic because it is about Blender's source code. These questions are considered outside the scope of this StackExchange as defined in the help center. Development questions should be asked of the developers directly instead, see the contacting developers page of the blender wiki. $\endgroup$
    – gandalf3
    May 11, 2015 at 18:09

1 Answer 1

2
$\begingroup$

Found the problem: In Blender 2.74, inside

def getDefName(self):
        data = self.x3dNode.getAttributeNode('DEF')
        if data:
            data.value  # XXX, return??
        return None

Does not return the name in case it found it, changing it to

def getDefName(self):
        data = self.x3dNode.getAttributeNode('DEF')
        if data:
            return data.value  # XXX, return??
        return None

worked for me, however I don't know how to suggest it as a bug fix nor am I sure that it is indeed a worthy fix as clearly someone already noticed that this function doesn't return anything in case there is a DEF.

$\endgroup$

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.