MHEG5  15.3.0
source/core/src/mh5misc.c File Reference

Miscellaneous functionality. More...

#include <string.h>
#include "mh5base.h"
#include "mh5profile.h"
#include "mh5misc.h"
#include "mh5debug.h"
#include "mh5parse.h"
#include "mh5stream.h"
#include "mh5memory.h"
#include "dvb_video.h"
#include "glue_main.h"
#include "dvb_service.h"
#include "glue_dsmcc.h"
#include "mh5control.h"

Defines

#define MAX_NDX_MAP   8
#define MAX_WAI_LEN   256
#define MAX_PROMPT   50
#define RSA_SALT_SIZE   16
#define RSA_SIGNATURE_SIZE   (1024 / 8)
#define MAX_VERSION_LEN   12
#define MAX_RSA_KEY_SIZE   1024

Functions

void MHEG5setInputEventRegister (MHEG5Int inputEventRegister)
 Change the input event register. This indicates which keypresses the MHEG-5 engine requires to be passed. See UK 1.05 profile section 3.6 for a description of which keypresses must be passed to MHEG-5 for the different input event register values. These values are likely to change for UK1.06 profile.
MHEG5Bool MHEG5parseUrl (U8BIT *buffer, U32BIT length, S_DVB_LOCATOR *multiplexRef)
 Parse a DAVIC style multiplex reference or UK-DTT inherritance format URL. This can be one of the following forms: rec://svc/cur rec://svc/def rec://svc/lcn/# dvb://original_network_id.[transport_stream_id].service_id[.*].
MHEG5Int MHEG5GetServiceIndex (MHEG5String *serviceReference)
 Ref:[1] - 3.10.6.1 and [1] - 3.10.6.3 Get the serviceIndex, a positive integer which is used to reference a service, based on the DVB URL (MHEG5_dvbLocator). NONE.
void MHEG5SetSubtitleMode (MHEG5Bool subtitleOn)
 Set the current subtitle display mode to be either On or Off, Should only have an impact if subtitles can be displayed simultaneously with MHEG. This function is used by the SetSubtitleMode resident program. See UK1.06 profile section 3.10.8.4.
MHEG5String MHEG5GetBootInfo (MHEG5Bool *InfoResultVal)
 Tell whether a network_boot_info sub-descriptor has been found and received. If so, returns the value of the NB_info field of the network_boot_info sub-descriptor. This function is used by the GetBootInfo resident program. See UK1.06 profile section 3.10.7.3.
MHEG5Int MHEG5GetDisplayAspectRatio (void)
 Find the setting of the attached display's aspect ratio This function is used by the GetDisplayAspectRatio resident program. See UK1.06 profile section 3.10.8.3.
MHEG5Bool MHEG5GetBasicSI (MHEG5Int serviceIndex, MHEG5Int *networkID, MHEG5Int *origNetworkID, MHEG5Int *transportStreamID, MHEG5Int *serviceID)
 Returns a series of integers representing basic Service Information (SI) about a service. The service is identified by means of a receiver specific "ServiceIndex". This integer can be determined by means of the SI_GetServiceIndex resident program (see 3.10.6.1, "SI_GetServiceIndex", on page 3-20). This function is used by the SI_TuneIndexInfo resident program. See UK1.06 profile section 3.10.6.3.
void MHEG5restoreReceiverDefaults (void)
 Restore receiver defaults as described in section 3.12.10 of the 1.06 profile.

Detailed Description

Miscellaneous functionality.

Date:
01/02/2002
Author:
R.Freeman

Function Documentation

MHEG5Bool MHEG5GetBasicSI ( MHEG5Int  serviceIndex,
MHEG5Int *  networkID,
MHEG5Int *  origNetworkID,
MHEG5Int *  transportStreamID,
MHEG5Int *  serviceID 
)

Returns a series of integers representing basic Service Information (SI) about a service. The service is identified by means of a receiver specific "ServiceIndex". This integer can be determined by means of the SI_GetServiceIndex resident program (see 3.10.6.1, "SI_GetServiceIndex", on page 3-20). This function is used by the SI_TuneIndexInfo resident program. See UK1.06 profile section 3.10.6.3.

Parameters:
serviceIndexReceiver-specific identifier for service
networkIDNetwork ID associated to the given service index
origNetworkIDOriginal network ID associated to the given service index
transportStreamIDTransport stream ID associated to the given service index
serviceIDService ID associated to the given service index
Returns:
Boolean MHEG5TRUE - service available. MHEG5FALSE - service not available.
MHEG5String MHEG5GetBootInfo ( MHEG5Bool *  InfoResultVal)

Tell whether a network_boot_info sub-descriptor has been found and received. If so, returns the value of the NB_info field of the network_boot_info sub-descriptor. This function is used by the GetBootInfo resident program. See UK1.06 profile section 3.10.7.3.

Returns:
None
MHEG5Int MHEG5GetDisplayAspectRatio ( void  )

Find the setting of the attached display's aspect ratio This function is used by the GetDisplayAspectRatio resident program. See UK1.06 profile section 3.10.8.3.

Reads the format of the connected display (4:3 or 16:9) This function is used by the GetDisplayAspectRatio resident program. See UK1.06 profile section 3.10.8.3.

Returns:
None
MHEG5Int MHEG5GetServiceIndex ( MHEG5String serviceReference)

Ref:[1] - 3.10.6.1 and [1] - 3.10.6.3 Get the serviceIndex, a positive integer which is used to reference a service, based on the DVB URL (MHEG5_dvbLocator). NONE.

Parameters:
serviceReferenceServiceReference defines a Stream using the URL format defined in DAVIC 1.3 part 9 paragraph 9.5. See also 8, "Name Mapping", on page 8-1
Returns:
serviceIndex. On error, an error value indicating one of the following: -1 (serviceIndex is unavailable for the given dvbLocator).
MHEG5Bool MHEG5parseUrl ( U8BIT *  buffer,
U32BIT  length,
S_DVB_LOCATOR multiplexRef 
)

Parse a DAVIC style multiplex reference or UK-DTT inherritance format URL. This can be one of the following forms: rec://svc/cur rec://svc/def rec://svc/lcn/# dvb://original_network_id.[transport_stream_id].service_id[.*].

Parameters:
bufferPointer to character buffer containing the URL string
lengthLength of character buffer
multiplexRefMultiplex reference extracted from the URL string
Returns:
MHEG5TRUE if URL could be decoded, else MHEG5FALSE

Restore receiver defaults as described in section 3.12.10 of the 1.06 profile.

Returns:
None.
void MHEG5setInputEventRegister ( MHEG5Int  inputEventRegister)

Change the input event register. This indicates which keypresses the MHEG-5 engine requires to be passed. See UK 1.05 profile section 3.6 for a description of which keypresses must be passed to MHEG-5 for the different input event register values. These values are likely to change for UK1.06 profile.

Parameters:
inputEventRegisterNew input event register value. 0 indicates that there is no scene currently running.
Returns:
None.
void MHEG5SetSubtitleMode ( MHEG5Bool  subtitleOn)

Set the current subtitle display mode to be either On or Off, Should only have an impact if subtitles can be displayed simultaneously with MHEG. This function is used by the SetSubtitleMode resident program. See UK1.06 profile section 3.10.8.4.

Returns:
None
 All Data Structures Files Functions Variables Typedefs Defines