- //*****************************************************************************
- //File Name: kb_machblue_core_def.h
- //
- //Description: data definition
- //
- //Author: steven & wisco
- //
- //Date: 2006.12.29
- //
- //Version: v1.0
- //*****************************************************************************
- #ifndef _KB_MACKBLUE_CLIENT_DEFINE_H_
- #define _KB_MACKBLUE_CLIENT_DEFINE_H_
- #include "stgxobj.h"
- #include "stavmem.h"
- #include "gendef.h"
- #include "machblue_defines.h"
- #include "machblue_tv_defines.h"
- enum
- {
- MB_FAVOR,
- MB_MOVE,
- MB_DELETE,
- MB_LOCK
- };
- typedef struct kb_movie_fontAddress_s
- {
- UINT8 *Address;
- UINT8 *English_Adderss;
- UINT8 *Chinese_Adderss;
- }kb_movie_fontAddress_t;
- typedef struct kb_movie_fontAttribute_s
- {
- int Ascender; //the distance from the baseline to the top of the logical extents of this font.
- int Descender; //the distance from the baseline to the bottom of the logical extents of this font.
- int Height; //the logical height of this font. This is the vertical distance from one baseline to the next when writing several lines of text. Note that this value does not correspond the height value specified when loading the font.
- int MaxAdvance; //the maximum character width.
- int Kerning; //the kerning to apply between two glyphs specified by their Unicode indices.
- int StringWidth; //the logical width of the specified UTF-8 string as if it were drawn with this font.
- int StringExtents; //the logical and real extents of the specified UTF-8 string as if it were drawn with this font.
- int GlyphExtents; //the extents of a glyph specified by its Unicode index.
- }kb_movie_fontAttribute_t;
- typedef struct kb_movie_font_s
- {
- kb_movie_fontAddress_t address;
- const char *font_name ;
- int m_size ;
- kb_movie_fontAttribute_t m_dfb_font ;
- }kb_movie_font_t;
- typedef struct kb_movie_pcm_s
- {
- mb_pcm_format_t m_format;
- unsigned long m_sample_rate;
- int m_n_channels;
- }kb_movie_pcm_t;
- typedef struct kb_movie_surface_s
- {
- int m_width;
- int m_height;
- int m_partition;
- mb_pixel_format_t m_format;
- STAVMEM_BlockHandle_t m_blockHandle;
- STGXOBJ_Bitmap_t m_bitmap;
- }kb_movie_surface_t;
- typedef struct kb_movie_event_s kb_movie_event_t;
- typedef struct kb_movie_eventSchedule_s kb_movie_eventSchedule_t;
- typedef struct kb_movie_service_info_s kb_movie_service_info_t;
- typedef struct kb_movie_service_s kb_movie_service_t;
- typedef struct kb_movie_serviceList_s kb_movie_serviceList_t;
- typedef struct kb_movie_stream_s kb_movie_stream_t;
- typedef struct kb_movie_streamController_s kb_movie_streamController_t;
- typedef struct kb_movie_serviceContext_s kb_movie_serviceContext_t;
- typedef struct kb_movie_service_edit_attribute_s kb_movie_service_edit_attribute_t; //shriek
- /** Structure to hold a event */
- typedef struct kb_movie_event_s
- {
- mb_tv_event_attributes_t attributes;
- mb_tv_authorization_flag_t auth;
- unsigned char day;
- kb_movie_service_t *service; // Service associated whit the event
- kb_movie_eventSchedule_t *evs;
- };
- /** Structure to hold a event schedule */
- typedef struct kb_movie_eventSchedule_s
- {
- kb_movie_event_t *events; // Event List NULL Terminated
- kb_movie_service_t *service; // Service associated whit the event schedule
- mb_time_t start_time;
- mb_time_t end_time; // Start time and end time of the event schedule
- unsigned long evtCount;
- };
- //为频道编辑添加数字标识
- typedef struct kb_movie_service_edit_attribute_s
- {
- unsigned char favor;
- unsigned char move;
- unsigned char del;
- unsigned char lock;
- };
- typedef struct kb_movie_service_info_s
- {
- unsigned short tsID;
- kb_movie_service_edit_attribute_t edit_info;
- };
- /** Structure to hold a service */
- typedef struct kb_movie_service_s
- {
- mb_tv_service_info_t info;
- mb_tv_service_state_t state;
- mb_tv_authorization_flag_t auth;
- kb_movie_service_info_t serInfo;
- kb_movie_eventSchedule_t evs[7]; // Event schedule associated whit the service
- kb_movie_event_t current_event; // Current Event of the service
- kb_movie_event_t following_event; // Followinf Event of the service
- kb_movie_serviceList_t *svl; // Service List associated whit the service
- kb_movie_serviceContext_t *svc; // Service context associated whit the service
- kb_movie_stream_t *streams; // stream of list NULL Terminated
- };
- /** Structure to hold a service List */
- typedef struct kb_movie_serviceList_s
- {
- mb_tv_svl_info_t info;
- kb_movie_service_t *services;
- unsigned long count;
- };
- /** Structure to hold a stream */
- typedef struct kb_movie_stream_s
- {
- mb_tv_stream_info_t info;
- mb_tv_stream_state_t state;
- kb_movie_service_t *service; // The service of the stream
- };
- /** Structure to hold a stream controller */
- typedef struct kb_movie_streamController_s
- {
- kb_movie_stream_t **streams; // stream list NULL Terminated
- kb_movie_stream_t **current_streams; // current stream list NULL Terminated
- kb_movie_serviceContext_t *svc; // Service context associated whit the stream controller
- int pb_speed; // Play back speed of the device
- unsigned long pts_value; // Presentation Time Stamp Value
- unsigned long pb_frame; // Play back frame
- };
- /** Structure to hold a service context */
- typedef struct kb_movie_serviceContext_s
- {
- mb_tv_service_context_info_t info;
- mb_tv_viewport_t viewport;
- kb_movie_service_t *service; // Service associated whit the service context
- kb_movie_streamController_t *stc; // stream controller associated whit the service context
- };
- #endif