smplayer-0.6.9源码,arm linux编译可用.
代码片段和文件信息
/* smplayer GUI front-end for mplayer.
Copyright (C) 2006-2008 Ricardo Villalba
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License or
(at your option) any later version.
This program is distributed in the hope that it will be useful
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not write to the Free Software
Foundation Inc. 59 Temple Place Suite 330 Boston MA 02111-1307 USA
*/
#define DIRECTSOUND_VERSION 5
#include
#include
#include
int sound_devices;
int display_devices;
BOOL CALLBACK DirectSoundEnum(LPGUID guid LPCSTR desc LPCSTR module LPVOID context)
{
printf(“%i: %s
“ sound_devices desc);
sound_devices++;
return TRUE;
}
BOOL WINAPI DirectDrawEnum(GUID FAR *lpGUID LPSTR lpDriverDescription LPSTR lpDriverName LPVOID lpContext HMONITOR hm)
{
if (!lpGUID)
printf(“%i: %s
“ display_devices “Primary Display Adapter“);
else
printf(“%i: %s
“ display_devices lpDriverDescription);
display_devices++;
return TRUE;
}
int main(int argc char* argv[])
{
if (argc != 2){
printf(“Usage: dxlist.exe [-sound] [-s] [-display] [-d]
“);
return 1;
}
if ((strcmp(argv[1]“-sound“)==0) || (strcmp(argv[1]“-s“)==0)) {
sound_devices = 0;
printf(“Sound devices:
“);
if (DirectSoundEnumerateA(DirectSoundEnum NULL) != DS_OK){
printf(“Error: can‘t list the audio devices
“);
}
}
else
if ((strcmp(argv[1]“-display“)==0) || (strcmp(argv[1]“-d“)==0)) {
display_devices = 0;
printf(“Display devices:
“);
if (DirectDrawEnumerateExA(DirectDrawEnum NULL DDENUM_ATTACHEDSECONDARYDEVICES) != DS_OK) {
printf(“Error: can‘t list the display devices
“);
}
}
else
printf(“Unknown option %s
“ argv[1]);
return 0;
}
版权声明:本文内容由互联网用户自发贡献,该文观点仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容, 请发送邮件举报,一经查实,本站将立刻删除。
评论列表(条)