Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: m-labs/flickernoise
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: cf76930
Choose a base ref
...
head repository: m-labs/flickernoise
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: f680dbf
Choose a head ref
  • 2 commits
  • 1 file changed
  • 1 contributor

Commits on Jan 14, 2012

  1. gui/performance.c: make dt_mode work again, except for the first patch

    Titles were not displayed, probably due to an oversight in some
    earlier code rearranging. This commit fixes it for all but the
    first patch.
    wpwrak committed Jan 14, 2012
    Copy the full SHA
    b7a8144 View commit details
  2. gui/performance.c: make dt_mode also work for the first patch

    This is a bit tricky because we can't just call osd_event in
    start_rendering. Instead we have to defer this to event_callback.
    wpwrak committed Jan 14, 2012
    Copy the full SHA
    f680dbf View commit details
Showing with 11 additions and 4 deletions.
  1. +11 −4 src/gui/performance.c
15 changes: 11 additions & 4 deletions src/gui/performance.c
Original file line number Diff line number Diff line change
@@ -179,6 +179,7 @@ static void add_simple_patches(void)

static int appid;
static int started;
static int first_event;

static void close_callback(mtk_event *e, void *arg)
{
@@ -431,6 +432,8 @@ static void simple_mode_next(int next)
renderer_pulse_patch(patches[simple_mode_current].p);
if(as_mode)
update_next_as_time();
if(dt_mode)
osd_event(patches[simple_mode_current].filename);
}

static void configured_mode_event(mtk_event *e)
@@ -481,12 +484,16 @@ static void configured_mode_event(mtk_event *e)
static void event_callback(mtk_event *e, int count)
{
int i;
int index;
int next;
rtems_interval t;

index = -1;
if(simple_mode) {
/*
* We can can't show the first title in start_rendering
* because the renderer isn't up yet. So we do it here.
*/
if (first_event && dt_mode)
osd_event(patches[simple_mode_current].filename);
next = 0;
for(i=0;i<count;i++)
simple_mode_event(e+i, &next);
@@ -497,12 +504,11 @@ static void event_callback(mtk_event *e, int count)
}
if(next)
simple_mode_next(next);
if(dt_mode && (index != -1))
osd_event(patches[index].filename);
} else {
for(i=0;i<count;i++)
configured_mode_event(e+i);
}
first_event = 0;
}

static void stop_callback(void)
@@ -525,6 +531,7 @@ static void start_rendering(void)
index = simple_mode_current;
}

first_event = 1;
if(!guirender(appid, patches[index].p, stop_callback))
stop_callback();
}