cordova-plugin-media icon indicating copy to clipboard operation
cordova-plugin-media copied to clipboard

Fix for CB-10882 : Plugin Media - "cordova-plugin-media" 2.2.0 seem have a "position" bug with mediaSound.getCurrentPosition method

Open ThillaiganeshChan opened this issue 8 years ago • 17 comments

…ave a "position" bug with mediaSound.getCurrentPosition method.

Added a Check for Recorder also in 'getCurrentPositionAudio'

ThillaiganeshChan avatar Mar 18 '16 10:03 ThillaiganeshChan

When I play a mp3 in 2.2.0 @ ios. No sound come out. I am not sure it related to this fix or not.

sonicwong avatar Apr 08 '16 07:04 sonicwong

@ThillaiganeshChan, please update this PR's title to use the correct JIRA ticket number. The title for CB-10822 is "Deduplicate common logic for storing modules metadata in cordova_plugins.js" and is not related to this change

vladimir-kotikov avatar Apr 08 '16 08:04 vladimir-kotikov

@sonicwong it's not related to this as this PR is related to getPosition for recordings.

There was however, recently a PR merged that fixed playback of local files where no protocol prefix was set.

I would suggest trying the latest version of the plugin installed directly from github with:

cordova plugin add https://github.com/apache/cordova-plugin-media.git

ghenry22 avatar Apr 08 '16 08:04 ghenry22

hi @ThillaiganeshChan and @vladimir-kotikov I am the bug reporter is there anything update ? or ... https://issues.apache.org/jira/browse/CB-10882

bau720123 avatar Apr 29 '16 15:04 bau720123

Cordova CI Build has one or more failures.

Commit - Link Dashboard - Link

Builder Name Console Output Test Report Device Logs
Windows 8.1 Store Link Link Link
Windows 10 Store Link Link Link
Windows 8.1 Phone Link Link Link
iOS Link Link Link
Android Mac Link Link Link

cordova-qa avatar May 18 '16 00:05 cordova-qa

Let there be tests

sarangan12 avatar May 18 '16 01:05 sarangan12

Cordova CI Build has one or more failures.

Commit - Link Dashboard - Link

Builder Name Console Output Test Report Device Logs
Windows 8.1 Store Link Link Link
Windows 10 Store Link Link Link
Windows 8.1 Phone Link Link Link
iOS Link Link Link
Android Mac Link Link Link

cordova-qa avatar May 18 '16 01:05 cordova-qa

hello guys this bug have been reported three months ago https://issues.apache.org/jira/browse/CB-10882 is there any update or ... ???

bau720123 avatar Jun 12 '16 12:06 bau720123

Just reading through your steps to reproduce in Jira and wanted to check where you are seeing the problem.

First you make a recording (this seems to work).

You then call getCurrentPosition().

Before calling getCurrentPosition(), have you stopped the recording, saved it and then created a new media object with the recording as SRC, called media.play() and then getCurrentPosition()?

I am going to do some testing and have a look at it, I just want to be really clear about where the problem is.

ghenry22 avatar Jun 13 '16 00:06 ghenry22

hi @ghenry22,thanks your reply

in "cordova-plugin-media" 2.2.0 yes,Before calling getCurrentPosition(), I stop the recording,after that,use getCurrentPosition()

but in "cordova-plugin-media" 2.3.0,I can't reproduce it,because it seem appear another problem https://issues.apache.org/jira/browse/CB-11418

you can try 2.2.0 or 2.3.0,you will know what I mean

bau720123 avatar Jun 13 '16 05:06 bau720123

well...@ghenry22 7 days passed is there any unclear or anything that I should explain once again ?

bau720123 avatar Jun 20 '16 13:06 bau720123

2 months passed anything wrong ?

bau720123 avatar Aug 24 '16 12:08 bau720123

really sad... https://issues.apache.org/jira/browse/CB-11867 this is a critical bug!but Cordova team Disregard it for a long time...

@ThillaiganeshChan way still not solve the problem https://github.com/apache/cordova-plugin-media/pull/87/commits/4deef091a3fe55f20d929a103d71d4c1747e5ab3

bau720123 avatar Sep 23 '16 15:09 bau720123

Pull Requests are welcome

jcesarmobile avatar Sep 23 '16 18:09 jcesarmobile

fixed by myself...

bau720123 avatar Sep 24 '16 07:09 bau720123

how did you fix it?

jcesarmobile avatar Sep 25 '16 22:09 jcesarmobile

hi @jcesarmobile mediaRec.stopRecord(); if(navigator.userAgent.match(/iPad|iPhone|iPod/i)) { mediaRecord.release(); //otherwise,it will crash immediately } if(navigator.userAgent.match(/Android/i)) { //do nothing,if use "release" method too,it will cause "record" method fail}

bau720123 avatar Sep 26 '16 01:09 bau720123