TGPr7 graphics怎么样共用

后使用快捷导航没有帐号?
查看: 2374|回复: 10
UID最后登录积分40注册时间精华0主题帖子金币27 威望0 历史贡献0
初学乍到, 积分 40, 距离下一级还需 10 积分
出问题QQ号码:
你所在的地区:
你所使用的网络:
出问题的游戏:
游戏所在大区:
是否体验服:
正文请附截图:
以下输入框请附带文字描述和截图谢谢
TGP版本号:
用TGP进入LOL后,进入游戏,出门到两三级左右,硬盘灯一直亮着,显示硬盘负荷过大,游戏画面严重卡顿,第二场比赛时,卡顿更甚,再玩几把很有可能会导致崩溃,只能重启。
于是我不开TGP,开了其他加速器试了试,进入游戏后很顺畅,玩几把也不卡顿,更别说崩溃。
本人电脑系统win xp,电脑配置运行LOL是肯定够了,我同学电脑配置较高,没出现过这种问题。
所以,我猜测是TGP占用资源过大。
官方人员能给个解释吗?
UID9502047最后登录积分15250注册时间精华0主题帖子金币3502 威望40 历史贡献0
学长师友, 积分 15250, 距离下一级还需 9750 积分
玩家麻烦把你电脑配置等相关信息给我们吗?
UID最后登录积分40注册时间精华0主题帖子金币27 威望0 历史贡献0
初学乍到, 积分 40, 距离下一级还需 10 积分
JIGsaw-竖锯 发表于
玩家麻烦把你电脑配置等相关信息给我们吗?
电脑型号& & & & X86 兼容 台式电脑
操作系统& & & & Windows XP 专业版 32位 SP3 ( DirectX 9.0c )
处理器& & & & 英特尔 Celeron(赛扬) G530 @ 2.40GHz
主板& & & & 昂达 H61N (英特尔 H61 芯片组)
内存& & & & 2 GB ( 金士顿 DDR3 1333MHz )
主硬盘& & & & 希捷 ST500DM002-1BD142 ( 500 GB / 7200 转/分 )
显卡& & & & 英特尔 HD Graphics Family ( 512 MB / 英特尔 )
显示器& & & & 宏碁 ACR0304 Acer K191WV ( 19.1 英寸 )
声卡& & & & 英特尔 Display Audio @ 英特尔 6 Series Chipset 高保真音频
网卡& & & & 瑞昱 RTL8105E Family PCI-E FE NIC
UID最后登录积分11195注册时间精华0主题帖子金币5722 威望0 历史贡献0
出入大神, 积分 11195, 距离下一级还需 3805 积分
卡车一号 发表于
电脑型号& & & & X86 兼容 台式电脑
操作系统& & & & Windows XP 专业版 32位 SP3 ( DirectX 9.0c )
LZ使用的什么加速模式呢?
TGP版主您服务。有问题欢迎反馈。
如果我的回答不能解决您的问题,请您
咨询企业QQ(请查找服务号)
或者加TGP核心用户反馈群
UID最后登录积分40注册时间精华0主题帖子金币27 威望0 历史贡献0
初学乍到, 积分 40, 距离下一级还需 10 积分
不离弃不放弃 发表于
LZ使用的什么加速模式呢?
强制加速模式
UID最后登录积分20540注册时间精华0主题帖子金币3047 威望90 历史贡献0
学长师友, 积分 20540, 距离下一级还需 4460 积分
提示: 作者被禁止或删除 内容自动屏蔽
UID最后登录积分40注册时间精华0主题帖子金币27 威望0 历史贡献0
初学乍到, 积分 40, 距离下一级还需 10 积分
TGP问题收集专用 发表于
不开加速是否正常??
额,我开TGP就是为了加速的,我是移动的网,TGP的加速还是很给力的,竟然比腾讯自己的网游加速小助手还给力,而且那不是免费的,无语。
UID最后登录积分770注册时间精华0主题帖子金币255 威望0 历史贡献0
崭露头角, 积分 770, 距离下一级还需 430 积分
请发布一下硬件信息。好做一下判断
LV 85.热心助人的小双
UID最后登录积分8095注册时间精华0主题帖子金币1959 威望0 历史贡献0
挥洒自如, 积分 8095, 距离下一级还需 1905 积分
卡车一号 发表于
额,我开TGP就是为了加速的,我是移动的网,TGP的加速还是很给力的,竟然比腾讯自己的网游加速小助手还给 ...
跨网用户建议使用强制加速!
TGP核心用户反馈群
TGP综合测试群
可以加QQ:
以上方式均可以反馈
UID393102最后登录积分60注册时间精华0主题帖子金币14 威望0 历史贡献20
勤奋好学, 积分 60, 距离下一级还需 90 积分
游戏崩溃&&经常出现错误报告 盘盘都要掉一次 我伤不起阿 无限视距也没有 战斗力也没有 这些都不重要 但是别盘盘都掉线阿 既然想让我们用 那么请完善并且超越别的辅助软件 好吗?
UID最后登录积分20540注册时间精华0主题帖子金币3047 威望90 历史贡献0
学长师友, 积分 20540, 距离下一级还需 4460 积分
提示: 作者被禁止或删除 内容自动屏蔽
Powered byBTAP church - Home
2016 TGP Graphics & Print - All Rights Reserved
GWENNA SPAN
Ministries
Power Packed Preaching& |& Prophecy& |& & Principles with PracticalityDraw rotate multiline text with GDI and GDI+ [用GDI和GDI+旋转多行文本] - 问题-字节技术
Draw rotate multiline text with GDI and GDI+
用GDI和GDI+旋转多行文本
问题 (Question)
On my Delphi application I need draw a multiline text with GDI and GDI+.
I have these items:
Rotate angle (the text may be rotate);
Max width (imagine the rectangle that contains the text, I have a limit for rectangle width but not for rectangle height);
Is there a easy way to draw this text both with GDI and GDI+?
I cannot found GDI and GDI+ functions about it.
我需要在我的Delphi应用程序与GDI和GDI+绘制多行文本。我这些:文本绘制;旋转角度(文本可以转动);最大宽度(想象包含文本的矩形,矩形的宽度有限制但不为矩形的高度);字体名称和字体高度;有一个画这个文本与GDI和GDI+简单的方法?我不能发现GDI和GDI+功能。
最佳答案 (Best Answer)
Use graphics32 with GR32_Text.
For GDI, the simplest way is to use the escapement and orientation properties of the font. For instance:
procedure TForm1.PaintBox1Paint(Sender: TObject);
Text = 'Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do '
+ 'eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim '
+ 'ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut '
+ 'aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit '
+ 'in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur '
+ 'sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt '
+ 'mollit anim id est laborum.';
Canvas: TC
lf: LOGFONT;
Canvas := PaintBox1.C
Canvas.Brush.Style := bsC // Set the brush style to transparent.
lf := Default(LOGFONT);
lf.lfHeight := 20;
lf.lfCharSet := DEFAULT_CHARSET;
lf.lfFaceName := 'Times New Roman';
angle := 15;
lf.lfEscapement := 10*//lfEscapement measured in 1/10th of degree
lf.lfOrientation := lf.lfE
Canvas.Font.Handle := CreateFontIndirect(lf);
R := PaintBox1.ClientR
inc(R.Top, 200);
DrawText(Canvas.Handle, Text, -1, R, DT_NOCLIP or DT_WORDBREAK);
which produces the rather strangely laid out:
Using SetWorldTransform gives a different layout, although still rather poor quality:
procedure TForm1.PaintBox1Paint(Sender: TObject);
Text = 'Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do '
+ 'eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim '
+ 'ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut '
+ 'aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit '
+ 'in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur '
+ 'sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt '
+ 'mollit anim id est laborum.';
Transform: TXF
Canvas: TC
lf: LOGFONT;
Canvas := PaintBox1.C
angle := 15;
Transform := Default(TXForm);
SinCos(DegToRad(-angle), Transform.eM12, Transform.eM11);
Transform.eM22 := Transform.eM11;
Transform.eM21 := -Transform.eM12;
SetGraphicsMode(Canvas.Handle, GM_ADVANCED);
SetWorldTransform(Canvas.Handle, Transform);
Canvas.Brush.Style := bsC // Set the brush style to transparent.
lf := Default(LOGFONT);
lf.lfHeight := 20;
lf.lfCharSet := DEFAULT_CHARSET;
lf.lfFaceName := 'Times New Roman';
Canvas.Font.Handle := CreateFontIndirect(lf);
R := PaintBox1.ClientR
inc(R.Top, 200);
inc(R.Left, Round(200*Transform.eM12));
DrawText(Canvas.Handle, Text, -1, R, DT_NOCLIP or DT_WORDBREAK);
Frankly, I think you are not going to get good results using either of these approaches. If I were you I would use a good library such as graphics32 with Angus Johnson's :
For GDI+, the results are much the same as for GDI. Sample code would be:
GDIPAPI, GDIPOBJ;
{$TYPEDADDRESS ON}
procedure TForm1.PaintBox1Paint(Sender: TObject);
Text = 'Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do '
+ 'eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim '
+ 'ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut '
+ 'aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit '
+ 'in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur '
+ 'sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt '
+ 'mollit anim id est laborum.';
Graphics: TGPG
Font: TGPF
Brush: TGPB
lf: LOGFONT;
Graphics := TGPGraphics.Create(PaintBox1.Canvas.Handle);
Graphics.SetTextRenderingHint(TextRenderingHintSystemDefault);
lf := Default(LOGFONT);
lf.lfHeight := 20;
lf.lfCharSet := DEFAULT_CHARSET;
lf.lfFaceName := 'Times New Roman';
Font := TGPFont.Create(PaintBox1.Canvas.Handle, @lf);
Brush := TGPSolidBrush.Create(MakeColor(0, 0, 0));
Graphics.RotateTransform(-15);
Graphics.DrawString(
MakeRect(0.0, 150.0, 450.0, 600.0),
Graphics.F
And the output:
Still pretty naff looking in my view. So for best quality, I would recommend graphics32 with GR32_Text.
译文;博士使用与gr32_text Graphics32。对于GDI来说,最简单的方法是使用字体的位移和方向特性。例如:procedure TForm1.PaintBox1Paint(Sender: TObject);
Text = 'Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do '
+ 'eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim '
+ 'ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut '
+ 'aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit '
+ 'in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur '
+ 'sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt '
+ 'mollit anim id est laborum.';
Canvas: TC
lf: LOGFONT;
Canvas := PaintBox1.C
Canvas.Brush.Style := bsC // Set the brush style to transparent.
lf := Default(LOGFONT);
lf.lfHeight := 20;
lf.lfCharSet := DEFAULT_CHARSET;
lf.lfFaceName := 'Times New Roman';
angle := 15;
lf.lfEscapement := 10*//lfEscapement measured in 1/10th of degree
lf.lfOrientation := lf.lfE
Canvas.Font.Handle := CreateFontIndirect(lf);
R := PaintBox1.ClientR
inc(R.Top, 200);
DrawText(Canvas.Handle, Text, -1, R, DT_NOCLIP or DT_WORDBREAK);
产生很奇怪了:使用SetWorldTransform给出了一个不同的布局,虽然质量仍然很差:procedure TForm1.PaintBox1Paint(Sender: TObject);
Text = 'Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do '
+ 'eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim '
+ 'ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut '
+ 'aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit '
+ 'in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur '
+ 'sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt '
+ 'mollit anim id est laborum.';
Transform: TXF
Canvas: TC
lf: LOGFONT;
Canvas := PaintBox1.C
angle := 15;
Transform := Default(TXForm);
SinCos(DegToRad(-angle), Transform.eM12, Transform.eM11);
Transform.eM22 := Transform.eM11;
Transform.eM21 := -Transform.eM12;
SetGraphicsMode(Canvas.Handle, GM_ADVANCED);
SetWorldTransform(Canvas.Handle, Transform);
Canvas.Brush.Style := bsC // Set the brush style to transparent.
lf := Default(LOGFONT);
lf.lfHeight := 20;
lf.lfCharSet := DEFAULT_CHARSET;
lf.lfFaceName := 'Times New Roman';
Canvas.Font.Handle := CreateFontIndirect(lf);
R := PaintBox1.ClientR
inc(R.Top, 200);
inc(R.Left, Round(200*Transform.eM12));
DrawText(Canvas.Handle, Text, -1, R, DT_NOCLIP or DT_WORDBREAK);
坦率地说,我认为你不去使用这些方法得到好的结果。如果我是你,我会用一个很好的图书馆如Graphics32与安古斯约翰逊:GDI +,结果都是一样的GDI。示例代码将:uses
GDIPAPI, GDIPOBJ;
{$TYPEDADDRESS ON}
procedure TForm1.PaintBox1Paint(Sender: TObject);
Text = 'Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do '
+ 'eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim '
+ 'ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut '
+ 'aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit '
+ 'in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur '
+ 'sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt '
+ 'mollit anim id est laborum.';
Graphics: TGPG
Font: TGPF
Brush: TGPB
lf: LOGFONT;
Graphics := TGPGraphics.Create(PaintBox1.Canvas.Handle);
Graphics.SetTextRenderingHint(TextRenderingHintSystemDefault);
lf := Default(LOGFONT);
lf.lfHeight := 20;
lf.lfCharSet := DEFAULT_CHARSET;
lf.lfFaceName := 'Times New Roman';
Font := TGPFont.Create(PaintBox1.Canvas.Handle, @lf);
Brush := TGPSolidBrush.Create(MakeColor(0, 0, 0));
Graphics.RotateTransform(-15);
Graphics.DrawString(
MakeRect(0.0, 150.0, 450.0, 600.0),
Graphics.F
和输出:还是很蹩脚,看在我看来。因此,最好的质量,我建议用gr32_text Graphics32。
答案 (Answer) 2
The basics seem to be simple:
procedure TForm2.FormPaint(Sender: TObject);
S = 'Multiline sample text with 50 degrees rotation';
NewFont: HFONT;
OldFont: HFONT;
TextHeight: I
R := ClientR
InflateRect(R, -20, -20);
NewFont := CreateFont(-H, 0, A * 10, A * 10, FW_NORMAL, 0, 0, 0,
DEFAULT_CHARSET, OUT_TT_ONLY_PRECIS, CLIP_DEFAULT_PRECIS, DEFAULT_QUALITY,
DEFAULT_PITCH, 'Tahoma');
OldFont := SelectObject(Canvas.Handle, NewFont);
DrawText(Canvas.Handle, S, -1, R, DT_LEFT or DT_BOTTOM or
DT_WORDBREAK or DT_NOCLIP);
DeleteObject(SelectObject(Canvas.Handle, OldFont));
But it is not for multiline text:
What you need to do is not use the rotation at font level, but at canvas level, with .
基础似乎很简单:procedure TForm2.FormPaint(Sender: TObject);
S = 'Multiline sample text with 50 degrees rotation';
NewFont: HFONT;
OldFont: HFONT;
TextHeight: I
R := ClientR
InflateRect(R, -20, -20);
NewFont := CreateFont(-H, 0, A * 10, A * 10, FW_NORMAL, 0, 0, 0,
DEFAULT_CHARSET, OUT_TT_ONLY_PRECIS, CLIP_DEFAULT_PRECIS, DEFAULT_QUALITY,
DEFAULT_PITCH, 'Tahoma');
OldFont := SelectObject(Canvas.Handle, NewFont);
DrawText(Canvas.Handle, S, -1, R, DT_LEFT or DT_BOTTOM or
DT_WORDBREAK or DT_NOCLIP);
DeleteObject(SelectObject(Canvas.Handle, OldFont));
但它不是多行文本:你需要做的是不是在使用字体水平旋转,但在画布的水平,与。
本文翻译自StackoverFlow,英语好的童鞋可直接参考原文:随笔 - 211&
文章 - 1&评论 - 22&trackbacks - 0
GDI+可以通过以下四种方法创建Graphics(图形环境)对象:
1.通过窗体canvas的句柄创建,如:
g:=TGPGraphics.Create(Canvas.Handle);
p:=TGPPen.Create(aclRed,2);
g.DrawLine(p,20,40,150,40);
2.通过其它有canvas的VCL画布句柄创建,如:
g:=TGPGraphics.Create(Image1.Canvas.Handle);
p:=TGPPen.Create(aclRed,2);
g.DrawLine(p,20,40,150,40);
3.通过位图(TGPBitmap)创建Graphics,如:
g1,g2:TGPG
bit:=TGPBitmap.Create(152,42);
//创建一个宽152,高42的位图对象
g1:=TGPGraphics.Create(bit);
//通过位图创建Graphics (g1)
p:=TGPPen.Create(aclRed,2);
//创建画笔对象
g1.DrawEllipse(p,0,0,150,40);
//在g1上画一个椭圆,此时的g1还在内存中,我们还看不到
g2:=TGPGraphics.Create(Canvas.Handle); //通过窗体canvas的句柄创建另一个Graphics (g2)
g2.DrawImage(bit,0,0,150,40);
//把g1当成图片画在g2上
4.通过位图(TGPBitmap)创建Graphics,如:
g1,g2:TGPG
img:=TGPImage.Create('d:\mm.jpg');
//从指定文件名创建一个图像对象
g1:=TGPGraphics.Create(img);
//通过图像对象创建Graphics (g1)
p:=TGPPen.Create(aclRed,2);
//创建画笔对象
g1.DrawEllipse(p,0,0,150,40);
//在g1上画一个椭圆,此时的g1还在内存中,我们还看不到
g2:=TGPGraphics.Create(Canvas.Handle); //通过窗体canvas的句柄创建另一个Graphics (g2)
g2.DrawImage(img,0,0,img.GetWidth,img.GetHeight);
//把g1(图形环境)当成图片画在g2上
&Graphics类(图形环境)提供了很多方法给我们调用,以下是方法表:
DrawLine&&&&&&&&&&&&&&&& 绘制直线
DrawLines&&&&&&&&&&&&&& 绘制一组直线
DrawRectangle&&&&&&&& 绘制矩形
DrawRectangles&&&&&& 绘制一组矩形
DrawEllipse&&&&&&&&&&&&&&绘制椭圆
DrawCurve&&&&&&&&&&&&&&绘制曲线(基数样条)
DrawClosedCurve&&& &绘制闭合曲线
DrawBezier&&&&&&&&&&&&& 绘制贝塞尔曲线
DrawBeziers&&&&&&&&&&& 绘制一组贝塞尔曲线
DrawArc&&&&&&&&&&&&&&&&&绘制弧线
DrawPie&&&&&&&&&&&&&&&&&&绘制扇形(饼形)
DrawPolygon&&&&&&&&&& 绘制多边形
DrawString&&&&&&&&&&&& 绘制字符串
DrawIcon&&&&&&&&&&&&&&& 绘制图标
DrawIconUnstretched
DrawImage&&&&&&&&&&&&&&绘制图像
DrawImageUnscaled
DrawImageUnscaledAndClipped
DrawPath&&&&&&&&&&&&&&&& 绘制路径
FillRectangle&&&&&&&&&&&& 填充矩形
FillRectangles&&&&&&&&&& 填充一组矩形
FillEllipse&&&&&&&&&&&&&&&&& 填充椭圆
FillClosedCurve&&&&&&&&&填充闭合曲线
FillPie&&&&&&&&&&&&&&&&&&&&&&&填充扇形
FillPolygon&&&&&&&&&&&&&&&&填充多边形
FillRegion&&&&&&&&&&&&&&&& 填充区域
FillPath&&&&&&&&&&&&&&&&&&& 填充路径
Clear&&&&&&&&&&&&&&&&&&&&&& 清空图形环境(画布)
BeginContainer
EndContainer
CreateObjRef
CopyFromScreen
ExcludeClip
FromHdcInternal
FromHwndInternal
GetContextInfo
GetHalftonePalette
GetHashCode
GetLifetimeService
GetNearestColor
InitializeLifetimeService
IntersectClip
AddMetafileComment
EnumerateMetafile
MeasureCharacterRanges
MeasureString
MemberwiseClone
MultiplyTransform
ReleaseHdc
ReleaseHdcInternal
ResetTransform
RotateTransform
ScaleTransform
TransformPoints
TranslateClip
TranslateTransform
阅读(...) 评论()TGPGraphics怎么共用 - Delphi当前位置:& &&&TGPGraphics怎么共用TGPGraphics怎么共用&&网友分享于:&&浏览:174次TGPGraphics如何共用初学GDI+,有一问题,TGPGraphics是否每次都要重新创建?例如我想实现这个功能:多个GPImage合成到一个GPImage,最后画到窗体上,我先用TGPGraphics.Create(AGPImage)和DrawImage实现了多个GPImage的合成,然后TGPGraphics.Create(Form.Canvas.Handle)创建了一个新的GPGraphics将这个AGPImage画出来。请问如何只创建一个GPGraphics实现这两次绘制?另外,我的图片合成方法有问题吗?------解决方案--------------------晕,你直接画两次就可以了!可以共用!
------解决方案--------------------确实是这样的,TGPGraphics只能画一次,所以TGPGraphics也不能全局来用,就是一开始Create后,然后以后再用是不行的
------解决方案--------------------TGPGraphics在函数结束它会自动释放它的DC,所以要重新指定,不要指定为AWinControl.Handle ,因为你不知道这个是句柄还是DC
12345678910
12345678910
12345678910 上一篇:下一篇:文章评论相关解决方案 12345678910 Copyright & &&版权所有

我要回帖

更多关于 mekko graphics怎么用 的文章

 

随机推荐