Jump to content

  • Log In with Google      Sign In   
  • Create Account

Promit

Member Since 29 Jul 2001
Online Last Active Today, 08:53 PM

#5277464 make c++ more like glsl

Posted by Promit on 22 February 2016 - 10:42 AM

Naively, something like this:

vec3 xy(){
    vec3 v;
    v.x=x;
    v.y=y;
    v.z=0; // or whatever you want for a non-asked-for swizzle
    return v;
}

It'd be kind of tedious, but you could write out whatever swizzles you want as functions like that - there are only so many permutations for a 3D vector, and with a decent constructor defined, they would be one-liners.

 

In C#, this would probably be something I'd do with some read-only properties, which is effectively the same thing, just lets you do it without writing parentheses.

Honestly the function variety makes things eight thousand percent easier. That's what I did in my code, rather than play the ridiculous games required to get native-looking swizzles.




#5275682 Vulkan is Next-Gen OpenGL

Posted by Promit on 14 February 2016 - 06:18 PM

It turns out that when you get an API that matches the hardware closely, the exact behavior of the hardware matters a lot. Imagine that!

 

These types of issues, and sophisticated workarounds for them, are part of the driver voodoo that we've known for decades. Being able to tell the GPU exactly what we want and how has this key drawback - there's no promise we're telling it to do the right thing in the best way. There's no longer as much space for the driver to lie to us and fix it in the background*.

 

*Yet.




#5275576 Do game developers still have any reason to support Direct3D 10 cards?

Posted by Promit on 13 February 2016 - 03:05 PM

It's all about understanding your target market and development constraints. Sometimes it's simply that you would have to sacrifice too much performance, and the actual feature levels are secondary concerns. The wider you cast your hardware support net, the more difficult it gets to ensure that things work well across the board. For many devs, if they're supporting "old" hardware they are better served by going all the way back to D3D 9.

 

Steam HW survey currently shows DX10 GPUs at 15%, and presumably much of that population is not buying the latest greatest games.




#5275475 Vulkan is Next-Gen OpenGL

Posted by Promit on 12 February 2016 - 05:57 PM

 

 

Vulkan requires Kepler and higher. We should have such lists once it comes out, and http://gpuinfo.org/ will get a nice vulkan section about capabilities.

I want to have a supported card when Vulkan is released. 

 

But I am more concerned for the game consumer than I am for dev's.  Not supporting Fermi is going to cause at least a small uproar.  Most have been lead to believe that any card that supports modern OpenGL 4.x will support Vulkan.

 

I don't think this is good...

 

According to an NVIDIA public presentation, Fermi will get Vulkan support. I don't know where he got that information.

 

Well pixeljetstream works there, but I would like clarification on the situation.




#5275313 Windows 10 - OpenGL Version

Posted by Promit on 11 February 2016 - 01:20 PM


I can see and understand their reasoning for leaving it to the old (1995 or 1996?) implementation.  

Hilariously enough, it is not the same implementation. It transitioned from software to a wrapper around D3D - 9 in the XP timeframe and 10 from Vista I think.




#5275288 Windows 10 - OpenGL Version

Posted by Promit on 11 February 2016 - 10:33 AM

Still looks like 1.1 to me in the DLL. As usual, you're a million times better off using GLEW.




#5275068 EASTL is now officially open source

Posted by Promit on 09 February 2016 - 08:22 PM

Although incomplete sections of it were previously available through EA's GPL source code releases, the EA STL is now officially open sourced, under a modified BSD license. Like everything nowadays, it lives on GitHub:

https://github.com/electronicarts/EASTL

If you're new to this or have generally forgotten what's going on, here is an overview of why this exists:

http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2007/n2271.html




#5273216 Vulkan is Next-Gen OpenGL

Posted by Promit on 29 January 2016 - 11:02 AM

Whenever NVIDIA talks about new OpenGL features and ways to get the most out of an API, I have one thought.

Okay, cool. Implement that, go run it on AMD and Intel systems, and tell me what happens.

As Hodgman alluded to it, let's not forget about what Rich Geldreich wrote. The NV guys tend to behave as if their hardware is the only GL platform that exists, and you would be nuts for writing against any other contingency. 

 

I'm excited for Vulkan. Despite what the insiders say though, as far as I'm concerned Vulkan is a hypothetical paper spec, not a real functioning system. Not yet. There is an open question of when the various vendors will ship, how reliable the drivers will be, and what will happen when rubber meets road for real world codebases. OpenGL always looked vastly better in PDF form than it actually was in running code, and for far more numerous reasons than extensions. Let's hope Vulkan does not meet the same fate.




#5272785 Loading images in DirectX 11 to use as textures and sprites

Posted by Promit on 26 January 2016 - 08:07 PM

The link to ChuckW's blog post above is terribly out of date, I'm afraid. What you actually want is this:

