• Announcements

    • khawk

      Download the Game Design and Indie Game Marketing Freebook   07/19/17

      GameDev.net and CRC Press have teamed up to bring a free ebook of content curated from top titles published by CRC Press. The freebook, Practices of Game Design & Indie Game Marketing, includes chapters from The Art of Game Design: A Book of Lenses, A Practical Guide to Indie Game Marketing, and An Architectural Approach to Level Design. The GameDev.net FreeBook is relevant to game designers, developers, and those interested in learning more about the challenges in game development. We know game development can be a tough discipline and business, so we picked several chapters from CRC Press titles that we thought would be of interest to you, the GameDev.net audience, in your journey to design, develop, and market your next game. The free ebook is available through CRC Press by clicking here. The Curated Books The Art of Game Design: A Book of Lenses, Second Edition, by Jesse Schell Presents 100+ sets of questions, or different lenses, for viewing a game’s design, encompassing diverse fields such as psychology, architecture, music, film, software engineering, theme park design, mathematics, anthropology, and more. Written by one of the world's top game designers, this book describes the deepest and most fundamental principles of game design, demonstrating how tactics used in board, card, and athletic games also work in video games. It provides practical instruction on creating world-class games that will be played again and again. View it here. A Practical Guide to Indie Game Marketing, by Joel Dreskin Marketing is an essential but too frequently overlooked or minimized component of the release plan for indie games. A Practical Guide to Indie Game Marketing provides you with the tools needed to build visibility and sell your indie games. With special focus on those developers with small budgets and limited staff and resources, this book is packed with tangible recommendations and techniques that you can put to use immediately. As a seasoned professional of the indie game arena, author Joel Dreskin gives you insight into practical, real-world experiences of marketing numerous successful games and also provides stories of the failures. View it here. An Architectural Approach to Level Design This is one of the first books to integrate architectural and spatial design theory with the field of level design. The book presents architectural techniques and theories for level designers to use in their own work. It connects architecture and level design in different ways that address the practical elements of how designers construct space and the experiential elements of how and why humans interact with this space. Throughout the text, readers learn skills for spatial layout, evoking emotion through gamespaces, and creating better levels through architectural theory. View it here. Learn more and download the ebook by clicking here. Did you know? GameDev.net and CRC Press also recently teamed up to bring GDNet+ Members up to a 20% discount on all CRC Press books. Learn more about this and other benefits here.


  • Content count

  • Joined

  • Last visited

Community Reputation

8326 Excellent

