Non-PowerOfTwo Textures troubleshoot.

Found a bug in the latest version? Post about it here.

Moderators: andrewj, Corbin, Lobo

[phpBB Debug] PHP Warning: in file [ROOT]/vendor/twig/twig/lib/Twig/Extension/Core.php on line 1266: count(): Parameter must be an array or an object that implements Countable
User avatar
Karnizero
Posts: 370
Joined: Sun 08 Mar 2009 2:45 am
Location: Espa
[phpBB Debug] PHP Warning: in file [ROOT]/vendor/twig/twig/lib/Twig/Extension/Core.php on line 1266: count(): Parameter must be an array or an object that implements Countable

Non-PowerOfTwo Textures troubleshoot.

Postby Karnizero » Thu 17 Jun 2010 8:45 pm

I'm having problems with non-power-of-two textures in edge 1.34.

That's what the map looks like:



The original texture image is 1024x768, and scaled to 0.25 via DDFIMAGE.

Is this a bug, or doesn't EDGE support those kind of non-power-of-two textures?

Whatever it be, is it possible to be fixed for this incoming EDGE patched version?
I have lots of textures that are with those similar dimensions, and i can't edit or scale down to 512x512, etc...

Thanks in advance.

User avatar
Corbin
Posts: 657
Joined: Mon 09 Jul 2007 6:10 am
Location: vice city, california
Contact:

Postby Corbin » Thu 17 Jun 2010 9:56 pm

EDGE should support non-power-of-2 textures - I've used them before with no problems. Was the texture applied correctly?

I've not had the issue - I've used HD textures 4x that size and scaled them in IMAGES with no problems. So 1024/768, 800/600, lower or higher, all of it works.

Maybe it's a problem with the texture itself? Try rescaling the value differently or even better, just rescale the image in an editor or something similar.

User avatar
Karnizero
Posts: 370
Joined: Sun 08 Mar 2009 2:45 am
Location: Espa
[phpBB Debug] PHP Warning: in file [ROOT]/vendor/twig/twig/lib/Twig/Extension/Core.php on line 1266: count(): Parameter must be an array or an object that implements Countable

Postby Karnizero » Fri 18 Jun 2010 1:32 pm


User avatar
Corbin
Posts: 657
Joined: Mon 09 Jul 2007 6:10 am
Location: vice city, california
Contact:

Postby Corbin » Fri 18 Jun 2010 10:05 pm

Remove the scale line - does the texture apply itself correctly?

User avatar
Karnizero
Posts: 370
Joined: Sun 08 Mar 2009 2:45 am
Location: Espa
[phpBB Debug] PHP Warning: in file [ROOT]/vendor/twig/twig/lib/Twig/Extension/Core.php on line 1266: count(): Parameter must be an array or an object that implements Countable

Postby Karnizero » Sat 19 Jun 2010 10:43 am


User avatar
Corbin
Posts: 657
Joined: Mon 09 Jul 2007 6:10 am
Location: vice city, california
Contact:

Postby Corbin » Sun 20 Jun 2010 12:09 am


User avatar
Karnizero
Posts: 370
Joined: Sun 08 Mar 2009 2:45 am
Location: Espa
[phpBB Debug] PHP Warning: in file [ROOT]/vendor/twig/twig/lib/Twig/Extension/Core.php on line 1266: count(): Parameter must be an array or an object that implements Countable

Postby Karnizero » Sun 20 Jun 2010 10:15 am

Here you go:



Enjoy. :wink:

User avatar
andrewj
Posts: 698
Joined: Sat 05 May 2007 11:22 am
Location: Tasmania
[phpBB Debug] PHP Warning: in file [ROOT]/vendor/twig/twig/lib/Twig/Extension/Core.php on line 1266: count(): Parameter must be an array or an object that implements Countable

Postby andrewj » Sat 26 Jun 2010 6:29 am

Textures need to be power-of-two sizes to tile (repeat) properly.

This is a limitation of standard OpenGL. Some modern cards (NVidia iirc) have an extension which allows non-power-of-two textures, but it is not common enough to make it absolutely required by EDGE.

The other possibility is that EDGE will scale the texture to a power-of-two size automatically. I guess I don't like that option because (a) it's very slow and (b) it can make certain kinds of textures look much worse.

User avatar
Karnizero
Posts: 370
Joined: Sun 08 Mar 2009 2:45 am
Location: Espa
[phpBB Debug] PHP Warning: in file [ROOT]/vendor/twig/twig/lib/Twig/Extension/Core.php on line 1266: count(): Parameter must be an array or an object that implements Countable

Postby Karnizero » Sat 26 Jun 2010 3:53 pm



[phpBB Debug] PHP Warning: in file [ROOT]/vendor/twig/twig/lib/Twig/Extension/Core.php on line 1266: count(): Parameter must be an array or an object that implements Countable
[phpBB Debug] PHP Warning: in file [ROOT]/vendor/twig/twig/lib/Twig/Extension/Core.php on line 1266: count(): Parameter must be an array or an object that implements Countable

Return to “Bug Reports”

Who is online

Users browsing this forum: No registered users and 3 guests