I have just started learning Java and I have to deliver a assignment in Which I have to read an Audio (.wav) File and Create echo effect of the audio file and save it without using any external library. Kindly guide me from where exactly to start. Although I have a basic knowledge about C++ upto functions and a little about Classes & Objects. Looking forward for the right direction as I am short of time!
Thanks.
You can find a working example here : http://www.java2s.com/Code/Java/Development-Class/Anexampleofplayingasoundwithanechofilter.htm
I've been learning Java for a month now. I've already managed to code some very simple stuff like prime number generator and a simple calculator. Now i'd love to try working on something more complex.
Here's my idea - I'd love to make a program that can copy pictures from SD card or USB with a single click (something that my parents can use very easily to copy all their photos to a folder without my help)
I was brainstorming quite a bit about it and before i start i want to ask following questions:
1. Are there any inbuilt Java methods that can help me with the following task?
2. What are the other (non-beginner) Java features that i'd need to read about?
I want to start it from the scratch, make it simple at first and progressively add more features to practice and learn some more.
Any pointers or tips much appreciated.
I'd suggest doing this as a script. The script can invoke java if you'd like to improve your java skills. However, scripting languages can also copy/move files very easily. If you choose java, read about file I/O, reading files, writing files, etc.
Here's a link for windows. Not sure what your operating system is, but you could create an executable script on mac, linux, etc.
http://www.wikihow.com/Write-a-Batch-File
Has anyone managed to use acoustid (http://acoustid.org/chromaprint) in an Java application? Accessing the chromaprint clib should be easy but I can't just pass in the audio file. I requires the raw uncompressed audio data.
I've tried using xuggler to get the uncompressed audio but didn't get anywhere. Basically I have no idea how to get the raw audio from encoded files like mp3/m4a/etc
Has anybody managed to make this work? Anyone mind sharing their code?
I suggest you use the fpcalc command line tool (included in Chromaprint, binaries for Windows/Mac/Linux are included on the website), run it in a subprocess from your Java application. You get output like this, which should be easy to parse:
FILE=/path/to/file.mp3
DURATION=398
FINGERPRINT=AQADtEqkRIkkrQ...
That's how most programs integrate AcoustID and I believe it's the easiest way.
I am about to make an app on android but I have 0 experience about it.
This project is important and kind of a big challenge to me.
With that being said, I will try my best to explain about it so you guyz can give me an accurate approach
So assuming I have a program written in C,C++. Either an .exe or bunch of library.
What this executable do is to process the data and generate a file with bunch of binary and weird output. This process is called pre-processing.
Then result file will then be fed into Matlab or python and the graphical result will be generated. This is called post-processing and also the final goal.
Right now I can't afford to get matlab installed so my boss only asked me to go up to the pre-processing part.
The project will be displaying the pre-processing on the screen of a android device even if it might be unreadable.
I have done some research and found several ways to accomplish this:
1/ write a simple app using java and use JNI to call the main function of the .exe
2/ write a simple app using c++ and get the result straight from the .exe
That's all i can come up with, can any expert give me some suggestions please.
I am looking for a solution that would get me pass the pre-processing phase but also be efficient and easy if I get a chance to work on post-processing phase later.
Thank you very much
I am currently making a project for school, where I am going to make a program which teaches children how to read. My basic idea for the program was produce the sentence and then get Windows Anna to say it. My question to you is, how can I access Winodws Anna through Java? and is there a better way of doing this?
Thanks
If having the program access internet is acceptable, then you could use iSpeech.
You can use their API, but the problem with that is that it is limited to 200 uses/day.
iSpeech has decently sounding voices, generally more polished than other TTS engines I've tired like espeak or FreeTTS, because it actually pronounces the words more fluently. Sure, it might pronounce 'Wind', relating with air, as 'Wind', relating to twisting, but other than that, it speaks quite well.
Also, while I haven't had any prior experience with this, I found an article that shows you how to access the MS Speech with command line (which can obviously be commanded through Java[if you do not know how, here is a good article]). It is located here. In command line, all you do is type in 'SayDynamic.exe* the text you want to speak".
*Or SayStatic, the other download available on the page.
This method seems to be better in terms of speed and not relying on internet access, but it definitely does NOT pronounce things as well as iSpeech. I guess the ideal thing for your program to have would be to use iSpeech when online, and use the Say*.exe when offline.
The site also provides the source code of the program. As you might notice, it is NOT Microsoft Anna's voice, but you can specify that in the source and recompile it.
Hope I helped!
You can use command line utiity NirCmd that uses text-to-speech API installed on Windows.
So, supply this utility together with your java application and run it with appropriate command line.
You can try FreeTTS : a speech synthesizer written in java.
You can try to call the Microsoft Speech API (SAPI) but I don't know how to do it in java.
Can you tell us how you invoke NirCmd ?
Altenatively to NirCmd, you can build your own tool in C# that will read the text. The text could be within a txt and your tool invoked with the path to that txt as argument. You can easily adapt a demo project like this one : http://www.codeproject.com/Articles/19334/Text-to-Speech-using-Windows-SAPI
There is the Speech platform of Windows
http://www.microsoft.com/en-us/download/details.aspx?id=27226
The Speech runtime
http://www.microsoft.com/en-us/download/details.aspx?id=27225
You can use JNA (not JNI) to interact with dll from java
https://github.com/twall/jna