Commit Graph

88 Commits

Author SHA1 Message Date
Herman Chen
bba530c27d [mpi_enc_utils]: Add hex format input support
Change-Id: I49ff9a916c51a0f9f3719cfb01e85e5a9e5f0a61
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2020-07-24 11:28:30 +08:00
Herman Chen
439fce52b0 [test]: Add infinite loop mode for mpi_enc_test
Change-Id: Ibf459034f89682ec2accf5c79cf437bc34804808
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2020-05-29 17:19:22 +08:00
Herman Chen
50bf7b7bf0 [utils]: Add encoder reference config sample
Add MppEncRefCfg configure sample to mpi_enc_utils.

Change-Id: I56d87dc6b267a8029c4d539526c368f2f44cec11
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2020-05-26 16:42:17 +08:00
Herman Chen
6a6521ed13 [gop_ref]: Remove gop_ref
New reference frame config interface will be added.

Change-Id: I5766cefde12237561bbc20c905e47ed2d3e90011
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2020-05-26 16:29:40 +08:00
Herman Chen
ef72082c67 [legacy]: Fix vpu_api_test
1. Remove static libraries for mpp and vpu.
2. Fix vpu_api_test and use dlopen to access libvpu.
3. Fix issue on vepu22 dependence on rga.

vpu_api_test cmd:
enc: vpu_api_test -t 2 -w 1280 -h 720 -i a.yuv -coding 7 -o a.h264

Change-Id: I9682b17b90dce4a82400f5e2da3c955819f875bf
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2020-05-19 11:00:13 +08:00
Shunqian Zheng
9464af395b [misc]: Terminate soc_name to fix out of bounds
1. Terminate soc_name string to fix memory out of bounds
2. Fix all snprintf/strnlen warning

Change-Id: I4525c6e289a00d1509bc30ee69545d92f2f4b9cb
Signed-off-by: Shunqian Zheng <zhengsq@rock-chips.com>
2020-04-29 16:06:47 +08:00
Herman Chen
708f7d4b28 [utils]: Update RGB generation code
Change-Id: I016c92f80391392f3b7f0ebbf8c44d6fa2304c27
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2020-04-27 16:01:22 +08:00
Herman Chen
4f5e7d3773 [mpi_enc_utils]: Fix tsvc4 definition
Change-Id: I1c995af21ae14b1dc0d14ad0cbd9c6a02d6d03c4
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2020-04-27 10:41:43 +08:00
Herman Chen
e8cb0d49f2 [enc_utils]: Format source code
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
Change-Id: I92f133f89920b125d3f2d44ee718ed394acd7aab
2020-04-20 09:53:55 +08:00
Xinhuang Li
c2d9a16c24 [test]: modify the frame rate to support decimals
use "-r numerator:denominator:flex"
for set the input to the same fps as the output, such as 50:1:1
or "-r numerator:denominator/flex-numerator:denominator:flex"
for set input and output separately, such as 40:1:1/30:1:0.
the default parameter is 30:1:0.

Signed-off-by: Xinhuang Li <buluess.li@rock-chips.com>
Change-Id: Ief2935354b82aba9c192b4af92636519d3e75423
2020-04-17 10:51:56 +08:00
Herman Chen
370777bd14 [utils]: Improve extension detection function
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
Change-Id: Id21a26efd4e3bdb82a5ef3d338d012c69dcac8e2
2020-04-14 10:43:01 +08:00
Herman Chen
50a9655531 [test]: update sample for fbc support
The FBC data should be in this form:

    +---------------------+
    | header (4K aligned) |
    +---------------------+
    |                     |
    |    payload data     |
    |                     |
    +---------------------+

