June 25, 2017

How Big Is HoloLens’ Field of View?



I have said this too many times, but there are still a lot of dumb asses in media do have a clue.

47″ TV: 19 x 11 degree
HoloLens: 30 X 18 degree

The above screenshot from Microsoft’s recent concept video shows just that. I know that’s a mock up, but it agrees to my estimation perfectly.



HoloLens SDK Is Expected to Release Soon!



As a number of people who have followed my blog noticed that I am writing a HoloLens programming series. I am ready to bring in another post with detailed programming technique and a working example based on my recent research on HoloLens programming. Just before I do so, I checked with the some great people that I have access to, just making sure that I am on the right direction, and that I am not misleading my readers. I got some information that is beyond exiting. I can’t contain my excitement. How reliable is my source? Well, I rarely say things that I am not sure of. Talking is cheap, lets get to is.

(We’re) working hard to release development tools and are looking forward to sharing information on the SDK for Microsoft HoloLens soon. The best way to ensure you receive developer updates and holographic APIs when available is to join the Windows Insider Program and install the Windows 10 Technical Preview. You can also start by building Windows universal apps and ramping up on Unity.

If you are a developer, you don’t need me to say anything more. This a what everyone is waiting for. I wonder why Microsoft didn’t make it available earlier.

For now, I will hold off my HoloLens programming series. Lets talk about it more when the new SDK is released. I think the date should be in line with Dev version of HoloLens hardware release, which is within two months.



HoloLens Programming in C# and DirectX – A Closer Look


Edit: The content of this is still valid, but some of the practice may not be ideal, please here for details.

We are not ready for the code yet. Before I show you how I do C# and DirectX, I want to do two things in one post: 1. Show you all the options we have for programming DirectX in C#. 2. Give you a little introduction about what the hell DirectX is. Lets get to it.

What are the options?

1. Unity + C# script.
As I said in the previous posts, this is not an option for HoloLens apps. Because Unity is for games only. You can still do apps with Unity, but it is going to be resource intensive, as you may expect for a game. If you have large amount of 3D visuals, like in a flight simulation, or the one like Case Western Reserve University does with HoloLens, you are still better off with Unity, but for light 3D rendering, mostly business logic and communication or things like a normal app does, you better write an app instead of a game. You need to look for something other than Unity, or any other game engines.

It would be ideal if Unity or another game engine manage rendering in the way like an app does, that would great for application development, but that’s not the case now. If the app itself has very dynamic objects in the scene, they are moving all the time, and requires fastest response possible from the user, then you have to go with game, no matter it is called a game or not.

2. C++/C# UWP app with DirectX in CoreWindow
CoreWindow is a class that represents the utter most application window of a UWP app. There are two project templates in Visual Studio 2015: DirectX 11 App and DirectX 12 App (New Project -> Visual C++ -> Windows -> Universal ->). Either of those two template generates bare bone code that is based on CoreWindow.

The templates titled “App”, but they are actually games. There is a game loop on app level. Visual updates are done at a possible frame rate. The DirectX rendering target is the app’s CoreWindow. The two templates are C++ projects, as I will show you in next post, it is very much possible to code DirectX in C++ and C# for rest parts, but this one is not our interest, because again, it is a game, not an app.

Let me try one more time to make it clear about the difference between an app and a game from a developer’s point of view. A game tries to use as much CPU/GPU as possible to satisfy a game’s need for frame rate. That’s why it runs on game loop to update visuals, instead of let the system handle them. Lets say, beside display and interaction, your app have a lot of other task to do, if your application is trying every 20 ms to update visuals, what time is left for everything else? I just found it’s not the ideal way of programming.

3. C++/C# DirectX with SwapChainPanel
SwapChainPanel is a xaml control designed to make DirectX work inside of the xaml controls. This is much like XNA and Silverlight interop in the past. It achieve the best of both world. Usually you put SwapChainPanel as the main scene, with other controls work as overlay. SwapChainPanel deal with DirectX rendering. However, the design of SwapChainPanel is still game oriented. You may use SwapChainPanel as islands among other controls, but the general guideline from Microsoft is SwapChainPanel targeting game development.

