You are not logged in.

#1 2005-03-30 14:19:01

dp
Member
From: Zürich, Switzerland
Registered: 2003-05-27
Posts: 3,378
Website

image to mesh for POVray or blender [solution inside]

i have a png with one colour and transperency (black/white drawing)

i want to make a mesh out of it to be used in povray or blender.

is there a way to do it automatically?
i searched the web but every resource i found tells me how to export a rendering graphics to png :-(

thanx in advance


The impossible missions are the only ones which succeed.

Offline

#2 2005-03-30 14:35:41

dp
Member
From: Zürich, Switzerland
Registered: 2003-05-27
Posts: 3,378
Website

Re: image to mesh for POVray or blender [solution inside]

one step closer: i managed to convert it to an xfig drawing using autotrace ... now it's vectorized ... what now?


The impossible missions are the only ones which succeed.

Offline

#3 2005-03-30 19:10:14

neri
Forum Fellow
From: Victoria, Canada
Registered: 2003-05-04
Posts: 553

Re: image to mesh for POVray or blender [solution inside]

dp wrote:

one step closer: i managed to convert it to an xfig drawing using autotrace ... now it's vectorized ... what now?

there is a set of scripts which are available from the web or also somwhere in the endless ranges of www. If you are not sure, download the statically linke dversion of blender, it's also included in their tarball.

copy the directory scripts and bpydata to ~/.blender/scripts and ~/.blender/bpydata maybe also the Bpymenus file to  ~/.blender. Note there seems no way to make this stuff available systemwide, at least I didn't find one hmm

now open blender, use the button you find in every window in the lower most left corner, press it and select "Scripts" then use the new "Scripts" menu entry in this window , select import->paths and choose the file format you want. It doesn't always work and I found eps and ai more relaiable that svg for this job.

good luck,
neri

Offline

#4 2005-03-30 20:29:20

dp
Member
From: Zürich, Switzerland
Registered: 2003-05-27
Posts: 3,378
Website

Re: image to mesh for POVray or blender [solution inside]

neri, thank you very much for the explaination

i searched the www ... what i found is here:

http://www.blender3d.com/cms/Import___Export.5.0.html

http://www.janw.gothere.uk.com/import.html

http://www-users.cs.umn.edu/~mein/blend … rt_export/

http://www.redrival.com/scorpius/blender-plugins.htm

and FINALLY!!! i found this:

http://jmsoler.free.fr/didacticiel/blen … import.htm

and now i know what i did wrong in the beginning: i was searching in english and german but forgot to try it in french :oops:

about the systemwide installation of the scripts: it of course would be great that we would be able to make a package of these helper scripts ... but for now copying around does the job


The impossible missions are the only ones which succeed.

Offline

#5 2005-03-30 20:55:32

dp
Member
From: Zürich, Switzerland
Registered: 2003-05-27
Posts: 3,378
Website

Re: image to mesh for POVray or blender [solution inside]


The impossible missions are the only ones which succeed.

Offline

#6 2005-03-30 21:44:31

dp
Member
From: Zürich, Switzerland
Registered: 2003-05-27
Posts: 3,378
Website

Re: image to mesh for POVray or blender [solution inside]

Traceback (most recent call last):
  File "/home/damir/.blender/scripts/mod_svg2obj.py", line 648, in fonctionSELECT
    scan_FILE(nom)
  File "/home/damir/.blender/scripts/mod_svg2obj.py", line 616, in scan_FILE
    courbes,n0,CP=Actions[cell]([cell,cursor], D, n0,CP)
  File "/home/damir/.blender/scripts/mod_svg2obj.py", line 295, in mouvement_vers
    CP=[l[0],l[1]]
IndexError: list index out of range

:-(


The impossible missions are the only ones which succeed.

Offline

#7 2005-03-30 22:09:15

neri
Forum Fellow
From: Victoria, Canada
Registered: 2003-05-04
Posts: 553

Re: image to mesh for POVray or blender [solution inside]

dp wrote:
Traceback (most recent call last):
  File "/home/damir/.blender/scripts/mod_svg2obj.py", line 648, in fonctionSELECT
    scan_FILE(nom)
  File "/home/damir/.blender/scripts/mod_svg2obj.py", line 616, in scan_FILE
    courbes,n0,CP=Actions[cell]([cell,cursor], D, n0,CP)
  File "/home/damir/.blender/scripts/mod_svg2obj.py", line 295, in mouvement_vers
    CP=[l[0],l[1]]
IndexError: list index out of range

:-(

As quoted above, svg isn't really the way to go sad
Once I used the Archlinux SVG (just the arch, which is a 4 or 5 node path)
but even this failed ... So I converted the very same file into an EPS and
it worked. Don't hesitate to add inkscape to your tool-chain smile
Just "Save as" ->eps and you should be done

-neri

Offline

#8 2005-03-30 22:33:52

dp
Member
From: Zürich, Switzerland
Registered: 2003-05-27
Posts: 3,378
Website

Re: image to mesh for POVray or blender [solution inside]

i tried eps first, as you said, but with it, it gives me a even more strange error:

[...]
len(t) 538
529
len(t) 538
530
len(t) 538
531
len(t) 538
532
len(t) 538
533
len(t) 538
534
len(t) 538
535
len(t) 538
536
len(t) 538
537
Traceback (most recent call last):
  File "<string>", line 423, in fonctionSELECT
  File "<string>", line 410, in scan_FILE
  File "<string>", line 173, in Open_GEOfile
AttributeError: requested file doesn't exist!

The impossible missions are the only ones which succeed.

Offline

#9 2005-03-30 22:56:29

dp
Member
From: Zürich, Switzerland
Registered: 2003-05-27
Posts: 3,378
Website

Re: image to mesh for POVray or blender [solution inside]

I GOT IT!

it didn't liked the eps file inkscape created ... i tried plain PS and it worked!!!! thank you for helping and holding my hand ;-)


The impossible missions are the only ones which succeed.

Offline

#10 2005-03-30 23:07:41

neri
Forum Fellow
From: Victoria, Canada
Registered: 2003-05-04
Posts: 553

Re: image to mesh for POVray or blender [solution inside]

dp wrote:

I GOT IT!

it didn't liked the eps file inkscape created ... i tried plain PS and it worked!!!! thank you for helping and holding my hand ;-)

This was not for free!!

... I wanna see the result smile

-neri

Offline

#11 2005-03-31 02:16:51

dp
Member
From: Zürich, Switzerland
Registered: 2003-05-27
Posts: 3,378
Website

Re: image to mesh for POVray or blender [solution inside]

neri wrote:
dp wrote:

I GOT IT!

it didn't liked the eps file inkscape created ... i tried plain PS and it worked!!!! thank you for helping and holding my hand ;-)

This was not for free!!

... I wanna see the result smile

-neri

the result is not yet ready ... i'm still experimenting (3d modelling can make you forget time)

the original 2d:

logo-CP_verysmall.gif

and the 3d now in blender:

cplogo_test.png


The impossible missions are the only ones which succeed.

Offline

#12 2005-03-31 13:03:54

neri
Forum Fellow
From: Victoria, Canada
Registered: 2003-05-04
Posts: 553

Re: image to mesh for POVray or blender [solution inside]

this is a nice result, looks good, though Im not a real fan of the chrome/shiny
surfaces stuff. But for this logo it works well.

-neri

Offline

#13 2005-03-31 13:18:32

dp
Member
From: Zürich, Switzerland
Registered: 2003-05-27
Posts: 3,378
Website

Re: image to mesh for POVray or blender [solution inside]

neri wrote:

this is a nice result, looks good, though Im not a real fan of the chrome/shiny
surfaces stuff. But for this logo it works well.

-neri

thank you.

i had to do some parts by hand because they were wrongly imported (the curve was imported with some wrong connections between points and the "toggle cyclic" made some holes in the letters (e.g. in the B and P) do not appear) this manipulations took me some minutes ... but for more complex things, i can imagine that it is a pain having to clean the curve before transforming it to a mesh ...

anyway : many thanx for the hints ... as i did all 2d-things in SVG i have now to export them first to PS before playing with them in 3d - this is a really important information that does not exist anywhere on the web!

smile


The impossible missions are the only ones which succeed.

Offline

Board footer

Powered by FluxBB