Jump to content

  • Log In with Google      Sign In   
  • Create Account

We need your help!

We need 7 developers from Canada and 18 more from Australia to help us complete a research survey.

Support our site by taking a quick sponsored survey and win a chance at a $50 Amazon gift card. Click here to get started!


bobobobo

Member Since 09 Mar 2010
Offline Last Active Apr 24 2014 02:50 AM

Topics I've Started

Can you cpu access a texcube you load from a DDS?

27 September 2011 - 05:10 PM

I'm trying to load a texture cube from a .dds file.

Now its loaded, and it renders fine, (which means its loading fine!)

But _after_ loading, I need to do some processing on the texcube using CPU ops.

So I have:


// LOAD THE CUBEMAP
D3DX11_IMAGE_LOAD_INFO loadInfo ;
loadInfo.MiscFlags = D3D11_RESOURCE_MISC_TEXTURECUBE;
DX_CHECK( D3DX11CreateTextureFromFileA( d3d, "C:/SHARE/res/office.dds", &loadInfo, 0, (ID3D11Resource**)&cubeTex, 0 ), "load texture cube" );

So that works. But when I try to call ID3D11DeviceContext::Map later on that texCube:


D3D11_TEXTURE2D_DESC cubeTexDesc ;
cubeTex->GetDesc(&cubeTexDesc);
if( cubeTexDesc.CPUAccessFlags & D3D11_CPU_ACCESS_READ ) // FALSE!!

I tried forcing:


// LOAD THE CUBEMAP
D3DX11_IMAGE_LOAD_INFO loadInfo ;
loadInfo.MiscFlags = D3D11_RESOURCE_MISC_TEXTURECUBE;
loadInfo.CpuAccessFlags = D3D11_CPU_ACCESS_READ ;
DX_CHECK( D3DX11CreateTextureFromFileA( d3d, "C:/SHARE/res/office.dds", &loadInfo, 0, (ID3D11Resource**)&cubeTex, 0 ), "load texture cube" ); // LOAD FAILS with cpuAccessFlags!!!


But that doesn't work (the texture load fails!)

FMOD play overlapping sounds

09 March 2010 - 03:27 PM

This may be a build in feature of FMOD, but I'd like to see if i can override it. When playing a SOUND with FMOD_System_PlaySound,
FMOD_System_PlaySound( system, FMOD_CHANNEL_FREE, SOUND, false, &channel ) ;
(YES I use the C api ;) ) If you've ALREADY started playing SOUND, then what happens is the original one is STOPPED and SOUND starts over again. The effect is the original sound gets "cut off". I don't want that, I want SOUND to overlap itself... I want another "instance" of the sound to start playing without affecting the original sound that's already playing.

PARTNERS