• Advertisement
Sign in to follow this  

It works, but only on my PC

This topic is 3730 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

hi how can I fix these problems, if they are never the same and not on my PC? 3 people tested this... The first got an error, that the program couldn't find d3dx9_30.dll The second one got an runtime error. The third got the picture undetailed or shrinked. the sources: http://ysites.de/DirectXtestProj.zip [Edited by - Ankou6591 on October 28, 2007 4:31:18 PM]

Share this post


Link to post
Share on other sites
Advertisement
The first guy has an old version of DirectX and needs to update.

DirectX 9.0c means nothing, refer to them by "DirectX April 2007" "DirectX June 2007" etc..

The second you have specified no valuable information about.
Third one, you got any screenshots?


Unhandled exception at 0x7e43171b in DirectXtestProj.exe: 0xC0000005: Access violation reading location 0x00330033.

Try throwing out a few IsBadReadPtr() here and there, see if it helps your code.
Check all hresults, loading a mesh perhaps, then trying to draw it without checking if it succeeded? Hard to say.

Or perhaps post some source, you're not [i hope] gonna find a lot of people willing to run an unknown exe file on their system :p

Share this post


Link to post
Share on other sites
Quote:

Try throwing out a few IsBadReadPtr() here and there, see if it helps your code.

I agree with http://blogs.msdn.com/oldnewthing/archive/2006/09/27/773741.aspx

Share this post


Link to post
Share on other sites
Quote:
Original post by Unknown1004
Or you could just include the binary module (d3dx9_30.dll) in the EXE folder?


The EULA prohibits this.

Share this post


Link to post
Share on other sites
Quote:

Third one, you got any screenshots?

http://rpgmakerxpdreams.rp.funpic.de/Bilderupload/daten/1193606682_Fragmente.PNG
and I found another person, who has the same result...

Quote:

Install the VC++ redist SP1

I'm using MingW

Quote:

Or perhaps post some source, you're not [i hope] gonna find a lot of people willing to run an unknown exe file on their system :p

oh sorry i wanted to post the complete folder...
i edited the link in the first post

Share this post


Link to post
Share on other sites
The "undetailed and shrunk texture" problem is probably occurring because that texture

a) Was not power-of-two, or
b) Was not square

Newer video cards can do non-pow2 textures and non-square textures, but older ones cannot.

I would suggest that you keep to the standard, and always use pow2 textures at least. Making all of your textures square is an extra bonus, but sometimes this wastes space, in which case the solution is to design your game graphics and gui graphics around these hardware limitations rather than the other way around.

Share this post


Link to post
Share on other sites
Ok I was looking for a post and here it is, also see the link in the post to legalize's book.

Share this post


Link to post
Share on other sites
but why do some people with the newest DirectX have this .dll and some people don't? they've all a new SDK. And I know from at least one with a good graphic card.
the other error, I can't spezify it because windows doesn't tell anything about the problem. Just that there is one... It occurs some times when I start it and sometimes it doesn't. And at some peoples pc it occurs everytime when they start it.
I know it sounds strange, but that are all informations I have =( I'm really annoyed of it...

Share this post


Link to post
Share on other sites
1) marius1930 was wrong about the dll. d3dx9_30.dll is NOT included with DirectX end user run times. YOU are responsible for either installing this DLL in user's system folder, or including it in the same folder as your exe (which is the most common way). You have to assume your users will not have this dll.

2) Your texture size is not a power of two. Make is 512x512 or 256x512 and rearrange images on it to fit. Otherwise, it may not get loaded at all (causing a crash on program termination), or will get stretched on load and look bad.

3) You cannot initialize WNDCLASSEX::lpszClassName with a direct string constant. Instead create a constant explicitly and set lpszClassName to that.

[Edited by - ValMan on October 29, 2007 1:31:13 PM]

Share this post


Link to post
Share on other sites
what do i have to do during the initialization, so that textures with non pow2 sizes?

and did I undestand it wrong, that it's not allowed to simply put the .dlls in the gamefolder?

Share this post


Link to post
Share on other sites
Quote:
Original post by Ankou6591
what do i have to do during the initialization, so that textures with non pow2 sizes?

and did I undestand it wrong, that it's not allowed to simply put the .dlls in the gamefolder?
You need to make the textures a power of two in size. E.g. a 200x200 texture would need to be 256x256.

And yes, you're not legally alowed to provide the DLLs with your exe, since if the DLL is patched via Windows update, Windows update can't patch the DLL in the game folder, so your game won't be patched which is a security problem. The correct way to handle this is to provide the DirectX redistributable package (Which is with your SDK), or to link them to the online version (I don't have a link offhand, but Googling on Microsoft.com for the DirectX redistributable with the appropriate version (E.g. April 2007) should show it up.

Share this post


Link to post
Share on other sites
Quote:
Original post by ValMan
The "undetailed and shrunk texture" problem is probably occurring because that texture

a) Was not power-of-two, or
b) Was not square

Newer video cards can do non-pow2 textures and non-square textures, but older ones cannot.

I would suggest that you keep to the standard, and always use pow2 textures at least. Making all of your textures square is an extra bonus, but sometimes this wastes space, in which case the solution is to design your game graphics and gui graphics around these hardware limitations rather than the other way around.

Non-square textures should be fine. You have to go all the way back to the Voodoo 2 to find a card which couldn't handle that.

Share this post


Link to post
Share on other sites
ok, now it seems to work, but I have still some questions concerning distribution of DirectX.
So I read the chapter in Legalizes book and there's described how to check for the current DirectX Version, but only if it's 9.0c, but you told me
Quote:

DirectX 9.0c means nothing, refer to them by "DirectX April 2007" "DirectX June 2007" etc..

so, how can I check for the month?

Share this post


Link to post
Share on other sites
Checking for the month is non-trivial. There is a D3DXCheckVersion() (or similar) function call you can use, but it's largely a waste of time.

Bundle up the redist package and installer as all good software should and leave it at that. The installer is smart enough to know whether to install the file or ignore it if it already exists.

hth
JAck

Share this post


Link to post
Share on other sites
hi...
:'( I was wrong NOTHING works
I've some new sources and Screens...
http://ysites.de/sources.zip
It would be REALLY nice if someone could look over them and help me...
There are 2 different kind of errors...

the first is on the screenshot
http://rpgmakerxpdreams.rp.funpic.de/Bilderupload/daten/1194208092_screen.PNG
there are 2 persons with this problem, it looks the same.
And that is how it should be:
http://rpgmakerxpdreams.rp.funpic.de/Bilderupload/daten/1194208206_screen.PNG

2 other persons get an error, the windowsstandard one.
This time the program have a log, you can see it in the source, but the log is german, sorry. So: They error occures at SetRenderState, it doesn't matter which RenderState.


So please, what do i have to do, that it works on all PCs correctly

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement