Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
66 changes: 0 additions & 66 deletions .vscode/c_cpp_properties.json

This file was deleted.

2 changes: 1 addition & 1 deletion .vscode/launch.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
"name": "UDP_OSD",
"type": "cppdbg",
"request": "launch",
"program": "${workspaceFolder}/msposd",
"program": "${workspaceFolder}/msposd",
"args": [
"--master",
"127.0.0.1:14550",
Expand Down
146 changes: 66 additions & 80 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -1,86 +1,72 @@
{
"workbench.colorTheme": "Visual Studio Dark - C++",

"workbench.colorTheme": "Default High Contrast",
"editor.formatOnSave": false,
"editor.formatOnType": false,
"editor.formatOnPaste": false,

"C_Cpp.clang_format_path": "/usr/bin/clang-format",
"C_Cpp.clang_format_style": "file",

"C_Cpp.intelliSenseEngine": "Default",
"C_Cpp.enhancedColorization": "Enabled",
"C_Cpp.dimInactiveRegions": true,
"C_Cpp.inactiveRegionOpacity": 0.5,

"[c]": { "editor.semanticHighlighting.enabled": true },
"[cpp]":{ "editor.semanticHighlighting.enabled": true },

"files.associations": {
"mavlink.h": "c",
"system_error": "c",
"chrono": "c",
"common.h": "c",
"array": "c",
"string": "c",
"string_view": "c",
"msp_displayport.h": "c",
"msp.h": "c",
"graphics.h": "c",
"thread": "c",
"mi_rgn.h": "c",
"mi_common.h": "c",
"bitmap.h": "c",
"random": "c",
"format": "c",
"compare": "c",
"cstdint": "c",
"functional": "c",
"rope": "c",
"ranges": "c",
"variant": "c",
"lodepng.h": "c",
"any": "c",
"expected": "c",
"fstream": "c",
"future": "c",
"optional": "c",
"shared_mutex": "c",
"spanstream": "c",
"stacktrace": "c",
"stop_token": "c",
"syncstream": "c",
"tuple": "c",
"string.h": "c",
"mi_vpe.h": "c",
"bitset": "c",
"slist": "c",
"initializer_list": "c",
"span": "c",
"regex": "c",
"utility": "c",
"*.tcc": "c",
"iomanip": "c",
"istream": "c",
"streambuf": "c",
"*.def": "c",
"iterator": "c",
"charconv": "c",
"ratio": "c",
"type_traits": "c",
"hi_math.h": "c",
"cstdlib": "c",
"xlib.h": "c",
"stdbool.h": "c",
"xutil.h": "c",
"xatom.h": "c",
"region.h": "c",
"cairo-xlib.h": "c",
"stdint-uintn.h": "c",
"interface.h": "c",
"valarray": "c",
"complex": "c",
"source_location": "c"
"mavlink.h": "c",
"system_error": "c",
"chrono": "c",
"common.h": "c",
"array": "c",
"string": "c",
"string_view": "c",
"msp_displayport.h": "c",
"msp.h": "c",
"graphics.h": "c",
"thread": "c",
"mi_rgn.h": "c",
"mi_common.h": "c",
"bitmap.h": "c",
"random": "c",
"format": "c",
"compare": "c",
"cstdint": "c",
"functional": "c",
"rope": "c",
"ranges": "c",
"variant": "c",
"lodepng.h": "c",
"any": "c",
"expected": "c",
"fstream": "c",
"future": "c",
"optional": "c",
"shared_mutex": "c",
"spanstream": "c",
"stacktrace": "c",
"stop_token": "c",
"syncstream": "c",
"tuple": "c",
"string.h": "c",
"mi_vpe.h": "c",
"bitset": "c",
"slist": "c",
"initializer_list": "c",
"span": "c",
"regex": "c",
"utility": "c",
"*.tcc": "c",
"iomanip": "c",
"istream": "c",
"streambuf": "c",
"*.def": "c",
"iterator": "c",
"charconv": "c",
"ratio": "c",
"type_traits": "c",
"hi_math.h": "c",
"cstdlib": "c",
"xlib.h": "c",
"stdbool.h": "c",
"xutil.h": "c",
"xatom.h": "c",
"region.h": "c",
"cairo-xlib.h": "c",
"stdint-uintn.h": "c",
"interface.h": "c",
"valarray": "c",
"complex": "c",
"source_location": "c"
}
}

}
45 changes: 0 additions & 45 deletions bmp/macros.h

This file was deleted.

18 changes: 6 additions & 12 deletions bmp/region.c
Original file line number Diff line number Diff line change
@@ -1,9 +1,5 @@
#include "region.h"

#if defined(__INFINITY6C__)
#include "bmp/star/i6c_hal.c"
#endif

// https://wx.comake.online/doc/ds82ff82j7jsd9-SSD220/customer/development/mi/en/exclude/mi_rgn.html

#ifdef __SIGMASTAR__
Expand All @@ -29,9 +25,7 @@ int create_region(int *handle, int x, int y, int width, int height) {
MI_RGN_ChnPortParam_t stChnAttrCurrent;

#if __INFINITY6C__
hal_rect rect = { .height = height, .width = width,
.x = x, .y = y };
return i6c_region_create(0,rect,255);
stChn.eModId = E_MI_MODULE_ID_VENC;
#else
stChn.eModId = E_MI_RGN_MODID_VPE;
#endif
Expand Down Expand Up @@ -352,9 +346,9 @@ void *get_directBMP(int handle) {
int s32Ret = GetCanvas(handle, &stCanvasInfo);

if (s32Ret)
printf("GetCanvas Res: %X OSD Handle:%d CanvasStride: %d , Canvas size : %d:%d\r\n",
s32Ret, handle, stCanvasInfo.u32Stride, stCanvasInfo.stSize.u32Width,
stCanvasInfo.stSize.u32Height);
printf("GetCanvas Res: 0x%X, OSD Handle: %d CanvasStride: %d, Canvas size: %d:%d\r\n",
s32Ret, handle, stCanvasInfo.u32Stride,
stCanvasInfo.stSize.u32Width, stCanvasInfo.stSize.u32Height);
return (void *)(stCanvasInfo.virtAddr);
#endif
return NULL;
Expand Down Expand Up @@ -430,8 +424,8 @@ int unload_region(int *handle) {
}
#ifdef __SIGMASTAR__

int GetCanvas(int handle, MI_RGN_CanvasInfo_t *stCanvasInfo) {
int s32Result = MI_RGN_GetCanvasInfo(DEV handle, stCanvasInfo);
int GetCanvas(int handle, MI_RGN_CanvasInfo_t *stCanvasInfo) {
int s32Result = MI_RGN_GetCanvasInfo(DEV handle, stCanvasInfo);
if (s32Result != MI_RGN_OK)
return s32Result;

Expand Down
Loading