1
0
Fork 0
Commit graph

10 commits

Author SHA1 Message Date
Emmanuele Bassi
9206bd7627 tests/*: Use symbolic constants for sources and events
And make sure to use clutter_threads_add_* instead of the bare
g_*_add().
2012-01-25 23:20:25 +00:00
Emmanuele Bassi
93eb0bfe32 micro-bench/*: Do not use clutter_stage_get_default() 2011-11-10 15:37:50 +00:00
nobled
eb906d85ca tests: abort if clutter_init fails
This fixes segfaults when something goes wrong during
init, but the test keeps going anyway.

Except for test-easing and test-picking, these were fixed by
sed magic:

sed -i -s -e "s/clutter_init \?(&argc, &argv)/\
if (clutter_init (\&argc, \&argv) != CLUTTER_INIT_SUCCESS)\n\
    return 1/" tests/*/*.c

http://bugzilla.clutter-project.org/show_bug.cgi?id=2574
2011-02-28 14:10:04 +00:00
Neil Roberts
65f449bdb0 test-text-perf: Add a wider range of characters
Instead of just using the latin alphabet, this adds digits and some
other alphabets to increase the range of glyphs used.
2010-08-12 11:54:41 +01:00
Neil Roberts
c26d2c5ef9 test-text-perf: Scale the text if the settings will not fit
If the font size or the number of characters causes the label not to
fit on the stage, instead of aborting it will now scale the labels so
that it fits within one of the dimensions. This makes it easier to
test with large glyph sizes.
2010-08-12 11:54:41 +01:00
Damien Lespiau
3161e92818 analysis: Make all function declarations be protoypes
It's valid C to declare a function omitting it prototype, but it seems
to be a good practise to always declare a function with its
corresponding prototype.
2010-06-01 12:08:18 +01:00
Owen W. Taylor
dcd8d28314 Limit the frame rate when not syncing to VBLANK
clutter-master-clock.c clutter-master-clock.h: When the
  SYNC_TO_VBLANK feature is not available, wait for 1/frame_rate
  seconds since the start of the last frame before drawing the next
  frame. Add _clutter_master_clock_start_running() to abstract
  the usage of g_main_context_wakeup()

clutter-stage.c: Add _clutter_master_clock_start_running()

clutter-main.c: Update docs for clutter_set_default_frame_rate()
  clutter_get_default_frame_rate() to no longer talk about timeline
  frame rates.

test-text-perf.c test-text.c: Set a frame rate of 1000fps so that
  frame-rate limiting doesn't affect the result.

http://bugzilla.openedhand.com/show_bug.cgi?id=1637

Signed-off-by: Emmanuele Bassi <ebassi@linux.intel.com>
2009-06-09 15:03:56 +01:00
Neil Roberts
d960ce46e5 [test-text-perf] Use queue_redraw instead of painting the stage directly
If it doesn't queue a redraw and allow the backend to clear and swap
the buffers then the results will be skewed because it is not
predictable when the driver will actually render the scene.
2009-05-28 15:31:05 +01:00
Neil Roberts
a1b0160da7 [test-text-perf] Small fix-ups
- Fix a typo in a for loop in create_label which left 'i'
  uninitialised and caused a crash if you're unlucky.

- Set the CLUTTER_VBLANK=none environment variable.

- Don't quit on a keypress.

- Trailing whitespace tidy up.
2009-05-21 17:43:41 +01:00
Owen W. Taylor
8724a16452 Add a test for text performance
Add tests/test-text-perf, which allows testing text performance as
a function of the length of text strings and font size.
2009-05-21 17:37:43 +01:00