{"id":3635,"url":"https://github.com/alhazmy13/MediaRecorderDialog","last_synced_at":"2025-08-03T22:31:57.658Z","repository":{"id":88125487,"uuid":"48539423","full_name":"alhazmy13/MediaRecorderDialog","owner":"alhazmy13","description":"Android has a built in microphone through which you can capture audio and store it , or play it in your phone. There are many ways to do that but with this dialog you can do all thats with only one dialog.","archived":false,"fork":false,"pushed_at":"2016-11-05T16:40:50.000Z","size":649,"stargazers_count":73,"open_issues_count":3,"forks_count":12,"subscribers_count":6,"default_branch":"master","last_synced_at":"2024-08-16T15:39:30.662Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"http://alhazmy13.net","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/alhazmy13.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"License.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null}},"created_at":"2015-12-24T11:06:05.000Z","updated_at":"2024-08-04T17:44:35.000Z","dependencies_parsed_at":"2023-04-24T23:47:34.447Z","dependency_job_id":null,"html_url":"https://github.com/alhazmy13/MediaRecorderDialog","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alhazmy13%2FMediaRecorderDialog","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alhazmy13%2FMediaRecorderDialog/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alhazmy13%2FMediaRecorderDialog/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alhazmy13%2FMediaRecorderDialog/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/alhazmy13","download_url":"https://codeload.github.com/alhazmy13/MediaRecorderDialog/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":228571844,"owners_count":17938772,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-01-05T20:16:47.078Z","updated_at":"2024-12-07T06:30:33.809Z","avatar_url":"https://github.com/alhazmy13.png","language":"Java","funding_links":[],"categories":["Media","Libraries"],"sub_categories":["Chat \u0026 Messaging"],"readme":"\u003cp align=\"center\"\u003e\n  \u003cimg src=\"https://cloud.githubusercontent.com/assets/4659608/12700283/c3072022-c7ee-11e5-8862-6b73f90c3066.png\" \u003e\n\u003c/p\u003e\n# Media Recorder Dialog\n![](https://img.shields.io/badge/Platform-Android-brightgreen.svg)\n![](https://img.shields.io/badge/Android-CustomView-blue.svg)\n![](https://img.shields.io/crates/l/rustc-serialize.svg)\n![](https://img.shields.io/badge/version-1.0.0-blue.svg)\n\n------ \nAndroid has a built in microphone through which you can capture audio and store it , or play it in your phone. There are many ways to do that but with this dialog you can do all thats with only one dialog.\n\nYou can report any issue on issues page. **Note: If you speak Arabic, you can submit issues with Arabic language and I will check them. :)**\n\n![mediarecorderdialog](https://cloud.githubusercontent.com/assets/4659608/11994579/303214a0-aa52-11e5-9d91-0e88e6b4da4c.gif)\n\n\n\n## Installation\n------ \n**Maven**\n```xml\n\u003cdependency\u003e\n\u003cgroupId\u003enet.alhazmy13.MediaRecorderDialog\u003c/groupId\u003e\n\u003cartifactId\u003elibary\u003c/artifactId\u003e\n\u003cversion\u003e1.0.0\u003c/version\u003e\n\u003c/dependency\u003e\n```\n\n\n**Gradle**\n```gradle\n\ndependencies {\n\tcompile 'net.alhazmy13.MediaRecorderDialog:libary:1.0.0'\n}\n```\n\n# Usage\n------ \n```java\n\n new MediaRecorderDialog.Builder(MainActivity.this)\n    .setOutputFormat(MediaRecorderDialog.OutputFormat.MPEG_4)\n    .setAudioEncoder(MediaRecorderDialog.AudioEncoder.AAC)\n    .setTitle(\"Recording,,,\")\n    .setMessage(\"Press the button\")\n    .setOnSaveButtonClickListener(new OnSaveButtonClickListener() {\n        @Override\n        public void onSucceed(String path) {\n            // Toast.makeText(MainActivity.this,path,Toast.LENGTH_SHORT).show();\n        }\n        @Override\n        public void onFailure() {\n            //Toast.makeText(MainActivity.this,\"Failure\",Toast.LENGTH_SHORT).show();\n        }\n    })\n    .show();\n\n```\n\n### Implement an `OnSaveButtonClickListener`\nIn order to receive the path of file, you will need to implement the `OnSaveButtonClickListener` interfaces. \n```java\n    @Override\n    public void onSucceed(String path) {\n        //Your Code\n    }\n    @Override\n    public void onFailure() {\n        //Your Code\n    }\n```\n\n### Additional Options\n* `setTitle` You can change the title of Dialog \n```java\n.setTitle(\"Recording,,,\")\n```\n* `setMessage` to change the message  \n```java\n.setMessage(\"Press the button\")\n```\n* `setOutputFormat` You can change the Output format by passing the format from  `MediaRecorderDialog.OutputFormat`\n```java\n.setOutputFormat(MediaRecorderDialog.OutputFormat.MPEG_4)\n```\n* `setAudioEncoder` You can change the  Encoder by passing the value from  `MediaRecorderDialog.AudioEncoder`\n```java\n.setAudioEncoder(MediaRecorderDialog.AudioEncoder.AAC)\n```\n### Theme and style\nYou can theme the dialog by overwriting the color resources in your project.\n```xml\n    \u003ccolor name=\"media_recorder_colorPrimary\"\u003e#00796B\u003c/color\u003e\n    \u003ccolor name=\"media_recorder_background\"\u003e#009688\u003c/color\u003e\n    \u003ccolor name=\"media_recorder_bar\"\u003e#80CBC4\u003c/color\u003e\n```\n### Credits \n* [Gota Library](https://github.com/alhazmy13/Gota) \n* [AndroidViewAnimations](https://github.com/daimajia/AndroidViewAnimations).\n* [Android Ripple Background Library](https://github.com/skyfishjy/android-ripple-background) \n\n\n## License\n------ \n\n\u003e Copyright (c) 2016 Abdullah Alhazmy\n\n\u003e MIT License\n\n\u003e Permission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the \"Software\"), to deal\nin the Software without restriction, including without limitation the rights\nto use, copy, modify, merge, publish, distribute, sublicense, and/or sell\ncopies of the Software, and to permit persons to whom the Software is\nfurnished to do so, subject to the following conditions:\nThe above copyright notice and this permission notice shall be included in all\ncopies or substantial portions of the Software.\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\nOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\nSOFTWARE.\n\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Falhazmy13%2FMediaRecorderDialog","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Falhazmy13%2FMediaRecorderDialog","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Falhazmy13%2FMediaRecorderDialog/lists"}