QQ登录

只需一步,快速开始

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 2205|回复: 1

刺猬大战 hedgewars 0.9.19.3 编译成功

[复制链接]
发表于 2013-11-5 13:27:37 | 显示全部楼层 |阅读模式
刺猬大战 hedgewars 0.9.19.3 编译,因为 ffmpeg 版本打了个补丁如下,它自带了文泉驿字体和一个WIN上的字体不能删,否则进不了游戏。。。昨天搞半天原来这么回事,文泉驿字体我搞了个链接,删掉自带的文泉驿字体,原来的那个 DejaVuSans-Bold.ttf 字体 MGC3 没有了,在 spec 档里把链接那几行代码删了,用上它自带的 DejaVuSans-Bold.ttf,编译运行 OK。
  1. --- hedgewars-src-0.9.19.3/QTfrontend/util/LibavInteraction.cpp        2013-06-11 07:26:50.000000000 +0000
  2. +++ hw-master/QTfrontend/util/LibavInteraction.cpp        2013-11-05 12:58:15.735985653 +0000
  3. @@ -32,7 +32,7 @@

  4. struct Codec
  5. {
  6. -    CodecID id;
  7. +    AVCodecID id;
  8.      bool isAudio;
  9.      QString shortName; // used for identification
  10.      QString longName; // used for displaying to user
  11. @@ -52,7 +52,7 @@
  12. QMap<QString,Format> formats;

  13. // test if given format supports given codec
  14. -bool FormatQueryCodec(AVOutputFormat *ofmt, enum CodecID codec_id)
  15. +bool FormatQueryCodec(AVOutputFormat *ofmt, enum AVCodecID codec_id)
  16. {
  17. #if LIBAVFORMAT_VERSION_MAJOR >= 54
  18.      return avformat_query_codec(ofmt, codec_id, FF_COMPLIANCE_NORMAL) == 1;
  19. @@ -278,7 +278,7 @@
  20.          return "";

  21.      int s = float(pContext->duration)/AV_TIME_BASE;
  22. -    QString desc = QString(tr("Duration: %1m %2s\n")).arg(s/60).arg(s%60);
  23. +    QString desc = tr("Duration: %1m %2s").arg(s/60).arg(s%60) + "\n";
  24.      for (int i = 0; i < (int)pContext->nb_streams; i++)
  25.      {
  26.          AVStream* pStream = pContext->streams[i];
  27. @@ -290,11 +290,11 @@

  28.          if (pCodec->codec_type == AVMEDIA_TYPE_VIDEO)
  29.          {
  30. -            desc += QString(tr("Video: %1x%2, ")).arg(pCodec->width).arg(pCodec->height);
  31. +            desc += QString(tr("Video: %1x%2")).arg(pCodec->width).arg(pCodec->height) + ", ";
  32.              if (pStream->avg_frame_rate.den)
  33.              {
  34.                  float fps = float(pStream->avg_frame_rate.num)/pStream->avg_frame_rate.den;
  35. -                desc += QString(tr("%1 fps, ")).arg(fps, 0, 'f', 2);
  36. +                desc += QString(tr("%1 fps")).arg(fps, 0, 'f', 2) + ", ";
  37.              }
  38.          }
  39.          else if (pCodec->codec_type == AVMEDIA_TYPE_AUDIO)
复制代码

本帖子中包含更多资源

您需要 登录 才可以下载或查看,没有账号?注册

×
 楼主| 发表于 2013-11-5 13:28:52 | 显示全部楼层
0ad 和 warzone2100 也编译成功了,置顶帖有就不上图了。
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

GMT+8, 2024-4-20 15:27 , Processed in 0.125747 second(s), 16 queries .

© 2021 Powered by Discuz! X3.5.

快速回复 返回顶部 返回列表