By the way, there was a SwapChainBackgroundPanel, which is replace by SwapChainPanel.

4. C++/C# DirectX with SurfaceImageSource
SurfaceImageSource works like general ImageSource for XAML controls. Many XAML controls can have ImageSource, SurfaceImageSource works in similar way, the difference is SurfaceImageSource is a surface for DirectX renderings. The resource of than rendering can be used as a image source for many different controls. In the next post, I will show you how to do the rendering part in C++, and everything else C#, like what you do in any UWP apps.

5. C++/C# DirectX with VirtualSurfaceImageSource
VirtualSurfaceImageSource is the same as SurfaceImageSource, except the former is for DirectX rendering of unlimited size, usually larger than the screen size. This is, I think, the best fit for HoloLen applications, because your visuals are likely spreading in the space instead of a small window. In the post after next one, I will show you a working example of that.

So, what the hell is DirectX any way?

DirectX is the ultimate 3D rendering APIs provide by all modern Windows OSes. Whatever 3D engines you know that work on Windows, work on top of DirectX. Being Unity, XNA, Unreal Engine, or any others, there is no exception, they are on top of DirectX.

DirectX is a collection of APIs that do not only 3D, also 2D, Text, Texture, shaders, that’s the X in DirectX. They are:

* Direct3D – for 3D objects
* Direct2D – for 2D overlays
* DriectWrite – for text
* Untilities: DirectXMath, XAudio, XInput

That’s not all, the following are parts of the DirectX subsystem:

* DXGI – Microsoft DirectX Graphics Infrastructure, deals with display devices directly. Because 3D drawing need to be faster than usual, that’s why programmer are required to deal with hardware directly. That’s the interface for it.
* HLSL – High Level Shading Language for DirectX. You write shading in this special language, with extension .hlsl, Visual Studio will compile it to binary.

In DiretX programming, you hear one term a lot, but it doesn’t make sense to most people, that’s Swap Chain. Forget about “swap” or “chain”, think of it as a display buffer, you write on the buffer instead of the monitor itself, the video card will take care of it. The reason it is called a chain because there are more than one buffers, one after another to improve performance. Why swap, well, you don’t need to know. Swap chain has nothing to do with DirectX, it is part of display technology existed long time ago.

Why DirectX programming is hard?

There are two reasons, and two only: 1. the designer of DirectX decided to use stupid names for their APIs, like D3D11CreateDevice(). Fyi, take this one for example, D3D11 means Direct3D version 11. They could just call it CreateDeive(), but they decided to make our lives harder. 2. We don’t do 3D that much. But I promise you, it is just a matter of familiarity. When you see the term “Swap Chain” or the ugly function names the 20th time, they start making sense to you.

That’s it. Next up is an example of SurfaceImageSource, then there is another sample code of VirtualSurfaceImageSource.



HoloLens Programming in C# and DirectX – The Big Picture



We need to be clear about this first: what is developing a HoloLens app? HoloLens is a computer running on Windows 10, by definition, every UWP application should be able to run on HoloLens. So if you write an app for Windows 10 UWP, and publish it to Windows Store. It should run on HoloLens, the way it runs on Windows desktop computers. However, that’s not what I mean by developing for HoloLens. Developing for HoloLens means your app takes advantage of HoloLens 3D mixed reality display, and optionally utilize spatial mapping, hand gestures and voice input. In this post and a few others after this, I only explore 3D display, in the context of HoloLens reality mode, not within a floating/pinned window as for a normal UWP app.

In multiple occasions, Microsoft had hinted Unity with C# script would the way build HoloLens apps. I don’t disagree. Unity is a high level game engine, especially for 3D/2D screen rendering. It is in the same position as XNA was before. Because XNA is no long supported in Windows 10. Unity is probably the best replacement. Unity is recommended for game development in general, not just for HoloLens. Even though you can do DirectX directly, but Unity would make many complicated task much easier otherwise. Also, the Unity Store has tons of stuff for asset creation, some of them are free.