http://blogs.msdn.com/b/chuckw/archive/2015/08/05/where-is-the-directx-sdk-2015-edition.aspx

Which leads to DirectXTex:

https://github.com/Microsoft/DirectXTex

Which is a wonderfully simple library to use. Copy WICTextureLoader and DDSTextureLoader into your codebase and enjoy single function call texture loading.

 

P.S. Call CoInitialize near the beginning of your main function, or WIC won't work.




#5272077 Is it possible to make a multi-threaded renderer?

Posted by Promit on 20 January 2016 - 06:49 PM

@AThompson I think he is talking about the Direct3D9 specific multithreaded device.

In that case, no for the love of god do not do this. Multithreaded rendering should not even be attempted unless you are using a D3D 11 device at the very least. It's a difficult recommendation even then. D3D 12 is the only solid choice for multithreaded rendering.

 

D3D9's multi-threaded mode is probably best left to situations where you wish to use the device on a single non-UI thread.




#5271469 How Important is an Honours Degree in Games/Audio Industries?

Posted by Promit on 16 January 2016 - 05:05 PM


I've decided to attempt to suspend my studies leaving me the option to return in a year.  This way I can spend a year on my own work and see how well I do with it, and by next year I'll know whether to complete the honours year.  I do hope at the very least I've made it clear that I'm not a quitter just because I'm choosing not to finish.  

I did something similar, worked for a pro studio for a year before finishing up my undergraduate degree. Did me a world of good both in terms of mental health and in overall life outlook. I do recommend getting out into the real world and getting a job though, not spending a year exclusively on your own work. That is not a productive thing to do. Your best experience and learning will come from interaction as part of a team focused on creating a real world product.




#5271378 How Important is an Honours Degree in Games/Audio Industries?

Posted by Promit on 16 January 2016 - 12:36 AM



It's hard to know what to say to your analogy of thinking like a child, teenager etc.  I'm not sure the way I think falls into any of those categories.  For one thing, I think of time as precious and the coming 4 months aren't so insignificant to me.  I want to do something meaningful in the time it wouldve taken to finish the degree.  I think I'm about to do more work than I've ever done and give something my all, and I don't want that something to be for purely superficial reasons e.g so I don't look like a quitter.  If an employer doesn't look further beneath the surface to see a candidates true abilities, that candidate would probably only have existed as a number in a corporate environment.  I'm a bit too free-spirited for that sort of thing anyway, so I suppose I'd be better off.  It seems there will always be a trade off between my attitude to life and being successful in life, but you've got to do what makes you happy, right?  Call it child-like or even idealistic if you will though...

It's a fun and optimistic way to look at the experience we call life, and I don't wish to denigrate your free-spirited attitude. But as an employer, I would politely show you the door. Game development is NOT the place for this. Industry projects are long term, challenging, and usually quite tedious work. Hard working employees are more valuable than those with "true abilities" - and frankly there's a healthy supply of people with both.




#5271377 Do I need a Laptop or a PC?

Posted by Promit on 16 January 2016 - 12:19 AM

Desktops are indisputably more powerful than laptops at any given price point. Miniaturization costs money and power restrictions cost performance. On the flip side there are many capable and reasonably priced laptops out there with plenty of power, more than enough to get work done. You should work on identifying your actual needs and software requirements first, as well as your needs for laptop size, battery life, performance, etc. For the time being, it doesn't sound like you need anything outside the realm of readily available thousand dollar laptops, like an Inspiron 15" 7000 series, Lenovo Y50, etc.

 

Don't get hung up on what professionals do. When you're paid a couple hundred dollars a day, it's worthwhile for a company to spend a day or two worth of your salary to maximize your productivity. It's not unusual for pro developers to have desktop PCs that cost $3000+. It's rare to provide high spec laptops simply because most of the heavy lifting is generally done in the office.

 

Are you a student? I would not recommend not having a laptop if so.




#5270895 Why does normal mapping stop working at flat angles?

Posted by Promit on 13 January 2016 - 11:39 AM

The actual exact reason is the lack of self-occlusion on the surface. For a true bumpy surface, as you approach shallow angles things should start disappearing behind the bumps. The moment this fails to happen, the illusion breaks down. Parallax (occlusion) mapping tackles this problem.




#5270581 RISC-V architecture and it's feasibility for games?

Posted by Promit on 11 January 2016 - 02:47 PM

Game developers do not, by and large, care about the ISA. Most ISAs are boring minutae when you get into the real world of shipping software. We care about CPU architecture, which is far more implementation centric and can vary widely within the same ISA.

 

My short answer to RISC-V is: show me a chip, in working silicon, with all of the architectural and performance details laid out, and then we can talk. My slightly longer answer is, what does this ISA or architecture accomplish that I don't already get out of ARM, with regards to power consumption and performance per watt? The main purpose of RISC-V appears to be that it's a free open spec, which is very useful for research and entirely useless for game development.






PARTNERS