|
| 1 | +# pylottie |
| 2 | + |
| 3 | +> Auto-generated documentation for [pylottie](../../pylottie/__init__.py) module. |
| 4 | +
|
| 5 | +- [Pylottie](../README.md#pylottie-index) / [Modules](../README.md#pylottie-modules) / pylottie |
| 6 | + - [convertLottie2GIF](#convertlottie2gif) |
| 7 | + - [convertLottie2Webp](#convertlottie2webp) |
| 8 | + - [convertLotties2PIL](#convertlotties2pil) |
| 9 | + - [convertMultLottie2GIF](#convertmultlottie2gif) |
| 10 | + - [convertMultLottie2Webp](#convertmultlottie2webp) |
| 11 | + - [recordLotties](#recordlotties) |
| 12 | + - [resQuality](#resquality) |
| 13 | + |
| 14 | +## convertLottie2GIF |
| 15 | + |
| 16 | +[[find in source code]](../../pylottie/__init__.py#L16) |
| 17 | + |
| 18 | +```python |
| 19 | +def convertLottie2GIF(fileName: str, newFileName: str, quality: int = 0): |
| 20 | +``` |
| 21 | + |
| 22 | +Convert to webp |
| 23 | + |
| 24 | +#### Arguments |
| 25 | + |
| 26 | +- `fileName` *str* - file path of the lottie file |
| 27 | +- `newFileName` *str* - name of the file to write |
| 28 | +- `quality` *int, optional* - Quality of the returned sequence. Defaults to 0. |
| 29 | + |
| 30 | +## convertLottie2Webp |
| 31 | + |
| 32 | +[[find in source code]](../../pylottie/__init__.py#L27) |
| 33 | + |
| 34 | +```python |
| 35 | +def convertLottie2Webp(fileName: str, newFileName: str, quality: int = 0): |
| 36 | +``` |
| 37 | + |
| 38 | +Convert to webp |
| 39 | + |
| 40 | +#### Arguments |
| 41 | + |
| 42 | +- `fileName` *str* - file path of the lottie file |
| 43 | +- `newFileName` *str* - name of the file to write |
| 44 | +- `quality` *int, optional* - Quality of the returned sequence. Defaults to 0. |
| 45 | + |
| 46 | +## convertLotties2PIL |
| 47 | + |
| 48 | +[[find in source code]](../../pylottie/__init__.py#L79) |
| 49 | + |
| 50 | +```python |
| 51 | +def convertLotties2PIL( |
| 52 | + fileNames: list[str], |
| 53 | + quality: int = 0, |
| 54 | +) -> list[tuple[(list[Image.Image], float)]]: |
| 55 | +``` |
| 56 | + |
| 57 | +Convert list of lottie files to a list of images with a duration |
| 58 | + |
| 59 | +#### Arguments |
| 60 | + |
| 61 | +- `fileNames` *list[str]* - list of file paths of the lottie files |
| 62 | +- `quality` *int, optional* - Quality of the returned sequence. Defaults to 0. |
| 63 | + |
| 64 | +#### Returns |
| 65 | + |
| 66 | +- `list[tuple[list[Image.Image],` *float]]* - pil images to write to gif/ webp and duration |
| 67 | + |
| 68 | +## convertMultLottie2GIF |
| 69 | + |
| 70 | +[[find in source code]](../../pylottie/__init__.py#L38) |
| 71 | + |
| 72 | +```python |
| 73 | +def convertMultLottie2GIF( |
| 74 | + fileNames: list[str], |
| 75 | + newFileNames: list[str], |
| 76 | + quality: int = 0, |
| 77 | +): |
| 78 | +``` |
| 79 | + |
| 80 | +Convert to gif |
| 81 | + |
| 82 | +#### Arguments |
| 83 | + |
| 84 | +- `fileNames` *list[str]* - list of file path to the lottie files |
| 85 | +- `newFileNames` *list[str]* - name of the files to write |
| 86 | +- `quality` *int, optional* - Quality of the returned sequence. Defaults to 0. |
| 87 | + |
| 88 | +## convertMultLottie2Webp |
| 89 | + |
| 90 | +[[find in source code]](../../pylottie/__init__.py#L54) |
| 91 | + |
| 92 | +```python |
| 93 | +def convertMultLottie2Webp( |
| 94 | + fileNames: list[str], |
| 95 | + newFileNames: list[str], |
| 96 | + quality: int = 0, |
| 97 | +): |
| 98 | +``` |
| 99 | + |
| 100 | +Convert to webp |
| 101 | + |
| 102 | +#### Arguments |
| 103 | + |
| 104 | +- `fileNames` *list[str]* - list of file path to the lottie files |
| 105 | +- `newFileNames` *list[str]* - name of the files to write |
| 106 | +- `quality` *int, optional* - Quality of the returned sequence. Defaults to 0. |
| 107 | + |
| 108 | +## recordLotties |
| 109 | + |
| 110 | +[[find in source code]](../../pylottie/__init__.py#L114) |
| 111 | + |
| 112 | +```python |
| 113 | +async def recordLotties( |
| 114 | + lottieData: list[str], |
| 115 | + step: int, |
| 116 | +) -> list[tuple[(int, int)]]: |
| 117 | +``` |
| 118 | + |
| 119 | +Record the lottie data to a set of images |
| 120 | + |
| 121 | +#### Arguments |
| 122 | + |
| 123 | +- `lottieData` *str* - lottie data as string |
| 124 | +- `step` *int* - Step by, Related to quality of the returned sequence. |
| 125 | + |
| 126 | +#### Returns |
| 127 | + |
| 128 | +- `tuple[int,` *int]* - duration and number of frames |
| 129 | + |
| 130 | +## resQuality |
| 131 | + |
| 132 | +[[find in source code]](../../pylottie/__init__.py#L72) |
| 133 | + |
| 134 | +```python |
| 135 | +def resQuality(quality): |
| 136 | +``` |
0 commit comments