Required
1. JSAPI – Java Lib to generate voice
2. FreeTTS – Open source library for converting text to speech
3. Jcaptcha – open source library for generating captcha image
4. Spring – Open source framework integrated with captcha to make easy integration with existing application.
Steps:
1. Download from the site - http://sourceforge.net/projects/jcaptcha/files/
2. Guide to integrate with spring http://jcaptcha.octo.com/confluence/display/general/JCaptcha+and+the+SpringFramework
3. Download FreeTTS from - http://jcaptcha.octo.com/confluence/display/general/JCaptcha+and+the+SpringFramework
To know more about these libraries follow - http://freetts.sourceforge.net/docs/index.php
4. Go to freetts-1.2\lib folder and run ‘jsapi.sh’ for unix/solaris & ‘jsapi.exe’ file for windows to generate environment specific ‘jsapi.jar’ file required to generate voice.
5. Add all jars available under \freetts-1.2\lib folder to domain classpath.
SET SPEECH_SYNTHESIS_HOME=F:/bea/JSAPI_LIB/jsapi.jar;F:/bea/JSAPI_LIB/freetts.jar; set CLASSPATH=%PRE_CLASSPATH%;%WEBLOGIC_CLASSPATH%;%POST_CLASSPATH%;%WLP_POST_CLASSPATH%;%SPEECH_SYNTHESIS_HOME% |
6. Copy the speech.properties file from freetts-1.2 to F:\bea\jdk150_04\jre\lib
7. For sample code for Jcaptcha with sound go to –
Resources:
4.
Casey's advices
- render the characters with different colors
- make some characters darker than the background, and some lighter
- use gradient colors for the backgrounds and the characters
- dont align all the characters vertically
- dont make the answers words, so that a dictionary could be used
- use more characters and symbols
- use uppercase and lowercase characters
- use a different number of characters each time
- rotate some of the characters more drastically (i.e. upside down)
- do more overlapping of characters
- make some pixels of a single character not touching
- have grid lines that cross over the characters with their same color
- consider asking natural language questions
No comments:
Post a Comment