diff options
author | rizzo <rizzo@f38db490-d61c-443f-a65b-d21fe96a405b> | 2008-01-08 23:09:44 +0000 |
---|---|---|
committer | rizzo <rizzo@f38db490-d61c-443f-a65b-d21fe96a405b> | 2008-01-08 23:09:44 +0000 |
commit | 3b8929f929dc7a8e8e6893b58ccaeb3b54ca2a51 (patch) | |
tree | 98f941b4d972c8829d77272f16f4b5283064c35e /channels/console_video.c | |
parent | 661c86104f4f3af3557d4df73aa3e4768154f35a (diff) |
add support for textareas, used for various dialog windows on the gui.
The main code to implement the textarea is in console_board.c,
and uses a simple png image with the font, blitting characters
on the designated areas of the main screen.
Additionally we provide some annotations in the image used
as a skin to indicate which areas are used for text messages.
(images will be committed separately).
At the moment the dialog area is only used to display a running
counter, just as a proof of concept.
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@97280 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'channels/console_video.c')
-rw-r--r-- | channels/console_video.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/channels/console_video.c b/channels/console_video.c index ebf936a37..e23fe7916 100644 --- a/channels/console_video.c +++ b/channels/console_video.c @@ -659,6 +659,8 @@ static struct ast_frame *get_video_frames(struct video_desc *env, struct ast_fra return v->enc->enc_encap(&v->enc_out, v->mtu, tail); } +int print_message(struct board *b, const char *s); + /* * Helper thread to periodically poll the video source and enqueue the * generated frames to the channel's queue. @@ -715,6 +717,10 @@ static void *video_thread(void *arg) int fd = chan->alertpipe[1]; char *caption = NULL, buf[160]; + sprintf(buf, "%d \r", count); + if (env->gui) + print_message(env->gui->bd_msg, buf); + /* determine if video format changed */ if (count++ % 10 == 0) { if (env->out.sendvideo) |