Unity runtime is written in C++, so your C# code for Unity is called C# script, meaning they are not compiled to .Net code. On the low level, Unity is based on DirectX. It is a high level wrapper of DirectX, but a lot more than just a wrapper. The compilation of a Unity project results in a Visual Studio project. There you can deploy, run and debug on HoloLens. To get start with Unity game development, I recommend Adam Tuliper’s post on MSDN: Unity : Developing Your First Game with Unity and C#.

It is clear that if you want to develop a HoloLens 3D Holographic game, or simulation app, like fly simulation, or educational holographic 3D illustration, you can safely choose Unity with C# scripting. Then use Visual Studio to deploy and test on HoloLens.

That’s all good… but, there is a problem.

Unity is a game engine, it is NOT an app engine. The same way XNA is a game engine, not an app engine. I have been asking this question: can you write an app on Unity? Now it is clear, the answer is NO. Of course you can call a fly simulator an app instead of a game, but a game and an app are intrinsically different. Allow me to explain.

A game requires fast real time response and fast real time visual refresh. It sacrifice everything to satisfy the above too requirements. That’s why a game is always running on it own separately loop, called the game loop. An app, on the other hand, is supposed to be on idle until there is input from a user. An app tries to use as less resource as possible. An app is running under system message loop, it is message based. The system take care of visual update.

If you are developing an app instead of a game, you don’t want your application in a busy loop. You don’t want your app to use as much resource as possible to gain frame rate. You want your app to be friendly to other apps.

So, if you develop an app, Unity is out of picture, but you still want to show 3D holograms. Well, that’s the point of HoloLens apps, right? Now what would you do? The answer is DirectX. As far as my research goes, there is no other way currently.

Write an app using DirectX? That must be hard, you say. In fact, it is not as hard as you think. If your application is mainly application logics, with light 3D visuals, like AutoCAD, it is not that hard. It all depends on how complex your 3D models are. I had no previous DirectX experience, by reading and researching for a couple of weeks, I can write simple 3D renderings now. I will present you those DirectX terms and basics to get you started.

Now it comes the real question: Do I have write my app in C++ to use DirectX? Microsoft says yes. There is also a C# wrapper for DirectX called SharpDX, but I found it doesn’t make things much easier. Also, you put your future to an uncertainty by using a open source package.

During the past week or two, I have worked out a way to separate DirectX and your app code: you put your DirectX code in a Windows Runtime Component project, in C++. Your main UWP app code in a another C# project. That way, you can have the freedom to write your big chunk of code in C#, but only a small portion of rendering code in C++. So far, I found it’s best solution for a HoloLens app structure. In the next post I will show you how that works. Also give you working code for download.

Before ending this post, I want to explain why I am doing that. For two reasons: I like to write C# code more than C++. Indeed, I have far more experience in C++ than in C#. I also have good understanding of COM programming, as the server and consumer, but I don’t like writing a UWP app in C++. It just doesn’t seem natural. I believe many would agree. The second reason is most of my examples are in C#. If you have written Windows or Windows Phone apps before, there is a good chance you were using C#. There is zero chance you did it with C++.



HoloLens Programming in C# and DirectX – Intermission



While writing this programming HoloLens series, an extremely relevant, extremely informative, and extremely on topic video popup. I embedded video here, I think it is very very helpful for developer.

Main points from the video:

1. Battery life: 2hrs heavy renders, 5.5h light use.
2. FOV: 15″ monitor half arm length from eyes. Why? Cost and battery life.
3. A number of sensors (I think GPS is very likely).
4. Transparency is adjustable.
5. For complex visual, need to utilize a server to do the rendering, then push the rendering result to HoloLens.
6. Server can be used for multiple wearers to share the same scene.
7. Connection: WIFI, Bluetooth.
8. Unity is the main program engine.
9. It’s a like a laptop in term of CPU power. (Think of Surface 3.)

I will continue this series later.



HoloLens Programming in C# and DirectX, without Unity



As a developer myself, I am exploring how to get started to develop HoloLens applications for the up coming device. The information has been limited from a developer’s perspective. Currently, all sources pointed to Unity. However, that’s doesn’t answer all the questions. Actually there are far more questions unanswered comparing to that it answers.

