Povray: clean code exported by inkScape using notepad++

When exporting paths from inkscape to blender the resulting file can be very large. We can reduce the file size by removing unused decimal zeros, eg “12.00000” would become “12”. We can use regular expressions notepad++ to do. Open the .pov file in notepad++ and in the Replace dialog box (Ctrl+H) select the Regular expression np_regexp_pov_en In the text field Find what: copy and paste the expression:
(\.(?:\d*[1-9])?)(0+)(,|>|;)
And in Replace with::
\1\3
Pressing Replace All clean it useless zeros code

Leave a Reply

Your email address will not be published. Required fields are marked *