252 lines
5.3 KiB
Lua
Executable File
252 lines
5.3 KiB
Lua
Executable File
------------------------------------------------------------------
|
|
-- some enum or constat values for vpu
|
|
|
|
VPU_VOMODE_BLK = 0 -- 宏块格式 | [ ]
|
|
VPU_VOMODE_SCAN = 1 -- 光栅格式(NV12) | [ ]
|
|
VPU_VOMODE_TILE192 = 2 -- Tile压缩192Byte | [ ]
|
|
VPU_VOMODE_TILE224 = 3 -- Tile压缩224Byte | [ ]
|
|
VPU_VOMODE_TILE256 = 4 -- Tile压缩256Byte | [ ]
|
|
VPU_VOMODE_RGB888 = 5 -- RGB888 | [ ]
|
|
VPU_VOMODE_ARGB888 = 5 -- ARGB888 | [ ]
|
|
VPU_VOMODE_YUYV = 6 -- YUYV(YUV2) | [ ]
|
|
VPU_VOMODE_RRGGBB = 7 -- RRGGBB | [ ]
|
|
VPU_VOMODE_NV16 = 10 -- NV16 | [ ]
|
|
VPU_VOMODE_Y = 11 -- Y | [ ]
|
|
VPU_VOMODE_UYVY = 12 -- UYVY | [ ]
|
|
VPU_VOMODE_YU12 = 13 -- YU12 | [ ]
|
|
VPU_VOMODE_RGB = 14 -- RGB | [ ]
|
|
VPU_VOMODE_BAYER_RAW = 15 -- BAYER_RAW | [ ]
|
|
VPU_VOMODE_10BIT_NV12 = 16 -- yuv420 10bit for 2dlut | [ ]
|
|
|
|
VPU_MODE_ISP_ONLINE = 0
|
|
VPU_MODE_DDR_OFFLINE = 1
|
|
VPU_MODE_2DLUT_OFFLINE = 2
|
|
VPU_MODE_2DLUT_ONLINE = 3
|
|
VPU_MODE_MAX_NUM = 4
|
|
VPU_MODE_DISABLE = 0xFFFF
|
|
|
|
-- ISP const
|
|
ISP_OFFLINE_MODE_DISABLE = 0
|
|
ISP_OFFLINE_MODE_LINEAR = 1
|
|
ISP_OFFLINE_MODE_WDR = 2
|
|
|
|
ISP_OUT_TO_VPU = 1 -- (1 << 0)
|
|
ISP_OUT_TO_DDR = 2 -- (1 << 1)
|
|
|
|
ISP_OUT_TO_DDR_YUV420_8BIT = 0
|
|
ISP_OUT_TO_DDR_YUV422_8BIT = 1
|
|
ISP_OUT_TO_DDR_YUV420_10BIT = 2
|
|
ISP_OUT_TO_DDR_YUV422_10BIT = 3
|
|
|
|
ISP_LUT2D_BYPASS = 0
|
|
ISP_LUT2D_ONLINE = 1
|
|
ISP_LUT2D_OFFLINE = 2
|
|
|
|
|
|
FORMAT_1080P25 = 0x0203
|
|
FORMAT_1080P30 = 0x0204
|
|
FORMAT_1080P60 = 0x0207
|
|
FORMAT_1200P30 = 0x0304
|
|
FORMAT_2688X1520P15 = 0x1201
|
|
FORMAT_2688X1520P20 = 0x1202
|
|
FORMAT_2688X1520P25 = 0x1203
|
|
FORMAT_2688X1520P30 = 0x1204
|
|
FORMAT_2592X1952P30 = 0x1304
|
|
---------------------------------------------------------------------------------
|
|
-- global variable here
|
|
|
|
local g_vi_width = 4096
|
|
local g_vi_height = 2160
|
|
|
|
|
|
---------------------------------------------------------------------------------
|
|
-- config parameters
|
|
|
|
test_cases = {
|
|
[0] = {
|
|
param = {
|
|
duration = 4000000, -- in ms
|
|
|
|
},
|
|
ispppp = {
|
|
[0] = {
|
|
offline_mode = ISP_OFFLINE_MODE_WDR,
|
|
out_mode = ISP_OUT_TO_VPU,
|
|
out_format = ISP_OUT_TO_DDR_YUV422_8BIT,
|
|
lut2d_mode = ISP_LUT2D_BYPASS,
|
|
u32Width = g_vi_width,
|
|
u32Height = g_vi_height,
|
|
sensor_name = "dummy_sensor",
|
|
isp_format = FORMAT_1080P30,
|
|
},
|
|
--cmd = "echo colorbar_30 > /proc/driver/isp;devmem 0x2d000090 32 0x80a8ffff",
|
|
cmd = "sh /nfs/test/ddr_init.sh 8M;sh /nfs/test/ddr_init.sh wdr",
|
|
|
|
},
|
|
vpu = {
|
|
group = {
|
|
vi_max_size = {
|
|
u32Width = g_vi_width,
|
|
u32Height = g_vi_height,
|
|
},
|
|
--vimode = VPU_MODE_ISP_ONLINE,
|
|
},
|
|
channels = {
|
|
[0] = {
|
|
info = {
|
|
chn_max_size = {
|
|
u32Width = 3840,
|
|
u32Height = 2160,
|
|
},
|
|
out_mode = VPU_VOMODE_TILE224,
|
|
support_mode = 3167,
|
|
|
|
},
|
|
config = {
|
|
vpu_chn_size = {
|
|
u32Width = 3840,
|
|
u32Height = 2160,
|
|
},
|
|
depth = 1
|
|
},
|
|
vomode = VPU_VOMODE_TILE224,
|
|
},
|
|
[1] = {
|
|
info = {
|
|
chn_max_size = {
|
|
u32Width = 2048,
|
|
u32Height = 2048,
|
|
},
|
|
out_mode = VPU_VOMODE_TILE192,
|
|
support_mode = 3167,
|
|
|
|
},
|
|
config = {
|
|
vpu_chn_size = {
|
|
u32Width = 1920,
|
|
u32Height = 1080,
|
|
},
|
|
depth = 1
|
|
},
|
|
vomode = VPU_VOMODE_TILE192,
|
|
},
|
|
[2] = {
|
|
info = {
|
|
chn_max_size = {
|
|
u32Width = 1280,
|
|
u32Height = 1280,
|
|
},
|
|
out_mode = VPU_VOMODE_BLK,
|
|
support_mode = 3167,
|
|
|
|
},
|
|
config = {
|
|
vpu_chn_size = {
|
|
u32Width = 1280,
|
|
u32Height = 720,
|
|
},
|
|
depth = 1
|
|
},
|
|
vomode = VPU_VOMODE_BLK,
|
|
},
|
|
|
|
|
|
},
|
|
src = {
|
|
width = g_vi_width,
|
|
height = g_vi_height,
|
|
mode = VPU_VOMODE_NV16,
|
|
filename = "res/fireworks_3840x2160_nv16.yuv",
|
|
},
|
|
|
|
},
|
|
|
|
|
|
jpege = {
|
|
width = 3840,
|
|
height = 2160,
|
|
crop = {
|
|
en = false,
|
|
s32X = 0,
|
|
s32Y = 0,
|
|
u32Width = g_vi_width,
|
|
u32Height = g_vi_height,
|
|
},
|
|
count=13,
|
|
}
|
|
},
|
|
[1] = {
|
|
|
|
vpu = {
|
|
group = {
|
|
vi_max_size = {
|
|
u32Width = g_vi_width,
|
|
u32Height = g_vi_height,
|
|
},
|
|
--vimode = VPU_MODE_ISP_ONLINE,
|
|
},
|
|
channels = {
|
|
[0] = {
|
|
info = {
|
|
chn_max_size = {
|
|
u32Width = g_vi_width,
|
|
u32Height = g_vi_height,
|
|
},
|
|
out_mode = VPU_VOMODE_TILE224,
|
|
support_mode = 3167,
|
|
|
|
},
|
|
|
|
},
|
|
[1] = {
|
|
info = {
|
|
chn_max_size = {
|
|
u32Width = 2048,
|
|
u32Height = 2048,
|
|
},
|
|
out_mode = VPU_VOMODE_TILE192,
|
|
support_mode = 3167,
|
|
|
|
},
|
|
|
|
},
|
|
[2] = {
|
|
info = {
|
|
chn_max_size = {
|
|
u32Width = 1280,
|
|
u32Height = 1280,
|
|
},
|
|
out_mode = VPU_VOMODE_BLK,
|
|
support_mode = 3167,
|
|
|
|
},
|
|
|
|
},
|
|
|
|
|
|
},
|
|
src = {
|
|
width = g_vi_width,
|
|
height = g_vi_height,
|
|
mode = VPU_VOMODE_NV16,
|
|
},
|
|
},
|
|
|
|
jpege = {
|
|
width = g_vi_width,
|
|
height = g_vi_height,
|
|
crop = {
|
|
en = false,
|
|
s32X = 0,
|
|
s32Y = 0,
|
|
u32Width = g_vi_width,
|
|
u32Height = g_vi_height,
|
|
},
|
|
count=13000,
|
|
update_osd = 0,
|
|
}
|
|
}
|
|
}
|
|
|
|
|