I have been researching for the past a couple months. Along the way writing this blog, I have gained a comfortable amount understanding about HoloLens from both a user’s perspective and a developer’s perspective. Thought I would share my research results now. This journey consists of a few posts: I will first give a big picture of HoloLens programming: options and realities, then there will be two or more tutorial like postd about how to develop 3D application with working examples and code to download. Keep in mind, I don’t have a device with me. The code has some assumptions. But based on my understanding, if you trust me, my assumptions are usually close to the reality.

I will answer the questions like: Why use Unity; Why Unity is not the answer for everything; What to do if Unity can’t be used. I will show you the difference between an app and a game. I will show you how to write a DirectX application in C# without using a wrapper like SharpDX.

This is just a setup post, the rest is coming up in the next a few days.



Visual Studio 2015 to Release on July 20th


Through Somasegar’s blog, Microsoft have announced the final release of Visual Studio 2015, Team Foundation Server 2015 and .NET 4.6 will be available for download on July 20th. His blog title is: “Save the Date: Visual Studio 2015 RTM on July 20th”. The RTM part is wrong, so ignore that.

As I said, Visual Studio and Windows releases are usually paired. Windows 10 will release on July 29.  So, that’s about one week before Windows 10.

Also on July 20 at 8:30 Am PDT (11:30 Am EDT), there will be  Visual Studio 2015 Final Release Event, live on the web.

To celebrate the release, we invite you to join us online on July 20th to learn about the new features and technologies. You will be able to engage in live, interactive Q&A sessions with the engineering team, as well as deep-dive into technical details covered in over 60 on-demand video sessions.




Develop for Windows 10: (4) Fix Mobile Emulators




In another post: Develop for Windows 10: (3) Setup Tools, I have talked about how to setup development environment in order to start development for Windows 10. It turns out, there was a problem.

Everything goes fine, but after creating a project in VS 2105. Run it. You found the run target doesn’t have Emulator like the picture below.



Actually, at the end of VS 2015 installation, there was a warning saying mobile emulators install failed. Why?

The problem was these emulators are running under Hyper-V, which is a virtual machine itself. So, in this case, we are trying to run Hyper-V inside of VirtualBox. So far, there is no way it can work. Fortunately, VMware Player works.

If you are installing Windows 10 TP on a physical machine, like multiple boot. You can skip the following steps, but in any case, make sure you system (your physical machine) meets requirement for Hyper-V. Here is the link.

So follow the steps below. (This is an ugly post, bear with me, and as always, forgive my typos. I will try to fix them later.)

1. Download and install VMWare Player from https://my.vmware.com/web/vmware/downloads,  scroll down to the bottom of the page, locate WmWare Player, click Download Product. Then download WmWare Player for Windows 64-bit.

2. Start WmWare Player.

Create a New Virtual Machine
Choose “I will install the operating system later”, click Next.
Choose Microsoft Windows and select Hyper-V (unsupported) not Windows 10 x64 (don’t ask me why), click Next.
Take a note of the Location (where the VM files a created, I call it {VM Folder}).
Click Next, and Next again.
Click Finish.

Open {VM Folder}\{VM Name}.vmx with Notepad.

Add following line to the end of file:

hypervisor.cpuid.v0 = “FALSE”

Save/close the file.

3. Now go back to VMWare Player, you should see your newly created VM.
Right click it -> Settings.

Highlight Processors, then on the right, Check Virtualize Intel VT-x/EPT or AMD-V/RVI
Highlight CD/DVD (SATA), then on the right, check Use ISO image file, click Browse to select your Windows 10 TP ISO file
Look at bottom of the dialog, click Add button, then select Network Adaptor(use defaults).

Click OK. You are back to the VMWare Player home screen.
Highlight your VM, click the green Power On button.

Now, Windows 10 TP will be installed on your machine. Make sure it is new installation not upgrade.

4. After Windows 10 TP is installed. You are probably getting build 10070. That’s too low, you need to upgrade. Go to Settings -> update and security -> Windows Update -> Advanced Options -> Scroll to the bottom -> Change from Slow to Fast.

