
SDL+GTK
一瓶不满半瓶晃
一瓶子不满,半瓶子晃。工作问题总结目标是提供问题一站式解决方案
展开
-
获取gtk控件位置,宽高
gint width, height;gdk_drawable_get_size(GDK_DRAWABLE(main_window->window), &width, &height);gint x, y;GdkScreen* cur_screen = NULL;GdkWindow* window = NULL;GdkPixbuf* pixbuf_screenshot = NULL;GdkRectangle rect;GdkRectangle screen_rect;.原创 2020-06-03 07:33:55 · 843 阅读 · 0 评论 -
ffmpeg+duilib 播放器开源项目
SunPlayer是一个视频播放器。核心播放部分是ffplayer(https://github.com/rockcarry/ffplayer),ffplayer是对ffmpeg的一个c封装,详情请转到github查看。UI部分使用的Troy维护的Duilib(https://github.com/qdtroy/DuiLib_Ultimate),还有一个版本UI使用的QT5。播放器实现了常用的功能,如播放,暂停,快进快退打开文件,最大化全屏等等功能。其中Duilib版本菜单部分还未完成。..转载 2020-05-27 06:06:25 · 800 阅读 · 0 评论 -
SDL2.0窗口嵌入gtk控件中
/* using SDL2.0 with GTk */#include <stdlib.h>#include <stdio.h>#include <time.h>#include <iostream.h>#include <gtk/gtk.h>#include <gdk/gdkx.h>#include <SDL2/SDL.h>//#include <SDL2/SDL_Video.h>..原创 2020-05-26 21:05:51 · 757 阅读 · 0 评论 -
SDL1.2窗口嵌入GTK控件中
SDL1.2窗口嵌入GTK控件中#include<gtk/gtk.h>#include <gdk/gdkx.h>#include <SDL/SDL.h>#include <SDL/SDL_video.h>//必须引用gtk/gtk.h这个头文件int video_output_width =0;int video_output_height = 0;#define WINSIZEX 320#define WINSIZEY 200/*原创 2020-05-26 20:52:30 · 532 阅读 · 0 评论