Advertisement Jump to content
  • Advertisement


Senior Moderator
  • Content Count

  • Joined

  • Last visited

  • Days Won


Everything posted by Promit

  1. Oh yeah I forgot about that. I'd blank the shader for that reason alone 🤣
  2. Will setting a NULL pixel shader improve performance even if no color RT is bound? That seems like an easy optimization for a driver to integrate automatically.
  3. As we said on GameDev's Discord (that everyone should join!) what really happened here is that Unity tried to strong arm a company for a license fee, didn't get it, and then lost the ensuing PR war when they tried to force the issue. While the resolution is probably a good thing and makes Unity a more transparent business, it's alarming that things went this way in the first place and that Unity tried to leverage someone that hard. Improbable really came out on top by being savvy with social media and forging a strong alliance with Unreal and Tim Sweeney to back them up on it. I'm not inclined to the charitable interpretation of Unity making a mistake here or Spatial doing something that was actually an offense. I think Unity wanted a cut from a certain class and thought they could get it.
  4. The absolute easiest thing to do is to use an archive library like PhysFS to read files like those, maybe with password protection enabled, although it's limited to some common formats that people will generally know how to work with. You could go in and make a modified version of one of the formats that is similar but different enough to require different parsing, though now you'll need to make a tool to output that too. Another option would be to layer some encryption into the files inside the package, and that can range from simple to complex.
  5. Promit

    Question on which engine should I use

    Unity's 2D stack has gotten quite robust in recent years and I don't think you should be reluctant about using it. If you really want to evaluate options, I believe Godot Engine has both a very capable easy to use 2D system and a scripting language.
  6. Promit

    Weird depth buffer values

    What are you using to actually view the depth buffer? Usually the best way to sanity check is to use the Visual Studio graphics debugger, take a snapshot, and compare what it has to what you have.
  7. The questions raised above are all good and important, but this also feels like a great excuse to point to stb_voxel as an example of how a voxel engine can be set up
  8. $25M is a lot of money for most devs, but Unreal is playing a different game with much higher stakes. The market they live in is worth billions of dollars a year, and if they can peel off 2% of Unity developers for a few tens of millions in good will dollars that'll basically pay off in no time.
  9. Promit

    Career guidance

    I see you're in India, so I am not entirely sure how much of this advice will apply. But typically at least in the US and several other countries, there are programs to get a graduate degree by taking evening and online classes in some combination. So you might have classes Monday and Wednesday 7-9 pm. From there, it's just about discipline and busting your ass doing all the work, because it doesn't come easy. You would likely take one or two courses each semester, which keeps the workload sane with the pressures of a full time job, and probably requires 2-3 years to complete.
  10. Promit

    PhysX 4.0 Announced as Open Source

    NVIDIA has announced a christmas present with the release of PhysX SDK 4.0 later this month, open sourced under the 3-clause BSD license. The big technical change in the physics engine appears to be the temporal Gauss-Seidel solver, enabling faster and more robust handling of contact points and constraints. For full details, please see
  11. Promit

    PhysX 4.0 Announced as Open Source

    NVIDIA has announced a christmas present with the release of PhysX SDK 4.0 later this month, open sourced under the 3-clause BSD license. The big technical change in the physics engine appears to be the temporal Gauss-Seidel solver, enabling faster and more robust handling of contact points and constraints. For full details, please see View full story
  12. We have a lot of code that computes the length of a vector into a separate variable and then divides the vector through to normalize it. Enough that I'm tempted to make an extra helper function just for that usage pattern.
  13. ??? Normalize the vector, or just compute the angle directly via arctangent (atan2).
  14. Promit

    Overengeneering Modularity

    Do you have any game development experience?
  15. Promit

    Overengeneering Modularity

    Alright, let me try to organize some thoughts on this subject. Modularized design is one of these things that everyone tosses around as of course that must be a good idea, but very few people actually succeed at doing. As has been noted, C++ is particularly poor for modular design compared to most later language designs, but that's far from the only issue or even the major one. Whenever code interacts, there are assumptions involved about how both sides behave. It's tempting to say that oh, B strictly depends on module A and so module A can be cheerfully reused, interchanged, etc without having to worry about B. It's also easy to say that things won't ever end up straddling the boundary, or making assumptions about the internal behavior of either piece. This is where we start to head into the land of leaky abstractions, systems that ostensibly live as independent modules and yet expose much more of their implementation than expected or intended. Eventually at the scale of something like a game, we tend to end up with modules that are entirely co-dependent, at least at a behavioral level and sometimes at a full code level. The physics and rendering code ends up with hacks, taps, or magic variables that exist to enable behaviors and structures that simply did not modularize in any meaningful way. I've seen people argue that the entire concept of code reuse (especially in the context of OOP) is overblown and more of a fantasy than reality, though I think that's extreme. That's all well and good at an academic level, but you'd probably like some advice about what to do about it. I'm going to give the same advice I give for many design problems: don't do anything at all. The biggest mistake developers routinely make is designing systems and interfaces for what they imagine they would like to solve instead of what they're actually solving. Focus on the exact things you need to actually produce the exact product you're making, and put just enough design effort in so that everything doesn't go to hell if you need to reshape it later. KISS and YAGNI are undervalued approaches. Take your matchmaking server that doesn't need math code. Suppose the math code goes in anyway. Who cares? What has this cost you? What problem has it created? What problem does removing it solve? Don't get lost trying to solve problems you don't actually have. Create a module when you have need to share blocks of code smoothly across multiple products, and then you'll have the necessary context to design the module properly. There's no sense making a module out of something that only has one use case in the first place.
  16. You're absolutely in a dictatorship. We just happen to be a polite one. Unlike Khawk, I have no belief that political threads are healthy, useful, or positive for this site and I would not blink if we revoked them entirely tomorrow. Given that situation, not only am I not reluctant but I am actively enthusiastic to drastically limit participation in the political stuff. You are one of the people I was talking about. My proposed rules are intended to keep you out of these threads.
  17. Speaking as a member and not a moderator, these are the things I'd like to see: All politics threads must have some kind of plausible connection to games or the game industry. Sorry but most of your guys' opinions are terrible and I've grown tired of reading the latest stupidity. Minimum reputation to even participate in political threads, and I'm not thinking small here. Perhaps a hundred points. Alternately minimum post counts/account ages? Either way, I believe that new accounts should have no right to participate. An understanding that stepping out of line in these threads is grounds for an insta-ban, much more readily than we might normally do so. I don't think we've had much of a problem with this yet, but there are certain domains/sites I would blacklist, and YouTube links should be off limits as well. You all know why. An outright explicit ban on threads that touch on race, gender, sexuality. Nothing good can come of these discussions. As a moderator, I'd very much like the ability to force particular members out of political threads permanently. We've seen an influx of people lately who kinda sorta do some game stuff here and there but mostly have an axe to grind on political ideology and just can't help themselves. A couple are already in this thread.
  18. Promit


    This classified is now closed.
  19. I think this might be helpful -
  20. Any chance I can push you towards C#? It's still fully UWP capable, you can still use DirectX, but it will be dramatically easier to move into from a Java background.
  21. It all depends. GLUT is ancient and irrelevant, but several other foundational libraries are perfectly viable as long as they're open source. The real issue nowadays is that graphics APIs are changing, platforms are coming and going, and professional studios need to be buffered against all of those changes. A math library needs to be flexibly ported to different CPU architectures with different SIMD instruction sets. Windowing libraries need to be expandable to handle platforms that may not even be publicly announced. You can't very well have MS come to you for an Xbox 4 demo and not be able to adapt to the platform. For those reasons, these core libraries can act as very short term gains, but in the long view it's more beneficial to control the underpinnings yourself.
  22. Promit

    Assembly language?

    I have to add some caveats in here. True, nobody builds games in assembly. But there are certainly uses for it. It's still common to write SIMD routines in assembly, especially newer instruction sets where the compiler intrinsic support is either not available or just doesn't work that well. PS3 SPUs were frequently coded in assembly. And debugging often involves going over the assembly code being emitted and run, in order to understand what's going on. Performance optimization also frequently requires analysis of the compiler output to fully achieve the desired results. We're not writing in assembly or even reading it on a regular basis, but you better believe that it comes up plenty in games.
  23. Promit

    Defining AAA

    It's unclear to me which days were the "romantic" ones, but I did want to try and put some numbers on budgets over the years. Luckily, some guy at Kotaku did the legwork already: I should mention that some of these budget numbers are direct budget and don't count things like the effort put into building a publisher-shared engine, and often times the marketing budgets can be quite large. There's never been any doubt that budgets have inflated massively over the course of the game industry's evolution. The definition I was given around 2007 for a AAA title was simply, a game expected to sell more than a million copies. (Successful indie games might sell those kinds of numbers, but that was not usually the expectation.) If the term ever meant anything about the innovation of said games, that went out the door at least 20 years ago.
  24. cracks knuckles Alright, let's talk seriously about what it means to roll your own. For context, I've worked at Microsoft and had access to the Windows source code. I've worked at NVIDIA and had access to the D3D driver source code. I'm software architect of a group which has a completely C++ tech stack which is essentially custom, save a few helper libraries that are part of it. I say this only to provide some context for where I'm coming from - rolling your own is a very familiar world to me. I'm going to ignore Casey/HMH from here on out because I don't care enough about him to say more on that subject. That's great. Do you have time to do both? More on that in a moment. I'm a little concerned that you don't actually know what you are trying to accomplish here. In general, there are two ways to come at building games. You can start with something very high level and learn all about how to structure the high level structures of a game, filling in low level knowledge over time. Or you can start very low level with the individual pieces, eventually figuring out how to connect them into a working whole. Both are perfectly valid approaches, but it's very difficult to accomplish both missions simultaneously. The people we're talking about in this thread have many years of professional experience under their belts, and are usually doing this in their spare time too. You can choose to roll your own tech, as we did, and it can pay dividends long term. But that choice will kick your actual game back by years, especially if you're still learning the fundamentals as you do it. Witness was mentioned above - that game took eight years and an ultimate team of 15 people to create. So it becomes necessary to decide what your priorities are, because we're no longer talking about short term gratification. You've demurred on that choice so far, though I like @MonterMan's comment on integrating outside libraries, particularly open source ones. I don't like the concept that some stick to of not having dependencies, because that's not reality. You always have dependencies, you're just choosing not to acknowledge them. The OS and platform SDK, the graphics API and drivers, the C++ runtime, etc. I just include the dependencies in the source tree whenever possible, rather than doing package manager stuff. At the end of the day, you're going to have to decide that you're writing some part of the system yourself, and some part just already exists there for you and functions in its own mysterious ways. There are many places to draw that line, but you should have a good understanding of why you placed it where you did and what the goals are. No matter what you choose, some things are going to be closer and some things are going to be farther away. It will take a long time to have both the low level and high level under your belt - and I have to mention that very few professional game developers ever do that. Most inhabit just one section of that world, relying on the rest of the team to build a complete product.
  25. I don't know how much more there is to say without digging into the series and cherry picking all the stuff I hate, and I got bored of that long ago. It's simply not representative of anything beyond a fanciful imagined time where people totally built stuff up from nothing. It's like a game-sized programming test rather than focusing on things that are actually productive. I just think it's a mistake to think that this is what a "real game programmer" does.
  • Advertisement

Important Information

By using, you agree to our community Guidelines, Terms of Use, and Privacy Policy. is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!