GraphicsWithNUX

Dev Week -- nux - visual rendering in UIs made easy -- jaytaoko -- Thu, Jul 14th, 2011

   1 [19:01] <jaytaoko> Hello
   2 [19:04] <jcastro> jaytaoko: go ahead and begin!
   3 [19:05] <jaytaoko> My name is Jay Taoko and I am a software developer at Canonical, in the Desktop Experience Team.
   4 [19:05] <jaytaoko> I am the creator of Nux, the toolkit we use for unity's rendering!
   5 [19:06] <jaytaoko> A bit about myself and how I ended at Canonical working on Unity:
   6 [19:06] <jaytaoko> At started working at Matrox, in Montreal, Canada, where I learned a great deal about GPUs and computer graphics.
   7 [19:07] <jaytaoko> After that, I worked at other companies doing graphics, including EA and Ubisoft.
   8 [19:07] <jaytaoko> After leaving Ubisoft, I started my own gig.
   9 [19:07] <jaytaoko> After a few years, out of the blue, someone mentioned that Canonical is looking for an OpenGL developer.
  10 [19:08] <jaytaoko> Having used Linux in the past, I knew about Canonical, but it had been a while since I installed Linux on any of my machines.
  11 [19:09] <jaytaoko> I was skeptic at first. Until I understood that Canonical was very serious about graphics.
  12 [19:09] <jaytaoko> That is when I decided to sign in!
  13 [19:09] <jaytaoko> Coming from the Windows operating system, I had to learn things on Ubuntu.
  14 [19:10] <jaytaoko> I have to say that this hasn't been a big problem.
  15 [19:10] <jaytaoko> I have been very welcomed at Canonical.
  16 [19:10] <jaytaoko> I have annoyed my colleagues with end-of-lines issues in the code, but I  have found ways to fix this and now it has become a practical joke...
  17 [19:11] <jaytaoko> Now, onto Unity and Nux!
  18 [19:11] <jaytaoko> Nux is the toolkit we for Unity's rendering.
  19 [19:11] <jaytaoko> we use*
  20 [19:12] <jaytaoko> I started Nux many years ago and I am very happy to see it used for such a great project.
  21 [19:12] <jaytaoko> Nux is written in C++ and it uses OpenGL for its rendering
  22 [19:13] <jaytaoko> It has a good widget set for writing graphics applications: http://i.imgur.com/ax1Q5.png
  23 [19:14] <jaytaoko> Although Nux has been adapted to support Unity, its original intent (writing real-time graphics application user interface) will remain.
  24 [19:15] <jaytaoko> There are very talented people working on it. They are adding  support for C++0x and other features to it. This is really great!
  25 [19:15] <jaytaoko> Nux provides the rendering of Unity. To that end, Nux has to be facilitate direct access to OpenGL.
  26 [19:16] <ClassBot> kamil_p asked: Which projects besides Unity uses Nux?
  27 [19:16] <jaytaoko> Only Unity uses it at the moment
  28 [19:16] <jaytaoko> Nux has a rendering API that is used for common rendering operation (rendering of widgets).
  29 [19:17] <jaytaoko> It also tries to hide the OpenGL API by providing convenience functions and objects.
  30 [19:18] <jaytaoko> However, we are free to use raw OpenGL is we need to.
  31 [19:18] <jaytaoko> however, one has to know how cooperation between nux and raw opengl works
  32 [19:19] <jaytaoko> But I think that encapsulating OpenGL into a wrapper is the right thing to do for most cases.
  33 [19:20] <jaytaoko> Unity is our flagship product. We want it to be great! We know what we want  Unity to be for this cycle. But we don't know yet what it will be in 2  years.
  34 [19:20] <jaytaoko> We have a design team working on new ideas all the time.
  35 [19:20] <jaytaoko> the deal between Unity and Nux is like this:
  36 [19:21] <jaytaoko> Wherever we take Unity, the Nux has to offer flexibility and convenience to achieve Unity's goal.
  37 [19:21] <jaytaoko> With the DX team working on both Unity and Nux, we have more  opportunities to improve, optimize and react to any changes required.
  38 [19:22] <jaytaoko> It hasn't been easy though. They was some rough edges at first. We had  to modify Nux so that it can be embedded inside a Compiz plugin.
  39 [19:22] <jaytaoko> Also, we have had issues with graphics drivers.
  40 [19:23] <jaytaoko> This is a burning issue.
  41 [19:24] <jaytaoko> We try to get Unity working on as many systems as possible. We have  Unity running well on  Atom N270, or systems with older GPUs: ATI  X1950, NVidia 6600...
  42 [19:24] <jaytaoko> And in Natty, we required less OpenGL features and GPU horse power than people think.
  43 [19:24] <jaytaoko> Only graphics features that have been around for at least 5 years were required.
  44 [19:25] <jaytaoko> Unity is in this unique position that it is advancing desktop rendering on all systems that support it.
  45 [19:26] <jaytaoko> It is bound to reveal more issues with graphics than any other application on the desktop before.
  46 [19:27] <jaytaoko> I have had some question regarding Unity support on geforce 2 cards!
  47 [19:27] <jaytaoko> yes, that is old!
  48 [19:27] <jaytaoko> but this is the challenge of Unity!
  49 [19:28] <jaytaoko> we can't get it to run on old GPU and I hope people understand. But we try as much as possible.
  50 [19:29] <jaytaoko> And there is Unity2D that Canonical is investing in!
  51 [19:29] <jaytaoko> If a system cannot run Unity with full opengl, there is always Unity2D.
  52 [19:30] <jaytaoko> The thing about the graphics issues is like this:
  53 [19:31] <jaytaoko> The more issues we find, the closer we get to  solutions and the better graphics rendering improves for everybody on  Ubuntu and across all Linux systems.
  54 [19:31] <jaytaoko> We are starting something new, but we are going to make things better.
  55 [19:32] <jaytaoko> This is what we started with almost a year ago:
  56 [19:32] <jaytaoko> http://i.imgur.com/zC9v8.jpg
  57 [19:33] <jaytaoko> yes, that is Unity + Compiz + Nux!
  58 [19:33] <jaytaoko> Our Alpha 0 prototype!
  59 [19:34] <jaytaoko> Jason Smith and Neil Patel and I got locked in a room for a week an prototyped the next iteration of Unity with Compiz and Nux...
  60 [19:34] <ClassBot> jsjgruber asked: Unity's indicators disappeared for me under Oneiric sometime in June. Known problem or should I file a bug against nux or some other project?
  61 [19:34] <jaytaoko> As you can see, we have come a long way...
  62 [19:36] <jaytaoko>  jsjgruber: probably a known issue
  63 [19:36] <jaytaoko> The control we have over Nux has allowed us to add the necessary fixes to get Unity working on as many system as possible.
  64 [19:36] <jcastro> Got a question: does nux only work with linux? ()
  65 [19:36] <jcastro> (from the channel, the bot is busted or something)
  66 [19:36] <jaytaoko> Sometimes even at the last minutes before Ubuntu's release (thanks to our  superb Desktop team of packagers: seb128, didrocks and all).
  67 [19:38] <jaytaoko> nux also works on Windows. I am constantly keeping the windows and Linux version in sync. However, I haven't released the windows project files.
  68 [19:38] <jaytaoko> it is quite easy to maintain both version. 95% of the code is the same.
  69 [19:39] <jaytaoko> We have had great support from GPU vendors to help us fix issues with Unity on some systems!
  70 [19:39] <jaytaoko> We also report bugs to open source drivers and our hope is that this will benefit everyone.
  71 [19:40] <jaytaoko> Now, what is coming next in Nux?
  72 [19:40] <jaytaoko> We are improving Nux for unity.
  73 [19:41] <jaytaoko> In Natty, we were using mostly ARB shader programs on all systems except NVidia GPUs.
  74 [19:42] <jaytaoko> We couldn't do it for AMD GPUs in time with the fglrx driver.
  75 [19:43] <jaytaoko> However we worked a great deal with AMD to resolve another issue and that is why we didn't have enough time in the end to test the GLSL shader code path
  76 [19:44] <jaytaoko> For Oneiric, we will enable the GLSL shader code path on a much system as possible.
  77 [19:45] <jaytaoko> What we are going to get from it is the ability to do more in terms of visual quality
  78 [19:45] <jcastro> QUESTION:What is the recommended way to start the project?
  79 [19:46] <jaytaoko> The best way is to approach Nux from Unity's side
  80 [19:46] <jaytaoko> The launcher, the Dash are all rendered with Nux
  81 [19:47] <jaytaoko> Download Unity's source code and take a look at the Launcher code. There you will see some shaders, rendering code...
  82 [19:47] <jaytaoko> That will show you how we use Nux in Unity.
  83 [19:48] <jaytaoko> The tests in Unity are a good sample of Nux programs...
  84 [19:49] <jaytaoko> Give them a try.
  85 [19:49] <jaytaoko> Then, there is Nux itself. It as a few test program of its own.
  86 [19:49] <jcastro> QUESTION: Can I embed GTK+/Qt widgets?
  87 [19:50] <jaytaoko> Maybe one way to start is to try and write a small Nux program. Nothing fancy, just get started.
  88 [19:51] <jaytaoko> That will also make you better at debugging in Unity if you choose to.
  89 [19:51] <jaytaoko> Questions?
  90 [19:52] <jcastro> QUESTION: Can I embed GTK+/Qt widgets?
  91 [19:53] <jaytaoko> I think so, but I am not sure.
  92 [19:53] <jaytaoko> Nux uses the glib main loop.
  93 [19:53] <jaytaoko> So it should be compatible with Gtk+/Qt somehow, but I have never tried it
  94 [19:54] <jaytaoko> However, some of us have been thinking about embedding Nux into Gtk+
  95 [19:54] <jaytaoko> Something that Nux is missing right now is documentation.
  96 [19:56] <jaytaoko> We are busy working on Unity but it would help people who want to learn if we have better documentation and tutorial on how to program in Nux.
  97 [19:56] <jaytaoko> Questions?
  98 

MeetingLogs/devweek1107/GraphicsWithNUX (last edited 2011-07-15 08:13:03 by dholbach)