| View previous topic :: View next topic |
| Author |
Message |
drcd
Joined: 04 Dec 2005 Posts: 22
|
Posted: Sat Jun 24, 2006 3:23 am Post subject: Problem with pspgl texturing |
|
|
Hi
I would like to know if there are problems with pspgl texturing because i can draw for example a quad but when i want map it, the mapping does nothing or the quad disappear. My texture is in a tga format and works on PC. So if someone here knows problems and how to solve them,can you tell me ho to fix it?
Thx |
|
| Back to top |
|
 |
zilt
Joined: 21 Feb 2006 Posts: 45 Location: Ontario, Canada
|
Posted: Sat Jun 24, 2006 4:15 am Post subject: Re: Problem with pspgl texturing |
|
|
| drcd wrote: | Hi
I would like to know if there are problems with pspgl texturing because i can draw for example a quad |
Quads aren't supported. From the pspgl homepage http://www.goop.org/psp/gl/:
GL_QUADS
not supported
Zilt |
|
| Back to top |
|
 |
drcd
Joined: 04 Dec 2005 Posts: 22
|
Posted: Sat Jun 24, 2006 4:54 am Post subject: |
|
|
I know but:
| Code: |
glBegin(GL_QUADS);
glVertex3f(Position.x,Position.y,Position.z);
glVertex3f(Position.x+Size.x,Position.y,Position.z);
glVertex3f(Position.x+Size.x,Position.y-Size.y,Position.z);
glVertex3f(Position.x,Position.y-Size.y,Position.z);
glEnd(); |
This part of code draw a quad. So i thought that the website wasn't updated. |
|
| Back to top |
|
 |
danzel
Joined: 04 Nov 2005 Posts: 182
|
Posted: Sat Jun 24, 2006 6:26 am Post subject: |
|
|
I seem to recall someone saying that GL_QUADS are implemented with GL_TRIANGLE_STRIP.
Check if your code works with them on pc, maybe its back to front?
(Haven't played with em myself, just using triangles atm) |
|
| Back to top |
|
 |
drcd
Joined: 04 Dec 2005 Posts: 22
|
Posted: Sat Jun 24, 2006 9:19 am Post subject: |
|
|
| I've tried GL_TRIANGLE_STRIP and i have the same result. I've also tried to just draw a quand using GL_QUAD and change its color using glColor3ub but the quad kept its black color. I've tried to do the same thing with GL_TRIANGLE_STRIP and apply a color but i saw the same result (black color). It's very strange. Does someone can texture a quad or change its color? |
|
| Back to top |
|
 |
drcd
Joined: 04 Dec 2005 Posts: 22
|
Posted: Sat Jun 24, 2006 10:05 pm Post subject: |
|
|
| Well, in fact there is no problem with pspgl to bind texture. I've tried with a bmp loader and it works fine but i would like to use tga or bmp with an alpha component and i don't know if it's possible. |
|
| Back to top |
|
 |
|