Difference between revisions of "Math rendering"
From Organic Design wiki
(point to math extraction issue in here) |
m |
||
Line 1: | Line 1: | ||
− | + | == See also == | |
− | = See also = | ||
*[[:Category:Articles containing maths|Articles containing maths]] | *[[:Category:Articles containing maths|Articles containing maths]] | ||
*[http://www.wikitex.org www.wikitex.org] | *[http://www.wikitex.org www.wikitex.org] | ||
*[http://www.wikisophia.org www.wikisophia.org] | *[http://www.wikisophia.org www.wikisophia.org] | ||
− | = Issues = | + | == Issues == |
There was a problem extracting the database on 13/11 due to duplicate entries in the math table, see [[13 November 2006]]. | There was a problem extracting the database on 13/11 due to duplicate entries in the math table, see [[13 November 2006]]. | ||
− | = Example = | + | == Example == |
The following maths code | The following maths code | ||
<table class=document-code><tr><td> | <table class=document-code><tr><td> | ||
Line 20: | Line 19: | ||
</table> | </table> | ||
− | = Transparency = | + | == Transparency == |
I replaced the line defining the ImageMagick ''convert'' command in ''/wiki/math/render.ml'' which makes it output a transparent PNG and also increases the quality by rendering the vector larger and downsizing with the default ''Mitchell'' filter. After making changes to ''render.ml'', you must rebuild the ''texvc'' executable by issuing a ''make clean'' and ''make''. | I replaced the line defining the ImageMagick ''convert'' command in ''/wiki/math/render.ml'' which makes it output a transparent PNG and also increases the quality by rendering the vector larger and downsizing with the default ''Mitchell'' filter. After making changes to ''render.ml'', you must rebuild the ''texvc'' executable by issuing a ''make clean'' and ''make''. | ||
<table class=document-code><tr><td> | <table class=document-code><tr><td> | ||
Line 30: | Line 29: | ||
</pre> | </pre> | ||
</table> | </table> | ||
+ | [[Category:Articles containing maths]][[Category:Examples]][[Category:XmlWiki]] |
Revision as of 22:29, 16 September 2007
Contents
See also
Issues
There was a problem extracting the database on 13/11 due to duplicate entries in the math table, see 13 November 2006.
Example
The following maths code
<math>
</math> |
Gives the following output
[math]e^x = \sum_{n = 0}^{\infty} {x^n \over n!} = 1 + x + {x^2 \over 2!} + {x^3 \over 3!} + {x^4 \over 4!} + \cdots[/math] |
Transparency
I replaced the line defining the ImageMagick convert command in /wiki/math/render.ml which makes it output a transparent PNG and also increases the quality by rendering the vector larger and downsizing with the default Mitchell filter. After making changes to render.ml, you must rebuild the texvc executable by issuing a make clean and make.
let cmd_convert tmpprefix finalpath = "convert -quality 100 -density 480 " \ ^ tmpprefix ^ ".ps -negate -unsharp 8 -resize 25% " ^ finalpath ^ " >/dev/null 2>/dev/null \ && convert " ^ finalpath ^ " -fill black -colorize 100% " ^ finalpath ^ ".png \ && composite -compose CopyOpacity " ^ finalpath ^ " " ^ finalpath ^ ".png " ^ finalpath |