About unbird

  • Rank
  1. uint -> Format.R32_UInt ushort -> Format.R16_UInt Edit : Note that even after the edit you still use signed integers. Won't matter here though
  2. DX11

    He meant not to use the 'Formatted' font (it's for code anyway), e.g. like so fixed.
  3. Floats are fine. This is a common problem with standard displays which only have 8 bits precision per channel (sometimes even less). You need to dither. This is a good presentation about: Banding in Games Also search these forums, the topic returns regularily.
  4. Good news: The editor has improved a bit I guess. But now I miss the BB-code mode, since I usually edit posts in Notepad++. Is it really gone ? For programming posts, I like to use a monospace font to designate code within normal text. This was originally possible with the [tt] tag. Like here. Hodgman also uses/used it a lot. I tried to use "Formatted" from the font selection, but as you can see, it changes the whole paragraph. I currently use italic as a workaround. Also, this post, changed the word "target" with links to some online store. Admins can check the history, not sure if it sill "works". (I then changed "render target" to "rendertarget" ) This is very annoying. I don't mind ads anywhere (e.g. between thread posts), but automatically changing text of mine gives the impression I put those links in. I did not. What is this ? Thanks PS: Also: Old emojis are corrupt.
  5. Yeah, that doesn't really work. Keep your shader as is. The problem is likely elsewhere. The log you show only demonstrates your intention, not necessarily the result. I guess you have a (temporary) read write hazard, which the pipeline forbids and resets. Since one is called backFaceTexture I expect it was a rendertarget at some point. Reset the rendertarget (output merger stage) to null before setting the SRV. To make sure: turn up the DX debug layer (which immediately reports such things) and/or dig deeper, e.g. with renderdoc and check if the SRV slots are actually set. Edit: Be warned about that Rastertek article, it's misleading. He confuses texture arrays with, well, arrays of textures. A texture array is one resource (and then one SRV / slot) with several slices similar to a 3D texture. In HLSL this is explicitly written as Texture2DArray . On the other hand Texture2D blah[2] will generate two slots.
  6. (since shadertoy doesn't allow more than a couple of lines in the description and I don't want to put all the stuff into the comment section there, I abuse the blog here) For everybody new - or not so new - to shaders, hear this: Browse and use ShaderToy ! Not only is it just bloody amazing what you find there, it's veeeeeery educational. And easy to use. No hassle with setting up the GPU pipeline yourself - you only need a WebGL capable browser (most are). The interactive compiler displays errors right after the faulty code lines. Minor nuisance for me was the sometimes "restrictive" behaviour of GLSL (coming from HLSL), but that's not deal breaking. After experimenting with signed distance functions in 3D with my SlimDX/HLSL stuff I was curious about 2D. So I found this (thank you Marteen): https://www.shadertoy.com/view/4dfXDn Very nice. Basic shapes with contours and the usual combiners. Improved with lighting and shadows. Expanding on this, experimenting with polygons and stars, I wanted to put it to the test with something less abstract. Anybody remember Spirograph ? The math around this (pun intended) is already endless. I didn't even know about roulettes before. But let's start simple. There's a very old discovery from a Persian astronomer: Tusi-Couple. Here a short protocol of the progress: Needed individual colouring for the shapes (Marteen's sample combines all shapes to one SDF). Experimenting with arbitrary blending, too (blend function). Animate the inner circle/wheel within the the outer. Just basic trigonometry. To make it more clear I colored both circles "Wheel of Fortune"-style (see radial function). Choose some point on the inner wheel, mark it with a point. I chose a star shape for this. Track the ellipse path. Since I got no clue how to derive that yet, I simply trial-and-errored. Only got a filled ellipse (or rather: used a transformed circle). Found a real ellipse and used that to generate an outline (ellipse and ellipseLine functions) The ellipse line produced some artifacts at the main axis. Needed some tweaking. Still not perfect, goes havoc in the degenerate case. Now use lineDist in that case. Hmmmm, cogs would be nice. Splitting the polygon function into circleMod (to get normalized angle part) and using polyShape for laying cyclic functions around a circle. The current implementation using a simple sinus is actually NOT a clean SDF. It works well enough though - and I expect a correct implementation to be quite challenging. Added spokes and bars to give even more of a mechanical/gear feeling. Steampunk rules. Challenge: Derive ellipse path automatically. I feared the worst. Ellipses are usually a bitch - algebraically. But in this case I found that one can exploit the simplicity of the Tusi-couple and derive the major/minor axis directly (see final if-clause within sceneDist function. Not yet commented) Add some light and make the thing scale with the viewport correctly (shadertoy has fullscreen capability). TODO: Choose 2nd point with mouse. This should be possible with additional input/buffer logic of the shadertoy setup. Haven't dug into it just yet. For now one can change the point at the start of the shader code, though (relativePos constant). ENJOY! If you're interested in SDFs I recommend this as a starting point: Distance functions. Quílez has more to offer, of course. He is also quite active on shadertoy. Rewriting classic games for instance. Wow. PS: Oh my, there are even sound shaders : https://www.shadertoy.com/view/MtGSWc
  7. I get two of these warning: warning X3576: semantics in type overridden by variable/function or enclosing type because you nest structs with semantics. I'd start eliminating these. This is a lucky guess, but warnings are there for a reason.
  8. It's usually recommended to post such things in the "Your Announcement" sub-forum or better yet start a blog (journal) here and yes, give some technical details - your site is silent about that too - if you really want feedback. That being said, with the smooth camera movement and the spherical sound this has a veeeeeery Kubrick feeling about it. Congrats. One hint though. Maybe it's just the video encoding but I'd add some noise to remove the banding. It screws the perfection. You should find a couple of threads about this in the graphics section.
  9. DrawIndexedPrimitive allows such offsets. This explains the parameters pretty well: Rendering from Vertex and Index Buffers
  10. You're welcome :D Thanks for the pix. The quadratic normals will be the last piece of the puzzle. But yeah, from there I think only a higher resolution base mesh or another AO approach can help. Good luck with your terrain. Looks promising.
  11. Wow. Congrats. I stand corrected. Looks like a very slim solution, I'm impressed. At least I sensed a bug there. :P I think you're fine. That's about as good as it gets. Those edges look suspicious but also consider this: It's PN Triangles. Those cubic patches might fit your mesh - or not. E.g. teh teapot can look quite bad (it should be quad patches, it's defined that way). And there's always other schemes (NURBS, Catmull-Clarke) if that's warranted. I'm curious now, if I may ask: Has the AO improved ? And what's that mesh: Marching cubes? PS: Sorry about the visualization hint, it occasionally helps. I should also admit I don't really do OpenGL, so bear with me. :D
  12. Using face normals to visualize the continuity. Hint: Output normals as colors directly, this gives a even clearer picture, e.g. [tt]color.rgb = normal * 0.5 + 0.5;[/tt] As for your current solution: Careful now. I don't know what you have there, but it can't be a proper PN Triangle tessellation, it looks way too simple. Also, using the lerp trick is rather counterproductive: PN triangle doesn't need it. You immediately break the continuity now. The point of PN Triangle is that you can throw any mesh (with proper matching normals) at it and it just works. With the alpha-lerp you now have veiled a bug. Go try using that article's PN Triangle code as is.
  13. PN Triangles should do the trick, but it's of course more costly.  :wink:   Edit: Kudos for the debugging approach.
  14. It is indeed a downside of Phong tessellation: It does not guarantee C1 continuity across patches.   You can tweak it a bit by lerping it with the untesselated patch (s. here, alpha parameter e.g. = 3/4).
  15. Nope. Unless you have a perfectly flat ocean there will always be some back-facing triangles.