rewrite readme and correct mistakes in it

This commit is contained in:
Latysheva Alexandra 2020-10-30 19:05:37 +06:00 committed by GitHub
parent 36c816c693
commit 3a83fe68c9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -17,20 +17,28 @@ make -j8
#### Example: #### Example:
You should add `-DLIBPNG_SAPI_ENABLE_EXAMPLES=ON` to use the example.\ You should add `-DLIBPNG_SAPI_ENABLE_EXAMPLES=ON` to use the example.\
run PNG to PNG: `./examples/pngtopng /absolute/path/to/input/image.png /absolute/path/to/output/image.png`\ run PNG to PNG:
run RGB to BGR: `./examples/rgbtobgr /absolute/path/to/input/image.png /absolute/path/to/output/image.png` ```
./examples/pngtopng /absolute/path/to/input/image.png /absolute/path/to/output/image.png
```
run RGB to BGR:
```
./examples/rgbtobgr /absolute/path/to/input/image.png /absolute/path/to/output/image.png
```
Input and output examples can be found in images directory. Examples of input and output can be found in `images`.
PNG to PNG: \ PNG to PNG: \
input: `/abs/path/to/project/images/pngtest.png`\ input: `images/pngtest.png`\
output:` /abs/path/to/project/images/pngtopng_pngtest.png` output:` images/pngtopng_pngtest.png`
RGB to BGR: \ RGB to BGR: \
input: `/abs/path/to/project/images/red_ball.png`\ input: `images/red_ball.png`\
output:` /abs/path/to/project/images/rgbtobgr_red_ball.png` output: `images/rgbtobgr_red_ball.png`
#### Tests: #### Tests:
You should add `-DLIBPNG_SAPI_ENABLE_TESTS=ON` to use tests.\ You should add `-DLIBPNG_SAPI_ENABLE_TESTS=ON` to use tests and run:
run: `./tests/tests` ```
./tests/tests
```