Benchmarks can use ascii encoding
parent
33b3f1b3b4
commit
44cef753da
|
@ -1,6 +1,7 @@
|
||||||
IN: benchmark.mandel
|
IN: benchmark.mandel
|
||||||
USING: arrays io kernel math namespaces sequences strings sbufs
|
USING: arrays io kernel math namespaces sequences strings sbufs
|
||||||
math.functions math.parser io.files colors.hsv io.encodings.binary ;
|
math.functions math.parser io.files colors.hsv
|
||||||
|
io.encodings.ascii ;
|
||||||
|
|
||||||
: max-color 360 ; inline
|
: max-color 360 ; inline
|
||||||
: zoom-fact 0.8 ; inline
|
: zoom-fact 0.8 ; inline
|
||||||
|
@ -65,7 +66,6 @@ SYMBOL: cols
|
||||||
] with-scope ;
|
] with-scope ;
|
||||||
|
|
||||||
: mandel-main ( -- )
|
: mandel-main ( -- )
|
||||||
"mandel.ppm" temp-file
|
mandel "mandel.ppm" temp-file ascii set-file-contents ;
|
||||||
binary [ mandel write ] with-file-writer ;
|
|
||||||
|
|
||||||
MAIN: mandel-main
|
MAIN: mandel-main
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
|
|
||||||
USING: float-arrays compiler generic io io.files kernel math
|
USING: float-arrays compiler generic io io.files kernel math
|
||||||
math.functions math.vectors math.parser namespaces sequences
|
math.functions math.vectors math.parser namespaces sequences
|
||||||
sequences.private words io.encodings.binary ;
|
sequences.private words io.encodings.ascii ;
|
||||||
IN: benchmark.raytracer
|
IN: benchmark.raytracer
|
||||||
|
|
||||||
! parameters
|
! parameters
|
||||||
|
@ -170,7 +170,6 @@ DEFER: create ( level c r -- scene )
|
||||||
] "" make ;
|
] "" make ;
|
||||||
|
|
||||||
: raytracer-main
|
: raytracer-main
|
||||||
"raytracer.pnm" temp-file
|
run "raytracer.pnm" temp-file ascii set-file-contents ;
|
||||||
binary [ run write ] with-file-writer ;
|
|
||||||
|
|
||||||
MAIN: raytracer-main
|
MAIN: raytracer-main
|
||||||
|
|
Loading…
Reference in New Issue