Skip to content

Commit

Permalink
Merge branch 'master' into new-logging
Browse files Browse the repository at this point in the history
  • Loading branch information
Beirdo committed Jun 7, 2011
2 parents 93e9b44 + 4959d39 commit d1f59fb
Show file tree
Hide file tree
Showing 4 changed files with 38 additions and 15 deletions.
2 changes: 1 addition & 1 deletion mythtv/bindings/perl/MythTV.pm
Expand Up @@ -114,7 +114,7 @@ package MythTV;
# schema version supported in the main code. We need to check that the schema
# version in the database is as expected by the bindings, which are expected
# to be kept in sync with the main code.
our $SCHEMA_VERSION = "1276";
our $SCHEMA_VERSION = "1277";

# NUMPROGRAMLINES is defined in mythtv/libs/libmythtv/programinfo.h and is
# the number of items in a ProgramInfo QStringList group used by
Expand Down
2 changes: 1 addition & 1 deletion mythtv/bindings/python/MythTV/static.py
Expand Up @@ -5,7 +5,7 @@
"""

OWN_VERSION = (0,25,-1,2)
SCHEMA_VERSION = 1276
SCHEMA_VERSION = 1277
NVSCHEMA_VERSION = 1007
MUSICSCHEMA_VERSION = 1018
PROTO_VERSION = '66'
Expand Down
3 changes: 3 additions & 0 deletions mythtv/libs/libmythbluray/bdnav/navigation.c
Expand Up @@ -40,6 +40,9 @@ static int _filter_dup(MPLS_PL *pl_list[], unsigned count, MPLS_PL *pl)
if (pl->list_count != pl_list[ii]->list_count) {
continue;
}
if (pl->mark_count != pl_list[ii]->mark_count) {
continue;
}
for (jj = 0; jj < pl->list_count; jj++) {
MPLS_PI *pi1, *pi2;

Expand Down
46 changes: 33 additions & 13 deletions mythtv/libs/libmythbluray/decoders/graphics_controller.c
Expand Up @@ -42,6 +42,7 @@

typedef struct {
uint16_t enabled_button; /* enabled button id */
uint16_t x, y, w, h; /* button rect on overlay plane (if drawn) */
} BOG_DATA;

struct graphics_controller_s {
Expand Down Expand Up @@ -261,23 +262,29 @@ static void _reset_page_state(GRAPHICS_CONTROLLER *gc)
}
}

static void _clear_osd(GRAPHICS_CONTROLLER *gc, int plane)
static void _clear_osd_area(GRAPHICS_CONTROLLER *gc, int plane,
uint16_t x, uint16_t y, uint16_t w, uint16_t h)
{
if (gc->overlay_proc) {
/* clear plane */
const BD_OVERLAY ov = {
.pts = -1,
.plane = plane,
.x = 0,
.y = 0,
.w = 1920,
.h = 1080,
.x = x,
.y = y,
.w = w,
.h = h,
.palette = NULL,
.img = NULL,
};

gc->overlay_proc(gc->overlay_proc_handle, &ov);
}
}

static void _clear_osd(GRAPHICS_CONTROLLER *gc, int plane)
{
_clear_osd_area(gc, plane, 0, 0, 1920, 1080);

if (plane) {
gc->ig_drawn = 0;
Expand All @@ -286,6 +293,16 @@ static void _clear_osd(GRAPHICS_CONTROLLER *gc, int plane)
}
}

static void _clear_bog_area(GRAPHICS_CONTROLLER *gc, BOG_DATA *bog_data)
{
if (gc->ig_drawn && bog_data->w && bog_data->h) {

_clear_osd_area(gc, 1, bog_data->x, bog_data->y, bog_data->w, bog_data->h);

bog_data->x = bog_data->y = bog_data->w = bog_data->h = 0;
}
}

static void _select_page(GRAPHICS_CONTROLLER *gc, uint16_t page_id)
{
bd_psr_write(gc->regs, PSR_MENU_PAGE_ID, page_id);
Expand Down Expand Up @@ -401,24 +418,27 @@ void gc_decode_ts(GRAPHICS_CONTROLLER *gc, uint16_t pid, uint8_t *block, unsigne
*/

static void _render_button(GRAPHICS_CONTROLLER *gc, BD_IG_BUTTON *button, BD_PG_PALETTE *palette,
int state)
int state, BOG_DATA *bog_data)
{
BD_PG_OBJECT *object = NULL;
BD_OVERLAY ov;

object = _find_object_for_button(gc->igs, button, state);
if (!object) {
GC_TRACE("_render_button(#%d): object (state %d) not found\n", button->id, state);

_clear_bog_area(gc, bog_data);

return;
}

ov.pts = -1;
ov.plane = 1; /* IG */

ov.x = button->x_pos;
ov.y = button->y_pos;
ov.w = object->width;
ov.h = object->height;
ov.x = bog_data->x = button->x_pos;
ov.y = bog_data->y = button->y_pos;
ov.w = bog_data->w = object->width;
ov.h = bog_data->h = object->height;

ov.img = object->img;
ov.palette = palette->entry;
Expand Down Expand Up @@ -476,11 +496,11 @@ static void _render_page(GRAPHICS_CONTROLLER *gc,
GC_TRACE("_render_page(): bog %d: button %d not found\n", ii, valid_id);

} else if (button->id == activated_button_id) {
_render_button(gc, button, palette, BTN_ACTIVATED);
_render_button(gc, button, palette, BTN_ACTIVATED, &gc->bog_data[ii]);

} else if (button->id == selected_button_id) {

_render_button(gc, button, palette, BTN_SELECTED);
_render_button(gc, button, palette, BTN_SELECTED, &gc->bog_data[ii]);

bd_psr_write(gc->regs, PSR_SELECTED_BUTTON_ID, selected_button_id);

Expand All @@ -490,7 +510,7 @@ static void _render_page(GRAPHICS_CONTROLLER *gc,
}

} else {
_render_button(gc, button, palette, BTN_NORMAL);
_render_button(gc, button, palette, BTN_NORMAL, &gc->bog_data[ii]);

}
}
Expand Down

0 comments on commit d1f59fb

Please sign in to comment.