Update README.md

pull/686/head
Sahib 2 years ago committed by GitHub
parent bccef83245
commit 9b1400c8f6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 18
      android/README.md

@ -9,16 +9,16 @@
- Creates Android archive with .aar extension - Creates Android archive with .aar extension
### 2) BUILDING (Is after `Using with Python`) ### 2) BUILDING (Is after `Using with Python`)
### USE PREBUILT PACKAGE FROM RELEASES SECTION ### USE PREBUILT PACKAGE FROM RELEASES SECTION
### 3. Using With Python ### 3. Using With Python
1) Add the aar from Releases tab or the one generated by you to your projects folder. ##### 1) Add the aar from Releases tab or the one generated by you to your projects folder.
2) In Buildozer spec file add jnius to requirements and the aar file. ##### 2) In Buildozer spec file add jnius to requirements and the aar file.
``` ```
requirements = jnius requirements = jnius
android.add_aars = ffmpeg-kit-release.aar android.add_aars = ffmpeg-kit-release.aar
``` ```
3) Using Pyjnius, declare the variables in Python (https://pyjnius.readthedocs.io/en/stable/) ##### 3) Using Pyjnius, declare the variables in Python (https://pyjnius.readthedocs.io/en/stable/)
``` ```
#IMPORTING jnius #IMPORTING jnius
from jnius import autoclass from jnius import autoclass
@ -28,7 +28,7 @@ FFMPEG = autoclass('com.sahib.pyff.ffpy')
``` ```
BOTH (FFMPEG and FFPROBE) RETURN OUTPUT OF THE COMMAND BOTH (FFMPEG and FFPROBE) RETURN OUTPUT OF THE COMMAND
4) To Use FFMPEG ##### 4) To Use FFMPEG
``` ```
#EXECUTED FFMPEG COMMAND, COMMAND IS STRING #EXECUTED FFMPEG COMMAND, COMMAND IS STRING
ffmpegCommand = FFMPEG.Run("COMMAND") ffmpegCommand = FFMPEG.Run("COMMAND")
@ -37,7 +37,7 @@ ffmpegCommand = FFMPEG.Run("COMMAND")
print(ffmpegCommand) print(ffmpegCommand)
``` ```
5) To use FFProbe ##### 5) To use FFProbe
``` ```
#EXECUTED FFProbe COMMAND, COMMAND IS STRING #EXECUTED FFProbe COMMAND, COMMAND IS STRING
probeCommand = FFMPEG.RunProbe("Command") probeCommand = FFMPEG.RunProbe("Command")
@ -50,8 +50,8 @@ NOTE - FILTER_COMPLEX can not be used. (IDK why, if you have solution tell me pl
EXAMPLES #### EXAMPLES
1) FFMPEG ##### 1) FFMPEG
``` ```
from jnius import autoclass from jnius import autoclass
from jnius import * from jnius import *
@ -68,7 +68,7 @@ print(d)
``` ```
2) FFProbe ##### 2) FFProbe
``` ```
from jnius import autoclass from jnius import autoclass
from jnius import * from jnius import *

Loading…
Cancel
Save