[prj] Blender add-on to create technical drawing

124»

Comments

  • I'm a complete Inkscape newbie....would the tagging be possible using Attributes like if you hover over the objects in this link: https://media.inkscape.org/media/resources/file/Hover2.svg
    I probably need a way to map the values to attributes first...

  • edited February 10

    I'm not sure I understood what you mean... Do you intend something like this?
    (wait for the inkscape part)

    steverugi
  • I used javascript to do what you see in the previous animated gif: the script (you can find it in https://gitlab.com/marzof/prj/-/tree/main/obj_data_viewer) extracts the infos from the svg (as it comes from prj) and shows them in an html page.
    I don't know if it could be a path to try for you needs.

    Bedson
  • (PS: the link to the google drive file return a "Access Denied" message... in order to let anyone see it you should change its permissions)

    Bedson
  • Link now opened for access. Thanks @strumet for your help.

  • Sorry to be a pain. This works in a Browser but I'm wondering if it is possible to get the leaders and text to be permanently shown (and linked to ) in Inkscape?
    Even better would be the ability to use Blender's Custom Properties....a bit like MeasureIt_Arch does with Autofill - Custom Properties https://kevancress.github.io/MeasureIt_ARCH/prop_descriptions/textfields/

  • edited August 24

    @DADA_universe said:
    I'd kind of taken prj as a given in my workflow since it does what it does well, so such a bummer not being able to use it in Blender 3.6, I suspect due to the python version in use, prj is just not able to install dependencies. @strumet is there something I can do about this please?

    Face palm as I realise I've circled back a year later to the same issue to which I didn't offer further information the last time, this time with Blender 4.1.1 with prj version 0.0.9L.

    Here is the error I'm getting after clicking the button to install dependencies: Command '['/usr/bin/python3.12', '-m', 'pip', 'install', 'svgwrite']' returned non-zero exit status 1.

    Running Blender on Manjaro Linux.

  • @DADA_universe said:

    @DADA_universe said:
    I'd kind of taken prj as a given in my workflow since it does what it does well, so such a bummer not being able to use it in Blender 3.6, I suspect due to the python version in use, prj is just not able to install dependencies. @strumet is there something I can do about this please?

    Face palm as I realise I've circled back a year later to the same issue to which I didn't offer further information the last time, this time with Blender 4.1.1 with prj version 0.0.9L.

    Here is the error I'm getting after clicking the button to install dependencies: Command '['/usr/bin/python3.12', '-m', 'pip', 'install', 'svgwrite']' returned non-zero exit status 1.

    Running Blender on Manjaro Linux.

    Figured out this had to do with Python path issues from how the system installed version of Blender is installed on Manjaro. Downloaded portable version of Blender 4.2 LTS (which has python bundled in it and located in a path it seems prj can better recognize) and the prj dependencies installed with no issues, however, trying to generate an svg with prj now throws this error:
    Something went wrong...Drawing cancelled for Camera_2D
    Traceback (most recent call last):
    File ".............../.config/blender/4.2/scripts/addons/prj/init.py", line 111, in execute
    filepath = main(camera, self.selected_objects, context)
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "........................../.config/blender/4.2/scripts/addons/prj/main.py", line 116, in main
    draw_subjects(subjects_to_draw)
    File ".........................../.config/blender/4.2/scripts/addons/prj/draw.py", line 136, in draw_subjects
    draw(subject)
    File "........................../.config/blender/4.2/scripts/addons/prj/drawing_maker.py", line 143, in draw
    export_grease_pencil(subject=subject,grease_pencil=lineart_gp,
    File "................................./.config/blender/4.2/scripts/addons/prj/drawing_maker.py", line 100, in export_grease_pencil
    svg_data = Svg_read(tmp_file)
    ^^^^^^^^^^^^^^^^^^
    File "................................./.config/blender/4.2/scripts/addons/prj/svgread.py", line 42, in init
    self.root = ET.parse(filepath).getroot()
    ^^^^^^^^^^^^^^^^^^
    File "......................./Downloads/blender-4.2.1-linux-x64/4.2/python/lib/python3.11/xml/etree/ElementTree.py", line 1218, in parse
    tree.parse(source, parser)
    File "/............................../Downloads/blender-4.2.1-linux-x64/4.2/python/lib/python3.11/xml/etree/ElementTree.py", line 580, in parse
    self._root = parser._parse_whole(source)
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^
    xml.etree.ElementTree.ParseError: not well-formed (invalid token): line 1, column 2

  • Hi @DADA_universe!
    Sorry for the very late reply.
    I think I fixed the problem: it was due to a change happened in Blender 4.1 related to the exportation of svg files.
    Now, with the last release of prj (0.0.9m), you should get the drawing capabilities back.
    Let me now if it works.
    Thanks!

    Bedson
Sign In or Register to comment.