The payload data size is equal to the orignal format size.

Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
Change-Id: I2855c89db43c3e2cc302ac40e96e36ef6147f041
2020-04-10 17:42:17 +08:00
Herman Chen
f79c854314 [utils]: Add gop ref config util function
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
Change-Id: I9b82e4a2a6e8451c9e63599329c3d3ddc74ff59c
2020-04-09 14:29:37 +08:00
Herman Chen
681599f97f [test]: Update utils for encoder test
1. Move command parsing to util files.
2. Support frame format and coding type detection.

Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
Change-Id: Id1df67ba61943bb7aa1f02ccccaa932fb5ae9842
2020-04-07 15:25:56 +08:00
Herman Chen
fe4b86b025 [mpp_enc]: Update OSD API
1. Update OSD palette config API. User must specify palette is default
or user defined.
2. OSD palette config will go through control and OSD data (region)
config will go through meta data in each frame.
3. Remove unused code.
4. Add mpi_enc_utils for mpi_enc_test cases

Change-Id: Ib4aeb60789a3e999446212841508e604533efb3c
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2020-04-02 18:21:20 +08:00
Herman Chen
52c93a4955 [utils]: Update iniparser
Change-Id: Id29dc65a732aa62f4614f1d602545c04e7de054b
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2020-02-27 17:25:17 +08:00
Ding Wei
f7ddf931c2 [utils]: Add more format support
Change-Id: I93f380f157806b8885559834b94b348bba87ff12
Signed-off-by: sayon.chen <sayon.chen@rock-chips.com>
Signed-off-by: Ding Wei <leo.ding@rock-chips.com>
2020-02-20 11:33:25 +08:00
Herman Chen
459eace205 [mpp_frame]: Add color format print
1. Add color format print for all supported format.
2. Add RGB color fill function.

Change-Id: I79fb3f40402b6fb6e36883c99945e709723aee7d
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2019-12-31 10:53:33 +08:00
Herman Chen
cd9a1cca3f [misc]: Change interface header file dependency
Move MppCtx, MppParam, MppFrame, MppPacket, MppBuffer, MppBufferGroup,
MppTask and MppMeta to rk_type.h.

Later development need to bring in cross reference between these
objects. So we choose to move these declaration together.

Change-Id: I7ea39138ca87d6ca4cb86556464a5de89d172846
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2019-06-14 10:15:12 +08:00
Johnson Ding
d2459e4fac [jpegd]: Add YUV400 support
Change-Id: I110f0f2a16977f985d32204704ca4c2effcd8b90
Signed-off-by: Johnson Ding <johnson.ding@rock-chips.com>
2019-06-12 10:55:58 +08:00
Herman Chen
f367af4a37 [utils]: Add YUV420P dump frame support
Change-Id: I0a63b03ab1bb5fb5fdcf52eadc2bde52319d155b
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2019-01-15 15:33:51 +08:00
Herman Chen
4553fac11e [test]: Add read packet config function
When mpp output packet binary file with size config file test case
should be enable to parser the corresponding config file.
This patch implement the config file option with "-c" prefix.

Command line sample:
mpi_dec_test -t 7 -i /sdcard/in.bin -i /sdcard/ops.bin
Then the test case will read in.bin file with size division specified
in ops.bin.

Change-Id: I8b18a6475d77f0303f12614a063888dcd9505f16
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2018-11-21 09:57:32 +08:00
Herman Chen
a0f76729d5 [utils]: Optimize YUV422SP frame write function
When decoding 422 source the YUV422 frame is default in YUV422SP mode.
But software like vooya does not support this format. So we change it to
YUV422P format for better user experience.

Change-Id: I103445470db5e6dd46ff1dc2cb705ae7e47bd8bc
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2018-11-20 11:43:06 +08:00
Herman Chen
ae93472665 [utils]: Add YUV444 frame writing support
VDPU hardware only support semi-planar format for YUV444 which is
hard to display on other software. So utils will change it to YUV444P
and write to file.

Change-Id: Ie81149d7638c2e1d36fc3bc06fe1353ca95c6c01
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2018-10-12 15:56:46 +08:00
Herman Chen
15e357ffd0 [utils]: Add YUV422SP frame write support
Add YUV422SP format support to function dump_mpp_frame_to_file for 422
format jpeg file.

