如何做出象fraps软件在DIRECTX游戏画面上显示文字的效果!!
软件下载页面:http://www.fraps.com/downloads.htm    1.9D版的
||要源代码||[给出详细原理包括使用函数50分]
http://www.fraps.com/files/7/images/counterstrike-fraps-screenshot.jpg
如图左上角的那个黄颜色的数字。
他的是不会闪的,而且不会被游戏画面更新而覆盖掉

解决方案 »

  1.   

    这是我写的游戏里的一段代码:  DXDraw.Surface.Fill(0);
      if FNextScene = gsNone then
      begin
        SpriteEngine.Draw;    with DXDraw.Surface.Canvas do
        begin
          Font.Name := 'Arial Black';
          Font.Size := 8;
          Font.Color := clRed;
          TextOut(1, 50, 'RECORD:' + IntToStr(iif(FScore > FTolScore, FScore, FTolScore)));
          Textout(1, 34, 'SCORE:' + IntToStr(FScore));
          TextOut(1, 18, 'TAMA:' + IntToStr(TamaType));
          TextOut(1, 2, 'LIFE:' + IntToStr(iLife));
          if FFrame < 150 then
          begin
            if (FBlink div 300) mod 2 = 0 then
            begin
              Font.Name := 'Arial Black';
              Font.Color := clRed;
              Font.Size := 18;
              Textout((FaceWidth - TextWidth('SCENE ')) div 2, (FaceHeight - TextHeight('SCENE ')) div 2, 'SCENE ' + IntTostr(FRound));
            end;
            BlinkUpdate;
          end else
          begin
            Font.Name := 'Arial Black';
            Font.Size := 8;
            Font.Color := clMaroon;
            Textout(1, FaceHeight - 16, 'SCENE');
            Font.Color := clRed;
            TextOut(52, FaceHeight - 16, IntTostr(FRound));
          end;
          Release;
        end;  end;