Close Settings, then go back to Cortana (you know what I mean), and type Check for update and click it. Make sure get any updates that is higher than 10070. It should be 10130 as of today.

Change update from Fast back to Slow, up to you.

5. Unlock your VM for development. Settings -> update and security -> For Developers. Check Developer Mode.
(Why unlock? Before, any PC or Phone used to running an app outside of Windows Store (called side-load) need to be unlocked. There was a procedure to unlock your machine. Now, in Windows 10, you just turn on Developer Mode, it is unlocked. You can side load any apps.)

Now Install Viusal Studio 2015 RC, make sure choose “Custom”, and check Universal Windows App Development Tools and its suboptions.  (Please check the links Develop for Windows 10: (3) Setup Tools)


Develop for Windows 10: (3) Setup Tools

Please read Develop for Windows 10: (4) Fix Mobile Emulators before continue.

As of today (June 2nd), Windows 10 is still in Tech Preview (called Insider Preview now), Visual Studio 2015 is still in RC (Release Candidate). Windows 10 will release on July 29th, Visual Studio 2015 can’t be far away, but at the moment you have to use the TP and RC.  Windows 10 SDK can change a little at the time Windows 10 is released, but it’s safe to say, you can start write some code now. Changes will be minimal if there is any.

You need to install 2 things: Windows 10 Tech Preview, Visual Studio 2015 RC. You could install Visual Studio 2015 on a Windows 7, 8, 8.1 machine and develop for Windows 10, but some functions are not available (I don’t know what). So it is the best to install Windows 10 TP on a VM then have Visual Studio 2015 RC installed on it.


Install Windows 10 Technical Preview on VirtualBox

So your machine is running either Windows 7, or 8.1, if you are running anything other than these two, then you are reading the wrong article.

Download and install VirtualBox from here.

Download Windows 10 Tech Preview (now called Insider Preview) from here. You will need login with your insider account (if you haven’t signed up, please go http://insider.windows.com to do so). Now click link download the ISO file .

PCWorld has a nice tutorial on how to install Windows 10 TP on VirtualBox.


Install Visual Studio 2015 RC on Windows 10 Preview

Got to VisualStudio.com, right on top of the page, you can download Visual Studio 20015 RC Community Edition or Enterprise Edition, doesn’t matter.

When Install VS 2015 RC, make sure choose custom install, then check Universal Windows App Development Tools and its subitems.



Note, current VS 2015 RC has Windows 10 SDK included.


If things goes fine, you have your environment ready to development App for Windows 10.




Develop for Windows 10 – (2) What to Know about UWP



In this post, I am trying to summarized what we have learned about UWP during Build 2015. I will only list the items, leave out details. In the future post I will try to get into some details if I can. After reading it, you will probably say, ah, that’s not much. I think that impression is correct. Even though there has been many sessions in the Build Conference, the changes are profound, but for developers, there isn’t a lot to learn. That’s a great job from Microsoft.



The most important thing in UWP is concept of adaptive programming. Keep this in mind: your application will potentially run on many different type of devices (from PC to Xbox, HoloLens), different size of screens, and different versions of UWP. Even though you have the option to write separate code for each case, but you mostly wouldn’t.

In order to deal with all situations, you need: 1) Runtime code detection to deal with different device types (families) since different device type may implement different set of APIs. 2) Set MinVersion, MaxTestedVersion and get latest SDK to cover most UWP versions, try to support cutting edge features while still keep backward compatibility. 3) Use controls like SplitView, RelativePanel and Pivot to adapt to screen sizes. Also can use VisualState in XAML or in the code behind to further adapt to screen changes.


Extension SDKs

Extension SDKs bring in APIs that are not commonly implemented in UWP. There are desktop Extension SDKs, Mobile Extension SDKs, etc. All you have to do is reference them in your Visual Studio projects. Call the APIs after runtime API detection.


API Contracts

API Contracts is the way UWP groups functionalities. By putting a collection of APIs together, you don’t have to detect each one of them separately, because they are either implemented in full or none. Each API Contract can relate to certain type of devices.


New in XMAL

