Skip to content

Commit

Permalink
Initial commit
Browse files Browse the repository at this point in the history
  • Loading branch information
Alex1-111 committed Aug 3, 2024
1 parent fc928d4 commit 64c2c20
Show file tree
Hide file tree
Showing 9 changed files with 1,010 additions and 608 deletions.
20 changes: 20 additions & 0 deletions .androidide/editor/openedFiles.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
{
"allFiles": [
{
"file": "/storage/emulated/0/AndroidIDEProjects/WavePlayerView/README.md",
"selection": {
"end": {
"column": 65,
"index": 1806,
"line": 19
},
"start": {
"column": 65,
"index": 1806,
"line": 19
}
}
}
],
"selectedFile": "/storage/emulated/0/AndroidIDEProjects/WavePlayerView/README.md"
}
47 changes: 39 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,14 +45,14 @@ WavePlayerView is an advanced library for analyzing real-time audio and displayi
### 1. Add it in your root build.gradle at the end of repositories:

```gradle
dependencyResolutionManagement {
repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS)
repositories {
mavenCentral()
//...
maven { url 'https://jitpack.io' }
}
dependencyResolutionManagement {
repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS)
repositories {
mavenCentral()
//...
maven { url 'https://jitpack.io' }
}
}
```

### 2. Add the Library to Your Project
Expand All @@ -61,7 +61,7 @@ WavePlayerView is an advanced library for analyzing real-time audio and displayi
```gradle
dependencies {
implementation 'com.github.alex11111115:WavePlayerView:1.11'
implementation 'com.github.alex11111115:WavePlayerView:1.12'
}
```

Expand Down Expand Up @@ -90,6 +90,28 @@ dependencies {

> In your `MainActivity.java` file, you can control the `WavePlayerView` as follows:
> To start using it, you need to initialize it first
```java
public class MainActivity extends AppCompatActivity {

private WavePlayerView waveView;

//....

@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.main);

waveView = findViewById(R.id.waveView);

//.....

}
}
```


> To play from file path:
```java
// Play audio from a file path
Expand Down Expand Up @@ -220,6 +242,15 @@ waveView.setLooping(true);
if (waveView != null) {
waveView.release();
}

> To Wave1 Alpha
```java
waveView.setWave1Alpha(alpha1);
```

> To Wave2 Alpha
```java
waveView.setWave2Alpha(alpha2);
```

### Permissions
Expand Down
5 changes: 2 additions & 3 deletions WavePlayerView/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@ android {
defaultConfig {
minSdk 21
targetSdk 34
versionCode 1
versionName "1.11"
versionCode 2
versionName "1.12"
namespace "sound.wave.kilobyte"
}

Expand All @@ -35,7 +35,6 @@ android {

buildFeatures {
viewBinding true
//dataBinding true
}

packagingOptions {
Expand Down
Loading

0 comments on commit 64c2c20

Please sign in to comment.