Skip to content
This SDK only works with devices released within the past 3 years. We regularly optimize and update the SDK to ensure compatibility and performance. We do not guarantee compatibility or provide technical support for devices older than 3 years.

# DD_VIDEO_OSD_CONFIG

### Structure Definition

C++C#

     1
     2
     3
     4
     5
     6
     7
     8
     9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    typedef struct _dd_video_osd_config_
    {
        unsigned int iSize;
        unsigned char enableCameraName;
        unsigned char enableTimeStamp;
        unsigned char enableTimeStampWithWeek;
        unsigned char enableDefineText;
        DD_POSITION cameraName;
        DD_POSITION timeStamp;
        DD_POSITION defineText;
        char cameraNameText[DD_MAX_CAMERA_NAME_LEN];
        char text[DD_MAX_TEXT_LEN];
        char timeFormat;
        char recv[3];
        struct
        {
            unsigned int enable;
            DD_AREA area;
        } cover[DD_MAX_VIDEO_COVER_NUM];
    } DD_VIDEO_OSD_CONFIG;

     1
     2
     3
     4
     5
     6
     7
     8
     9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    [StructLayout(LayoutKind.Sequential, Pack = 4)]
    public struct DD_VIDEO_OSD_CONFIG
    {
        public UInt32 iSize;
        public byte enableCameraName;
        public byte enableTimeStamp;
        public byte enableTimeStampWithWeek;
        public byte enableDefineText;
        public DD_POSITION cameraName;
        public DD_POSITION timeStamp;
        public DD_POSITION defineText;
        [MarshalAs(UnmanagedType.ByValArray, ArraySubType = UnmanagedType.U1, SizeConst = 64)]
        public byte[] cameraNameText;
        [MarshalAs(UnmanagedType.ByValArray, ArraySubType = UnmanagedType.U1, SizeConst = 64)]
        public byte[] text;
        public byte timeFormat;
        [MarshalAs(UnmanagedType.ByValArray, ArraySubType = UnmanagedType.U1, SizeConst = 3)]
        public byte[] recv;
        public struct DD_VIDEO_OSD_CONFIG_cover
        {
            public UInt32 enable;
            public DD_AREA area;
        }
        [MarshalAs(UnmanagedType.ByValArray, ArraySubType = UnmanagedType.Struct, SizeConst = 3)]
        public DD_VIDEO_OSD_CONFIG_cover[] cover;
    }

### Function Description

OSD configuration structure.

### Member Description

Member | Type | Remark
--- | --- | ---
iSize | unsigned int | The length of this structure.
enableCameraName | unsigned char | The name of the overlay channel.
enableTimeStamp | unsigned char | Overlay timestamp.
enableTimeStampWithWeek | unsigned char | Add the day of the week to the timestamp.
enableDefineText | unsigned char | Overlay custom text.
cameraName | `DD_POSITION` | The location of the channel name.
timeStamp | `DD_POSITION` | The location of the timestamp.
defineText | `DD_POSITION` | Customize the text position.
cameraNameText | char[DD_MAX_CAMERA_NAME_LEN] | The name of the overlay channel.
text | char[DD_MAX_TEXT_LEN] | Custom text.
timeFormat | char | Time format.
recv | char[3] | Reserved field.
cover |
    1
    2
    3
    4
    5
    struct
        {
            unsigned int enable;         // Whether the area coverage is effective.
            DD_AREA area;                // Area parameters.
    } cover[DD_MAX_VIDEO_COVER_NUM];
| The area parameters to be covered.

Error Code