SplitView, RelativePanel and Pivot are mentioned above. Many know that Pivot control is the most used in Windows Phone, now it is implemented in UWP, only it becomes tabs in large screen automatically. Others are: ContentDialog (popup dialog), AutoSuggestBox, Map Control, PerspectiveTransform3D (transform control in 3D space: rotations and parallax), Windowing (can customize background, titlebar, etc.), Ink Canvas, Drag and Drop, WebView.

AppBar is not new, but if used properly, it can replace SplitView, make the app more visually compelling. I will look into this later.


Application Life Cycle

As a developer, we need to be aware that application states: not running -> running suspended -> not running. What trigger them. What to do before application is suspended.

Related topic is background task, how to start one and how to manage it.


I think that’s almost all (there are other things: notification, live tiles, advertising, Cortana, but they are not something you will certainly use). As you can see, every subtitles above except for the last one are actually part of “Adaptive”. So, I’d like to simplify it a little by saying “UWP means Adaptive”.




HoloLens Partners Share Dev Experience (Video)




At BUILD 2015, beside Holographic Academy, the only HoloLens related session is “Case Studies of HoloLens App Development”. It’s some of HoloLens partners from NASA Jet Propulsion Laboratory, architecture company Trimble, Case Western Reserve University and HoloLens’ own user experience team. The video below is the recording or the panel discussion. It’s more of designer’s point of view, and general user experience. C# and Unity was mentioned, but don’t expect any coding.

I put down some notes below the video in case you don’t have time to watch the video.

So far, Holographic Academy is a BUILD only setup, outside of it, developers still don’t have a way to access the device. Experience the development process. The development process is much like development for Windows Phone. MicroUSB to USB connect the device (HoloLens) to PC. You run Visual Studio and Unity on the PC, deploy the binary directly to device. The emulator is never mentioned, not sure if there is one.

The mouse cursor moves from computer screen to the hologram is magical, I will research on that later.

NASA still plan to use HoloLens in the summer. He didn’t say July. Last time Microsoft said July. Speaking of NASA, I just can’t imagine if there is a small FOV, like people said, to use that for the real Mars Explorer mission. I think there is something else. Please check my last post here.




Register for: A Developer’s Guide to Windows 10




This is important for Windows 10 developers. We have heard a lot during BUILD, but this one is a systematic, in depth walkthrough of Windows 10 app development. It’s Jerry and Andy again. Make sure bookmark this link.



Jerry Nixon: “Why you must build a HoloLens app”




Microsoft’s Developer Evangelist Jerry Nixon wrote a blog post: Why you must build a HoloLens app, on March 27th. I don’t know how, but I missed it. Today, I am reading his blog together with you. I will also try to read between his lines, hopefully we can get something we didn’t know before.

I haven’t watched Channel 9 videos often recently, so, I am not really familiar with Jerry. Only know him after watch his Developer’s Guide to Windows 10 Preview (with Andy Wigley). Andy has been a regular on Channel 9. Anyway, important thing is Jerry is from Microsoft, and he know pretty much everything regarding Microsoft’s plans in UAP and HoloLens development. It all depends on how much he is allowed to say. We know he can’t say too much before April 29th, but as long as he is talking, we can heard something from his tune, or guess some lines that are not printed.



Regarding HoloLens programming, He said,

On top of all that black magic is HoloLens, introducing a new set of holographic APIs for app developers. Though it leverages Windows Core and though it leverages UAP, the device-specific APIs that enable the holographic experience are going to be different to what app developers do today. This means developers can use what they know, but will need to learn this new paradigm.

This means when we develop for HoloLens, it still follows UAP scheme. You create an UAP app (I don’t know if there is other choices in for Windows 10). You probably also add “HoloLens Extension”, if such thing exists. Basically there are things we already know: like coding for UAP, and things we don’t know: like HoloLens related APIs. HoloLens APIs is very much already in Windows 10 preview, but Windows 10 SDK doesn’t yet include HoloLens. I am sure we will see that during BUILD.

HoloLens is going to be a commodity. That means it is going to be cheap (which is relative, I know). When you include HoloLens in a solution, you aren’t including an investment in some strange, proprietary whatever. You are just including HoloLens, with a standardized version of Windows, a standard application model, with standard languages and APIs, and everything you can expect a development team to already know or easily learn.

