急问关于windows mobile direct3d 的问题

forestwind 2009-11-04 02:09:04
刚开始用windows mobile direct3d库,很是不熟悉,网上大多数tutorial都是不是为windows mobile 服务的,本想照葫芦画瓢画个最简单的三角形,但是device.VertexFormat由于库里没有,那个三角形就死活也显示不出来, 简单贴一下其中一小段代码

protected override void OnPaint(PaintEventArgs e)
{
//。。。。。省略之前vertex设置
device.Clear(ClearFlags.Target, System.Drawing.Color.LightBlue.ToArgb(), 1.0f, 0);

device.BeginScene();


device.VertexFormat = CustomVertex.TransformedColored.Format;
device.DrawUserPrimitives(PrimitiveType.TriangleList, 1, vertexes);

device.EndScene();
device.Present();
}
其中device.VertexFormat跟device.DrawUserPrimitives都因库不支持而报错,三角形也因此显示不了,哪位高人给指点下,这种到底应该怎么办
另外,哪位兄弟有这种windows mobile direct3d详细的tutorial跟例子什么的,给分享下,微软那个slides已经有了,有没有别的,万分感谢
...全文
34 2 打赏 收藏 转发到动态 举报
写回复
用AI写文章
2 条回复
切换为时间正序
请发表友善的回复…
发表回复
forestwind 2009-11-04
  • 打赏
  • 举报
回复
汗,我再顶顶,坐等高人
forestwind 2009-11-04
  • 打赏
  • 举报
回复
自己顶一下好了,哪位大牛给回答一下
Book Description Learn how to develop exciting tablet and PC games for Windows 8 using practical, hands-on examples Overview Use cutting-edge technologies like DirectX to make awesome games Discover tools that will make game development easier Bring your game to the latest touch-enabled PCs and tablets In Detail With the recent success of a lot of smaller games, game development is quickly becoming a great field to get in to. Mobile and PC games are on the rise, and having a way to create a game for all types of devices without rewriting everything is a huge benefit for the new Windows 8 operating system. In this book, you will learn how to use cutting-edge technologies like DirectX and tools that will make creating a game easy. This book also allows you to make money by selling your games to the world. Learning Windows 8 Game Development teaches you how to create exciting games for tablets and PC on the Windows 8 platform. Make a game, learn the techniques, and use them to make the games you want to play. Learn about graphics, multiplayer options, how to use the Proximity + Socket APIs to add local multiplayer, how to sell the game outright, and In-App Purchases. Learning Windows 8 Game Development guides you from the start of your journey all the way to developing games for Windows by showing you how to develop a game from scratch and sell it in the store.With Learning Windows 8 Game Development, you will learn how to write the code required to set everything up, get some graphics on screen, and then jump into the fun part of adding gameplay to turn a graphics sample into a proper game. From there, you’ll look at how to add awesome features to your game like networking, motion controls, and even take advantage of new Windows 8 features like live tiles and sharing to make your players want to challenge their friends and keep playing. This book wraps up by covering the only way a good game can finish development: by shipping the game on the Windows Store. You’ll look at the things to remember to make certification painless and some great tips on how to market and sell your game to the public. What you will learn from this book Render sprites in 2D Use touch, gamepad, mouse, and keyboard input to control the game Learn the techniques to add multiplayer to your game Add competition with accessible Windows 8 features Use motion sensors and GPS to add unique gameplay Master techniques to maximise your Windows Store effectiveness Learn tips and tricks to pass store certification Kick-start the next stage of gaming with 3D rendering Approach A standard practical tutorial running people through Windows 8 RT with a specific focus on game development is the approach chosen here. This type of approach will more likely appeal to an audience that is in need of a structured guide that they can emulate and learn from, unlike the usual reference text available in the market. Who this book is written for Learning Windows 8 Game Development is for any developer looking to branch out and make some games. It’s assumed that you will have an understanding of C++ and programming. If you want to program a game, this book is for you, as it will provide a great overview of Direct3D and Windows 8 game development and will kick-start your journey into 3D development.

110,536

社区成员

发帖
与我相关
我的任务
社区描述
.NET技术 C#
社区管理员
  • C#
  • Web++
  • by_封爱
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告

让您成为最强悍的C#开发者

试试用AI创作助手写篇文章吧