• 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.

Igor Kokarev

Members
  • Content count

    10
  • Joined

  • Last visited

Community Reputation

115 Neutral

About Igor Kokarev

  • Rank
    Member
  1. Update: The problem is solved. Thanks.   We're trying to implement 2-pass Gaussian blur on HSL2.0. Here is a code of shader for horizontal blur. Pixelwidth is a radius. This shader doesn't work, the result looks as without the shader, please can you help? sampler s0: register(s0); float1 pixelwidth: register(c0); float PixelKernel[13] = { -6, -5, -4, -3, -2, -1, 0, 1, 2, 3, 4, 5, 6, }; static const float BlurWeights[13] = { 0.002216, 0.008764, 0.026995, 0.064759, 0.120985, 0.176033, 0.199471, 0.176033, 0.120985, 0.064759, 0.026995, 0.008764, 0.002216, }; float1 Clip(float1 arg): float1 { if (arg<0) arg=0; if (arg>1) arg=1; return arg; } float4 main_ps(float2 tex: TEXCOORD0):COLOR { float4 cl=(0,0,0,0); float2 coord=tex; for (int i=0; i<13; i++){ coord.x=Clip(tex.x+PixelKernel[i]*pixelwidth); cl+=tex2D(s0, coord)*BlurWeights[i]; } return cl; }
  2. We afraid that Summed Area Tables on PS 2.0 will not work fast enough.   Computable shaders is a good idea, but it require DX11 or Cuda.
  3. Thanks, I'll try Summed Area Tables.
  4. Thanks for your responses!   I need to apply a dynamic blur to photography for multimedia application in realtime. Blur radius will change in every frame smoothly. Radius will be between 0 and around 150.   Hodgman, I see very nice blur on your screenshot. My congratulations! Regrettably I need variable blur adjustable by user (templates).
  5. Please advice blur with variable radius with good quality for entire screen.   I've read advice to use separated gaussian blur x, y axis. However all examples were for certain fixed radius. How to implement variable radius?   Also it's important to avoid moire artefacts for animated objects inside blurred scene. We tried downsampling + spline and it gave moire defects.    
  6. phil_t,   Results are brilliant! Exactly what we need for a correct alpha blending. Thank you!
  7. phil_t,   Thanks again! I'll write about result.
  8. phil_t,   Thanks, we'll try idea with premultiplied alpha. Very interesting.     Please look on the following illustration:   [attachment=14384:86704_1363885776_compare.png]   - Left picture - layers in Photoshop.   - Right picture - rendering of alpha textures to alpha rendertarget.   Problems of DirectX rendering with D3DBLENDOP_ADD   1. Shadows of globes are more bright than on left picture. 2. Hardly visible visual artefacts on a border between two globes. 3. Color of shadows of globes depends on color of rendertarget, although color is transparent. Left part - black background color (alpha 0), right part - background color is red (alpha 0).   So as you can see the result is terrible. And we can't mix layers correctly for our multimedia application.        
  9. C0lumbo,   Thanks you for advice!   But if we understood rightly your sample, it doesn't take alpha of source textures. My images has semi-transparent areas and with your code pictures will have aliased edges. Right?     We need the following result:      resultAlpha = dstAlpha + srcAlpha - dstAlpha*srcAlpha ;    resultRed = ( dstRed*dstAlpha*(1-srcAlpha) + srcRed*srcAlpha  ) / resAlpha ;    resultGreen = ( dstGreen*dstAlpha*(1-srcAlpha) + srcGreen*srcAlpha  ) / resAlpha ;    resultBlue = ( dstBlue*dstAlpha*(1-srcAlpha) + srcBlue*srcAlpha  ) / resAlpha ;    Same formala is used in Photoshop to mix layers.
  10. I need to render several alpha textures (PNG images - photos and text) to 32-bit alpha RT. And then render alpha RT to backbuffer. This is for 2D multimedia app.   D3DBLENDOP_ADD doesn not mix correctly layers. The result is not same if I render alpha textures directly to 24-bit backbuffer.   In other words, I need same alpha blending as used for layers in Photoshop (by default).   I know alternate solution with rendering of each alpha texture to RT and then use shaders. But it works slow because of multiple switching of rendertargets for each alpha texture.