- May 11, 2011
-
-
Dmitry Chestnykh authored
-
Dmitry Chestnykh authored
-
Dmitry Chestnykh authored
Server accepts parameter lang, e.g. xxx.wav?lang=en. NewAudio and WriteAudio accept the target language.
-
- May 08, 2011
-
-
Dmitry Chestnykh authored
-
Dmitry Chestnykh authored
-
- May 04, 2011
-
-
Dmitry Chestnykh authored
-
Dmitry Chestnykh authored
-
- May 01, 2011
-
-
Dmitry Chestnykh authored
-
Dmitry Chestnykh authored
At last! [RIFF][following size][WAVE]fmt[...]...data[data size][padded data]. Also, update example.wav.
-
Dmitry Chestnykh authored
-
Dmitry Chestnykh authored
This is specified in RIFF format, but I forgot to implement. ckData Binary data of fixed or variable size. The start of ckData is word-aligned with respect to the start of the RIFF file. If the chunk size is an odd number of bytes, a pad byte with value zero is written after ckData. Word aligning improves access speed (for chunks resident in memory) and maintains compatibility with EA IFF. The ckSize value does not include the pad byte. (From http://www.kk.iij4u.or.jp/~kondo/wave/mpidata.txt)
-
- Apr 29, 2011
-
-
Dmitry Chestnykh authored
-
Dmitry Chestnykh authored
-
- Apr 28, 2011
-
-
Dmitry Chestnykh authored
Captcha ids are now 20 characters long.
-
Dmitry Chestnykh authored
-
Dmitry Chestnykh authored
-
Dmitry Chestnykh authored
This simplifies code and makes it faster. It also produces smaller PNGs. Before: captcha.BenchmarkNewImage 500 6198230 ns/op captcha.BenchmarkImageWriteTo 100 17517110 ns/op 0.14 MB/s After: captcha.BenchmarkNewImage 500 3869968 ns/op captcha.BenchmarkImageWriteTo 200 7237604 ns/op 0.23 MB/s (Core 2 Duo @ 2.26 GHz, MacBook) Currently the background is white, not transparent, because PNG encoder doesn't support paletted images with alpha channel. Submitted CL: http://codereview.appspot.com/4432078 Change alpha to 0x00 once it's accepted to make captcha transparent.
-
Dmitry Chestnykh authored
-
Dmitry Chestnykh authored
Also, audio benchmark uses the new ioutil.Discard.
-
Dmitry Chestnykh authored
Instead, change level of individual reversed sounds when making background to the appropriate values. This speeds up makeBackgroundSound ~3%. Before and after. captcha.BenchmarkNewAudio 50 30436940 ns/op captcha.BenchmarkNewAudio 50 29435780 ns/op Also, level up white noise a bit.
-
Dmitry Chestnykh authored
Also: - use ranges everywhere - optimize makeWhiteNoise a bit Before and after: captcha.BenchmarkNewAudio 50 32128580 ns/op captcha.BenchmarkNewAudio 50 30436940 ns/op
-
Dmitry Chestnykh authored
-
- Apr 27, 2011
-
-
Dmitry Chestnykh authored
-
Dmitry Chestnykh authored
-
Dmitry Chestnykh authored
-
Dmitry Chestnykh authored
For the standard size and width with new font they no longer had any effect anyway (were always +0).
-
Dmitry Chestnykh authored
-
Dmitry Chestnykh authored
-
Dmitry Chestnykh authored
NewLen is now like the old New (accepts captcha length as the argument). Also, rename StdLength to DefaultLen.
-
Dmitry Chestnykh authored
Garbage collection is an internal detail of a Store, and requiring to export this method seem to be not very useful. The default memory store, of course, still has garbage collection, but it's not the unexported method, called in Set as usual.
-
Dmitry Chestnykh authored
-
Dmitry Chestnykh authored
-
Dmitry Chestnykh authored
-
Dmitry Chestnykh authored
-
Dmitry Chestnykh authored
-
Dmitry Chestnykh authored
-
Dmitry Chestnykh authored
-
Dmitry Chestnykh authored
-
Dmitry Chestnykh authored
-
Dmitry Chestnykh authored
Use rndf instead of rand.Float64 voodoo.
-