Click here to Skip to main content
Click here to Skip to main content

Tagged as

Go to top

Designing for Ultrabook

, 14 Oct 2012
Rate this:
Please Sign up or sign in to vote.
The design and planning in preparation of porting an iPad/iPhone app to Ultrabook.
This is an old version of the currently published article.

Please note

This article is an entry in our AppInnovation Contest. Articles in this sub-section are not required to be full articles so care should be taken when voting.

Sample Image

Introduction

Planet Minesweeper is a reimagining of the classic Minesweeper game in 3D, with the grid of squares replaced by a planet tiled with hexagons. This preserves the classic, beloved gameplay of Minesweeper but adds some new dimensions and even fixes some frustrating situations such as getting stuck in a corner.

I've been developing mobile apps as Tapnik since 2010. However, I've done over a decade of Windows programming (including console programming using Windows tools). I moved to mobile because I loved the immediacy and flexibility of the touch input and sensor-rich environment, now with the Ultrabooks (and Surface) on the horizon I’m excited to see these things return to a Windows environment.

Bringing Planet Minesweeper to Ultrabook

As soon as I heard about the Ultrabooks, I immediately thought of bringing Planet Minesweeper to this platform. I could maintain the smooth and intuitive touch controls of the tablet version, but also add some usability “power ups” for power users with the keyboard available. Additionally this would help on some of the interface screens. Finally, I was excited about the graphical capabilities of the Ultrabooks, some models would allow adding graphical pizazz that goes beyond the capabilities of current tablets.

Designing for Touch

I wanted to preserve what works well on tablets with the touch interface for manipulating the planet, but use the features of the Ultrabook to offer power users or hardcore players some shortcuts and options for a faster, more streamlined experience.

This screen is only a mockup, but it shows how Planet Minesweeper could fit in with the stylish Modern UI that Windows 8 provides. It also demonstrates that on an Ultrabook, much more information could be provided on the planet select screen. For example, the high scores and additional details are available right on the planet screen, whereas there's not space for them on the mobile phone version.

Interface Mockup

Here's some of the ideas sketched out for Planet Minesweeper:

  • Pressing "SPACE" to rotate the nearest unclear patch of mines. Sometimes it takes a bit of hunting around to find what's left to clear, especially on a huge planet. Having keyboard shortcuts lets me add features like these for hard-core players without cluttering the interface for new players.
  • A "compass" mode that aligns the onscreen planet with the actual earth beneath you, so you'd have to rotate the Ultrabook around to uncover it. Obviously you're not going to want to play like this all the time, but this would be a great challenge feature for a one-off achievement (like the "play a level upside down in Tiny Wings").
  • Subtle effects driven by sensors. For example, the ambient light sensor could drive shader parameters that control the bloom and color grading of the background skybox. These kinds of subtle but fascinating features aren't noticed consciously by most players, but make a strong emotional impression when they are noticed, and can help with PR and marketing because they provide interesting anecdotes to mention in reviews.
  • Taking advantage of the additional horsepower of the Ultrabook to add more effects such as particles and per-pixel lighting.

There's also a lot of possibilities opened up by the range of API's provided by the Ultrabook. Using Smart Connect, it might be possible to suspend a game on your Ultrabook during your commute, and resume it at the office at the same point in time. (During your lunch break, of course. Nobody would dream of playing Minesweeper at work, right).

Adapting the Code to Ultrabook

Planet Minesweeper currently targets OpenGL ES1 and ES2, whereas DirectX is the most straightforward graphics API on Ultrabooks. Luckily, the Planet Minesweeper rendering layer is abstracted through an abstract “IGraphics” interface. So implementing this interface against DirectX should give me an easy path to getting the rendering working on Ultrabooks.

For example:

// This is a bit of the game code...
m_gfx->clear( 0.1f, 0.3f, 0.7f, 1.0f );
m_gfx->setCamera( m_matModelviewProj );

Here's the implementation in the GraphicsES2 renderer used on iOS

void GraphicsES2::clear( float r, float g, float b, float a )
{
    glClearColor( r, g, b, a );
    glClear( GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT );   
}

And this would be the equivalent in the on the Ultrabook in GraphicsDX.

void GraphicsDX::clear( float r, float g, float b, float a )
{
    FLOAT ColorRGBA[4];
    ColorRGBA[0] = r;    ColorRGBA[1] = g; 
    ColorRGBA[2] = g; ColorRGBA[3] = a;

    m_deviceContext->ClearRenderTargetView(m_renderTargetView, color);  
    m_deviceContext->ClearDepthStencilView(m_depthStencilView,
        D3D11_CLEAR_DEPTH, 1.0f, 0);
}

Conclusion

As an indie developer, one of the greatest advantages you have is being able to move quickly to adopt new platforms as they emerge. The Ultrabooks represent a great opportunity for developers as they combine a proven development environment with cutting edge features like touch input and a myriad of sensors. I'd love to see Planet Minesweeper running on a sleek little Ultrabook.

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

Share

About the Author

Smitha Vijayan
The Code Project
United States United States
Smitha is a software developer, and has been in the industry since January 2000. She has experience in ASP.NET, C#, Windows Forms, Visual Basic, ASP, JavaScript, VBScript, and HTML. She has been with CodeProject since 2003 and currently works as Senior Editor.
 
In her free time, she tries out new dishes, reads a little, and puts together jigsaw puzzles. Originally from Trivandrum, Smitha currently lives with her husband and fellow CP'ian Nish [^] and her son Rohan in Columbus, Ohio.

Comments and Discussions


Discussions posted for the Published version of this article. Posting a message here will take you to the publicly available article in order to continue your conversation in public.
 
Generalpmines iOS version PinmemberJoel Davis (Tapnik)16-Oct-12 13:00 
QuestionI assume this is a Windows store (Metro) app? PinadminChris Maunder14-Oct-12 7:12 
AnswerRe: I assume this is a Windows store (Metro) app? PinmemberMember 800622814-Oct-12 7:23 
GeneralMy vote of 5 PinmemberMichael Haephrati14-Oct-12 5:13 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.

| Advertise | Privacy | Mobile
Web04 | 2.8.140916.1 | Last Updated 14 Oct 2012
Article Copyright 2012 by Smitha Vijayan
Everything else Copyright © CodeProject, 1999-2014
Terms of Service
Layout: fixed | fluid