Well, I don’t want to read too much. But when he put HoloLens and commodity in same sentence, I can’t stop speculating. Did he just said HoloLens is going to cheap or develop for HoloLens is going to cheap, or both? He did say: HoloLens is going to be a commodity. Take a note, please.

Don’t let HoloLens become a specialty skill. You are going to find the SDK just like every other Microsoft property. It will be standard and asynchronous, full of controls, methods, and classes.

Ok, it’s going to be asynchronous, like any WinRT APIs, but what those controls look like is interesting thing to find out. Obviously they are different from regular controls we do in XAML for PC and phone.


UAP, HoloLens, Recommended Readings – Developer’s Collection


Developers: Get Yourself Ready for HoloLens


There is no question that HoloLens presents great opportunities for developers. Getting on the platform early is even a bigger deal. As we’re all aware once a platform get crowed, it’s very difficult for an app to get attention in the market place. The BUILD conference is just a little more than a month away, we will hear more about Windows Holographic and HoloLens. Windows 10 SDK will be released at the time, which will include details about Windows Holographic API and how to write code for HoloLens. Before getting to that, we need get ourselves ready. In this post, I am trying to help with that.

What Should I Do to Develop a Holographic Application?

Nothing. Remember this,

 All Windows universal apps work as holograms.

This is direct quote from Microsoft’s hololens.com. So, you can take my word for it. If you are writing a Windows 10 universal app, you are writing a holographic app. If there is any chance you get confused by this, let me explain: Holograms and 3D are totally different things. A Hologram can be 2D or 3D. A Hologram is simply a digital objects added to the user’s real world. They can be placed, pinned anywhere in the user’s field of view. Of course, if you want to build 3D holograms, there is extra work. In short, if you want to write an app(2D or 3D) that will work on HoloLens, you write a Windows 10 universal app. Windows universal app doesn’t start from Windows 10. It is already there for Windows 8.1 and Windows Phone 8.1. So, you can get information from Windows Dev Center.

Two Important Questions About HoloLens

What Programming Language Should I Choose to Develop a Holographic Application?

Basically that’s the question you would ask about developing a Windows universal app. Here is a post from Microsoft about the topic. But here I will give you an digested, more useful answer.

Here are the choices:

  • HTML, CSS and JavaScript.
  • XAML and C#
  • XAML, DirectX and C++
  • DirectX and C++

First, I want to vote NO to JavaScript, so did most developers. JavaScript is just a big mess. I am not a big fun of going 20 years back and crafting every UI by hand. HTML and CSS are just not programmer friendly. Not to mention there are limitations comparing to C++ and C#.  #2 and #3 are basically your choices. XAML has been the official UI construction language for Windows and Windows Phone. It is proven to be powerful and easy to use. So, it comes down to this: C# vs. C++/DirectX. The former is easier, the later gives more control over WinRT and DirectX. If you have to deal with a great deal of graphics especially 3D, C++/DirectX would be the choice. Otherwise, C# will serve you well, and save you a lot of time.

What If I want to Develop 3D Holographic Applications?

Many people say the whole point of HoloLens is 3D. Well, yes and no. In any case, if you want to learn how to write 3D holographic code, you have to wait until BUILD. I have managed to get some bits from Windows 10 preview, that says nothing about 3D programming, but that’s how much I know for now.

HoloLens Misconception – 3D

What Should I do Now?

Before Windows Holographic SDK is ready, If either of these: XAML, C#, C++, DirectX doesn’t make prefect sense to you, head to Windows Dev Center, find a tutorial and some sample projects. Also, browse topics about developing Windows universal apps.

HoloLens: Some Early Bits for Developers

There are hints there might be a emulator for HoloLens, just like the emulator for Windows Phone, but I am not sure. Also, Wired have said Microsoft is planning to bring HoloLens to devs hands in this spring. Hope that turns out true.


Some Business Ideas with HoloLens – (8) Holo-Movie
Some Business Ideas with HoloLens – (7) Holo-Escort
Some Business Ideas with HoloLens – (6) Holo-Online Store