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

crazy_crab

Members
  • Content count

    18
  • Joined

  • Last visited

Community Reputation

183 Neutral

About crazy_crab

  • Rank
    Member
  1. newbies use D3D9, maybe because still there are more tutorials and books on D3D9 than D3D10/11 and for very smaller or startup projects,IMO d3d9 is easy to use and setup.but yeah learning FF pipeline is waste of time now.
  2. or you could use bezier or catmull curves for smooth translation.
  3. you can also use octree to improve performance if area is mostly static. you can also use heightmaps instead of ray cast.
  4. did you try D3DPT_TRIANGLESTRIP instead of D3DPT_TRIANGLEFAN ???
  5. @Jason Z and NightCreature83 thanks, actually i have engine in dx9 ,but wanted to process some raw data in gpu and give output to a texture.so i choose compute shader of dx11 and I dont want to change existing source which is written in dx9.   however I figured  out the problem as D3DFMT_A8R8G8B8 will match to DXGI_FORMAT_B8G8R8A8_UNORM.however you cant then create UAV from that format.You have to create texture with DXGI_FORMAT_B8G8R8A8_TYPELESS.then create UAV with castable format like  DXGI_FORMAT_R32_UINT and then do your work on shader. thanks.
  6. Hi I am trying to share resource between directx9 and directx11,having some problems regarding this. what i am doing is this :- STEP1: created a shared texture with format D3DFMT_A8R8G8B8 in directx9 and get its shared handle. STEP2: open the shared texture with directx11 device using the handle. STEP3: create UAV of texture creating in step3. but step 3 fails with error D3D11: ERROR: ID3D11Device::CreateUnorderedAccessView: The format (0x57, B8G8R8A8_UNORM) cannot be used with a Typed Unordered Access View. [ STATE_CREATION ERROR #2097344: CREATEUNORDEREDACCESSVIEW_INVALIDFORMAT ] D3D11: ERROR: ID3D11Device::CreateUnorderedAccessView: A UnorderedAccessView cannot be created of a Resource that did not specify the D3D11_BIND_UNORDERED_ACCESS BindFlag. [ STATE_CREATION ERROR #2097342: CREATEUNORDEREDACCESSVIEW_INVALIDRESOURCE ]     please help me here that how can i create UAV of a shared texture which is created in directx9. //code //DX9 HRESULT hr = g_pd3dDevice9->CreateTexture( Width , Height , 1 , D3DUSAGE_RENDERTARGET , D3DFMT_A8R8G8B8 ,D3DPOOL_DEFAULT , &g_pTexture , &g_pSharedHandleTex9 ); //DX11 hr = m_pDevice11->OpenSharedResource( g_pSharedHandleTex9 , __uuidof(ID3D11Texture2D) , (void**)&m_pTetxure); //success hr = m_pDevice11->CreateUnorderedAccessView( m_pTetxure, NULL, &m_pTetxureUAV); //fails     so,instead of this, I tried to do  STEP1: create a texture in directx11 format  DXGI_FORMAT_R8G8B8A8_UNORM (with UAV bind flag) STEP2: created a shared texture with format D3DFMT_A8R8G8B8 in directx9 and get its shared handle. STEP3: open the shared texture with directx11 device using the handle. STEP4: CopyResource() from the texture created on step 1 to the shared texture.    but the step4 failed,with error  D3D11: ERROR: ID3D11DeviceContext::CopyResource: Cannot invoke CopyResource when the Formats of each Resource are not the same or at least castable to each other, unless one format is compressed (DXGI_FORMAT_R9G9B9E5_SHAREDEXP, or DXGI_FORMAT_BC[1,2,3,4,5]_* ) and the source format is similar to the dest according to: BC[1|4] ~= R16G16B16A16|R32G32, BC[2|3|5] ~= R32G32B32A32, R9G9B9E5_SHAREDEXP ~= R32. [ RESOURCE_MANIPULATION ERROR #284: COPYRESOURCE_INVALIDSOURCE ]       I thought that D3DFMT_A8R8G8B8 and DXGI_FORMAT_R8G8B8A8_UNORM should match , just like DXGI_FORMAT_R32_FLOAT and D3DFMT_R32F matches.please help me here.   code: //DX9 HRESULT hr = g_pd3dDevice9->CreateTexture( Width , Height , 1 , D3DUSAGE_RENDERTARGET , D3DFMT_A8R8G8B8 ,D3DPOOL_DEFAULT , &g_pTexture , &g_pSharedHandleTex9 ); //DX11 D3D11_TEXTURE2D_DESC desc; desc.Width              = width; desc.Height             = height; .... desc.Format             = DXGI_FORMAT_R8G8B8A8_UNORM; hr = m_pDevice11->CreateTexture2D(&desc, NULL, &m_pTetxure); //success ... ... hr = m_pDevice->OpenSharedResource( g_pSharedHandleTex9 , __uuidof(ID3D11Texture2D) , (void**)&m_pSTexture); m_pDeviceContext11->CopyResource( m_pSTexture, m_pTetxure ); //fails     please help me. thanks.  
  7. hi, i made a simple 3d car race game and put it to opensource.it is made in c++,OpenGL,havok physics.it is very basic and good for bigineers.may someone will be helped by it. here is the link to get executable or source [url="http://code.google.com/p/3d-car-race-game/downloads/list"]http://code.google.com/p/3d-car-race-game/downloads/list[/url] let me know your suggestions on it. thanks.
  8. ok, i solve this problem.. actually the problem was in drawing of sprit Points function. i was using DrawPrimptiveUP but when i used DrawPrimptive(vertix buffer),everything is fine now... but i can not understand why this problem was not there when i use DrawPrimptiveUP and dont render mesh.
  9. hi, i am make a simple particle system using point sprite.every thing is fine but when i draw a mesh (or actally call drawsubset(x) for mesh drawing) ,particles shows very far from each other and fire system particles becomes like sky-stars. my code for sprite drawing is stack->Push(); { stack->Translate(pos.x,pos.y,pos.z); g_pd3dDevice->SetTransform(D3DTS_WORLD, stack->GetTop()); g_pd3dDevice->SetRenderState( D3DRS_ZWRITEENABLE, FALSE ); g_pd3dDevice->SetRenderState( D3DRS_ALPHABLENDENABLE, TRUE ); g_pd3dDevice->SetRenderState( D3DRS_DESTBLEND, D3DBLEND_ONE ); g_pd3dDevice->SetRenderState( D3DRS_POINTSPRITEENABLE, TRUE ); // Turn on point sprites g_pd3dDevice->SetRenderState( D3DRS_POINTSCALEENABLE, TRUE ); // Allow sprites to be scaled with distance g_pd3dDevice->SetRenderState( D3DRS_POINTSIZE, FtoDW( size ) ); // Float value that specifies the size to use for point size computation in cases where point size is not specified for each vertex. g_pd3dDevice->SetRenderState( D3DRS_POINTSIZE_MIN, FtoDW(1.0f) ); // Float value that specifies the minimum size of point primitives. Point primitives are clamped to this size during rendering. g_pd3dDevice->SetRenderState( D3DRS_POINTSCALE_A, FtoDW(0.0f) ); // Default 1.0 g_pd3dDevice->SetRenderState( D3DRS_POINTSCALE_B, FtoDW(1.0f) ); // Default 0.0 g_pd3dDevice->SetRenderState( D3DRS_POINTSCALE_C, FtoDW(0.0f) ); // Default 0.0 DrawPoint(g_pd3dDevice); g_pd3dDevice->SetRenderState( D3DRS_ZWRITEENABLE, TRUE ); g_pd3dDevice->SetRenderState( D3DRS_ALPHABLENDENABLE, FALSE ); g_pd3dDevice->SetRenderState( D3DRS_POINTSPRITEENABLE, FALSE ); g_pd3dDevice->SetRenderState( D3DRS_POINTSCALEENABLE, FALSE ); } for mesh drawing,i am using MS sample mesh drawing code... stack->Push(); { stack->Scale(.5,.5,.5); r->Draw(); }stack->Pop();d3ddev->SetTransform(D3DTS_WORLD, stack->GetTop()); please help me. thanks
  10. i solve the problem... D3DXMatrixScaling(&mat,.02,.02,.02); D3DXMatrixMultiply(stack->GetTop(),stack->GetTop(),&mat); D3DXMatrixRotationY(&mat,D3DXToRadian(-10)); D3DXMatrixMultiply(stack->GetTop(),stack->GetTop(),&mat); D3DXMatrixRotationX(&mat,D3DXToRadian(-5)); D3DXMatrixMultiply(stack->GetTop(),stack->GetTop(),&mat); stack->Translate(.6,-.6,0); D3DXMATRIX matWorld; d3ddev->GetTransform( D3DTS_VIEW, &matView); D3DXMatrixInverse(&matWorld, 0, &matView); D3DXMatrixMultiply(stack->GetTop(),stack->GetTop(),&matWorld); d3ddev->SetTransform( D3DTS_WORLD, stack->GetTop() ); gun->Draw(); actually i sholud multyply the inverse view matrix after all the rotation and translations.this simple thing gave me a bad headach...
  11. hi, i am making a simple FPS game in DirectX and c++. i have a weapon mesh and want to show it as the camera rotate and move,i tried for many hours but can not succeed. -I know the camera forward,up and right directions (in vector forms) g_vLook,g_vUp,g_vRight -I know the current position of camera. g_vEye so, how can i set up the rotations and translation of the weapon. my code is.. D3DXMATRIX matWorld,temp; g_pd3dDevice->GetTransform( D3DTS_VIEW, &matView ); D3DXMatrixInverse(&matWorld, 0, &matView); //scaling D3DXMatrixScaling(&mat,.02,.02,.02); D3DXMatrixMultiply(&matWorld,&matWorld,&mat); //translation D3DXMatrixTranslation(&mat,g_vEye.x,g_vEye.y,g_vEye.z); D3DXMatrixMultiply(&matWorld,&matWorld,&mat); gun->Draw(); by this code not working well. please help me.
  12. OpenGL

    I am specifying more... Actually i want to add rivers and hills along my path(road),like in BELOW image..here hills have also turns as the road turns..... please tell any good way how game programmers make road path and side scenery along the road... thanx.
  13. hi I want to make a car race game in opengl.I have a 3ds model of the road which is in zig-zagged shape,now i want to add scenery along with the both corners of the road....but i cant get any way to do it as i have to get all the corners vertics of the road to do that. So,please tell the standard way,most game programmers do... thanks.
  14. hi, i am making a compound shape in havok using convex list. I created and added it to world correctly and for rendering i am making meshes using hkDisplayGeometry of each sub-shape of compound.... my code is... case HK_SHAPE_CONVEX_LIST: { hkpShapeDisplayBuilder::hkpShapeDisplayBuilderEnvironment env; hkpShapeDisplayBuilder GeometryBuilder(env); hkArray<hkDisplayGeometry*>* displayGeometries; displayGeometries = new hkArray<hkDisplayGeometry*>; GeometryBuilder.buildDisplayGeometries(shape, *displayGeometries ); printf("%d",displayGeometries->getSize()) //ans=5,no problem here for (int j=0; j<displayGeometries->getSize(); j++) { hkDisplayGeometry* geometry = (*displayGeometries)[j]; if(geometry->getGeometry()==NULL)printf("Something Wrong......."); } } break; my problem is that geometry->getGeometry() returns null in above code......all is fine before the for loop,i couldn't understand where the problem is??? thanx...