Hi !
Featured games (85)
games approved by the League of Dukes
Games in Showcase (623)
Games in Android Showcase (176)
games submitted by our members
Games in WIP (676)
games currently in development
News: Read the Java Gaming Resources, or peek at the official Java tutorials
    Home     Help   Search   Login   Register   
Pages: [1]
  ignore  |  Print  
  silence detection in java  (Read 2396 times)
0 Members and 1 Guest are viewing this topic.
Offline emmi12345

Junior Newbie

Java games rock!

« Posted 2004-06-11 09:24:38 »

hi guys,

could any one help me on silence detection i will be very thank ful

thx in adavance
Offline oNyx

JGO Coder

Medals: 2

pixels! :x

« Reply #1 - Posted 2004-06-11 11:28:28 »

You... check for the silence(!)... and then *gasp* do the stuff.

Roll Eyes

Seriously, if you want usefull answers you should provide all the details you can get.

Ah well... I tell you this... there are two kinds of "silence". Digital absolute - there is nothing - silence and sound from let's say line-in or a mic and there is no real noise. The former is easy to ckeck and the latter needs to be some kind of fuzzy conditions. So instead of checking for a zero volume you check for let's say a volume wich is lower than 5% (or any other treshold).

Whenever the one or the other type occurs you set a marker and if it lasts for a specific timespan you found a pause/silence.

弾幕 ☆ @mahonnaiseblog
Offline emmi12345

Junior Newbie

Java games rock!

« Reply #2 - Posted 2004-06-11 12:09:07 »


infact i am making a system, in which i will detect is clients mic is connected.

for that i have to check silence for some seconds.

if for that time i didnt get any signal thus i will give message of "mic unplug".

i am capturing data in bytes.

now wat u suggest?
Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline swpalmer

JGO Coder

Exp: 12 years

Where's the Kaboom?

« Reply #3 - Posted 2004-06-11 15:04:01 »

Check that the amplitude of the input data does not exceed some threshold for N samples where N is based on the duration of silence your are trying to detect.

What is hard about this?  Am I missing something?

Offline emmi12345

Junior Newbie

Java games rock!

« Reply #4 - Posted 2004-06-12 03:32:02 »

i am receiving data in bytes and how i configure the amplitude bcz it shows differernt values for same scenario.

if i got the value of byte for silence it would be very ease.

Offline swpalmer

JGO Coder

Exp: 12 years

Where's the Kaboom?

« Reply #5 - Posted 2004-06-12 16:54:56 »

Are you using 8-bit samples?  (Typically these days you use 16-bit audio samples)

You need to know the format you have configured for the audio source.

E.g. signed vs. unsigned (w. offset), 8 or 16 bit.

Then it is easy.  for signed data silence is near 0,  for unsigned data silence is near the middle of the range.  Because of noise you will need to consider a band around the true silence value to be silence.

Pages: [1]
  ignore  |  Print  
You cannot reply to this message, because it is very, very old.

KaiHH (12 views)
2015-10-06 20:22:20

KaiHH (11 views)
2015-10-06 19:41:59

BurntPizza (19 views)
2015-10-06 19:04:48

basil_ (44 views)
2015-09-30 17:04:40

shadowstryker (22 views)
2015-09-29 15:55:06

TheSpaceHedgehog (28 views)
2015-09-29 01:58:48

GamerC4 (54 views)
2015-09-24 21:10:38

GamerC4 (71 views)
2015-09-24 21:09:48

htuy (28 views)
2015-09-24 04:57:24

htuy (38 views)
2015-09-24 04:56:35
Math: Inequality properties
by Roquen
2015-10-01 13:30:46

Math: Inequality properties
by Roquen
2015-09-30 16:06:05

HotSpot Options
by Roquen
2015-08-29 11:33:11

Rendering resources
by Roquen
2015-08-17 12:42:29

Rendering resources
by Roquen
2015-08-17 09:36:56

Rendering resources
by Roquen
2015-08-13 07:40:51

Networking Resources
by Roquen
2015-08-13 07:40:43

List of Learning Resources
by gouessej
2015-07-09 11:29:36 is not responsible for the content posted by its members, including references to external websites, and other references that may or may not have a relation with our primarily gaming and game production oriented community. inquiries and complaints can be sent via email to the info‑account of the company managing the website of java‑
Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines | Managed by Enhanced Four Valid XHTML 1.0! Valid CSS!