Solved

Invalid pixel format in DirectX7

Posted on 2001-06-07
4
954 Views
Last Modified: 2007-12-19
When I try to create a surface that can be used as a texture (can't remember the DDSCAPS constant offhand) in DirectX7 I am getting a DDERR_INVALIDPIXELFORMAT error.

The example code I have doesn't populate the pixelformat structure so neither did I.  Am I doing something wrong?  Should I use CreateTexture rather than CreateSurface with the texture caps?  

I saw something in the docs that suggested you can't have a 16-bit texture.  I changed my program to 32 bit and that didn't seem to help.

Thanks in advance,
LEJ
0
Comment
Question by:l99057j
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
4 Comments
 
LVL 15

Expert Comment

by:lyonst
ID: 6171168
Hi,

Video Card Problems: (back to top)  

Question: Do I have to update my video drivers to use TerraExplorer?

Answer: Updating your drivers periodically ensures optimal performance from your computer. In most cases Installing TerraExplorer will not necessitate updating your video drivers. Cards with outdated drivers could receive one of the following errors.

- DirectX error messages ("cannot initialize DirectX", "try reinstalling and restarting the application");

- D3dim.dll error messages;

- DirectDraw and Ddraw.dll error messages
("DirectDrawError: E_NOINTERFACE", "Error starting program:
A required .DLL file, DDraw.dll, was not found", "Direct draw error: DDERR_INVALIDPIXELFormat");

Cheers,

T.
0
 
LVL 15

Expert Comment

by:lyonst
ID: 6171173
Hi,

Have you tried 24 Bit as this can also resolve this problem.

Cheers,

T.
0
 
LVL 54

Expert Comment

by:nico5038
ID: 7375177

No comment has been added lately, so it's time to clean up this TA.
I will leave a recommendation in the Cleanup topic area that this question is:
 - PAQ'd and pts removed
Please leave any comments here within the
next seven days.

PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER !

Nic;o)
0
 
LVL 5

Accepted Solution

by:
Netminder earned 0 total points
ID: 7400547
Per recommendation, points NOT refunded and question closed.

Netminder
CS Moderator
0

Featured Post

Get proactive database performance tuning online

At Percona’s web store you can order full Percona Database Performance Audit in minutes. Find out the health of your database, and how to improve it. Pay online with a credit card. Improve your database performance now!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

What is RenderMan: RenderMan is a not any particular piece of software. RenderMan is an industry standard, defining set of rules that any rendering software should use, to be RenderMan-compliant. Pixar's RenderMan is a flagship implementation of …
Recently, in one of the tech-blogs I usually read, I saw a post about the best-selling video games through history. The first place in the list is for the classic, extremely addictive Tetris. Well, a long time ago, in a galaxy far far away, I was…
In this brief tutorial Pawel from AdRem Software explains how you can quickly find out which services are running on your network, or what are the IP addresses of servers responsible for each service. Software used is freeware NetCrunch Tools (https…
Sometimes it takes a new vantage point, apart from our everyday security practices, to truly see our Active Directory (AD) vulnerabilities. We get used to implementing the same techniques and checking the same areas for a breach. This pattern can re…
Suggested Courses

626 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question