Change-Id: I721551f526c2c981f023f638f4efd20bf695f5e9
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2018-09-06 09:10:04 +08:00
Herman Chen
fe17ac5806 [cmake]: Remove static library dependency
Some test depend on mpp_base static library which is unwanted.

Change-Id: Ic3ab0826dee1284c0737d1015648c334a6328f8d
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2018-08-23 16:38:32 +08:00
Herman Chen
166ddee9e0 [utils]: Add iniparser for ini file parsing
Source from https://github.com/ndevilla/iniparser
With MIT License:
https://github.com/ndevilla/iniparser/blob/master/LICENSE

NOTE: remove getdouble interface due to Android do not support atof.

Change-Id: I6b10f67875144bc0c36182c07024c133aa6987a5
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2018-04-27 17:20:32 +08:00
Ding Wei
6b6c1ae033 [utils]: for avoiding c++ keywrod, rename xor to vor
Change-Id: I6d2f604b33373932ba4df9affa253764e99bae13
Signed-off-by: Ding Wei <leo.ding@rock-chips.com>
2018-04-27 17:20:32 +08:00
Herman Chen
4e030fa170 [test]: Move some function to utils
Move yuv read function and yuv create function to utils.

Change-Id: I79a861ce869c182a27ed51a976eeb08f1f230d6e
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2018-04-27 17:20:24 +08:00
Ding Wei
4b2c91ed78 [utils]: fix bug: has error when calc last 4 byte
Change-Id: I240518ff7fcf429f42e50f87b56bf78738f2bb6d
Signed-off-by: Ding Wei <leo.ding@rock-chips.com>
2018-01-24 09:31:18 +08:00
Ding Wei
53a02bf26f [checksum]: use sum and xor for data/frame check
Change-Id: Ie3bd2f2819d8387a5b2486cf0a096d271220d819
Signed-off-by: Ding Wei <leo.ding@rock-chips.com>
2018-01-19 15:01:38 +08:00
Herman Chen
ef3d9158eb [utils]: Fix warning on Linux
Change-Id: I5b7319381f55fd089d512b9a3274dd9273b7279c
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2018-01-03 09:01:33 +08:00
Herman Chen
f96141033d [util]: Add frame checksum calculation function
Add checksum calculation function and file access function for debug.
NOTE: checksum for YUV image and for luma only so far.

Change-Id: I54509bebd64f5e5143e14824733d9c25af9db204
Signed-off-by: Herman Chen <herman.chen@rock-chips.com>
2017-06-13 09:42:57 +08:00
Lin Kesheng
60373a6973 [all]: format code
use fromdos to change file type, remove ^M in code.

Change-Id: I000202dc51fcff57cc0771455baebea595115b1d
Signed-off-by: Lin Kesheng <lks@rock-chips.com>
2016-09-08 15:21:02 +08:00
ChenHengming
dfe367b0ff [utils]: add mpp_frame write file function to utils
git-svn-id: https://10.10.10.66:8443/svn/MediaProcessPlatform/trunk/mpp@921 6e48237b-75ef-9749-8fc9-41990f28c85a
2016-06-16 07:22:48 +00:00
ChenHengming
c0866a76f9 [comment]: fix company name hand writing error
git-svn-id: https://10.10.10.66:8443/svn/MediaProcessPlatform/trunk/mpp@906 6e48237b-75ef-9749-8fc9-41990f28c85a
2016-06-13 09:42:31 +00:00
ChenHengming
bed52a856e [utils]: add show_options to utils
git-svn-id: https://10.10.10.66:8443/svn/MediaProcessPlatform/trunk/mpp@316 6e48237b-75ef-9749-8fc9-41990f28c85a
2015-09-28 22:31:52 +00:00
ChenHengming
c6d93bd1b9 [misc]: remove compile warning, and add utils directory for test cases
git-svn-id: https://10.10.10.66:8443/svn/MediaProcessPlatform/trunk/mpp@315 6e48237b-75ef-9749-8fc9-41990f28c85a
2015-09-28 21:22:25 +00:00