HBRecorder

Additional

Language
Java
Version
0.1.11 (Jul 30, 2020)
Created
Aug 14, 2019
Updated
Aug 11, 2020
Owner
Hagen Brooks (HBiSoft)
Contributors
指尖上的艺术 (FingerArt)
Hagen Brooks (HBiSoft)
2
Activity
Badge
Generate
Download
Source code
APK file

Advertisement

HBRecorder

Lightweight screen and audio recording Android library Requires API level 21>


If you are using this library in one of your applications and would like to thank me:



Implement library in your app level build.gradle:

dependencies {
    implementation 'com.github.HBiSoft:HBRecorder:0.1.11'
}

Implementing the library:

  1. In your Activity, first implement HBRecorder, as shown below:
public class MainActivity extends AppCompatActivity implements HBRecorderListener {
  1. Alt+Enter to implement the following methods:
@Override
public void HBRecorderOnStart() {
    //When the recording starts
}

@Override
public void HBRecorderOnComplete() {
    //After file was created
}
@Override
public void HBRecorderOnError(int errorCode) {
    //When an error occurs
}
  1. Init HBRecorder as shown below:
public class MainActivity extends AppCompatActivity implements HBRecorderListener {
    HBRecorder hbRecorder;

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

        //Init HBRecorder
        hbRecorder = new HBRecorder(this, this);        

}
  1. Add the following permissions in your manifest:
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
<uses-permission android:name="android.permission.WRITE_INTERNAL_STORAGE" />
<uses-permission android:name="android.permission.RECORD_AUDIO" />
<uses-permission android:name="android.permission.FOREGROUND_SERVICE" />

That's it, HBRecorder is now ready to be used.