So you have a crappy computer

Showcase your libraries, tools and other projects that help your fellow love users.
User avatar
Robin
The Omniscient
Posts: 6506
Joined: Fri Feb 20, 2009 4:29 pm
Location: The Netherlands
Contact:

So you have a crappy computer

Post by Robin » Fri Mar 19, 2010 11:53 am

Latest at viewtopic.php?f=5&t=1433#p16922
So you have a crappy computer and you can't have images that are not po2. Most games on the forum will need padding. If you use Linux, you're in luck.
I've written a shell script that takes a .love, unpacks it, and does the usual padding.lua magic usually done by hand.
unlove.sh.txt
This is it.
(783 Bytes) Downloaded 279 times
It requires
  • bash
  • zenity
  • unzip
  • echo
  • sed
  • mv
... so it should run out of the box for most people.

For maximum sweetness you can make your favourite filebrowser unlove .loves automatically.
Last edited by Robin on Fri Jul 02, 2010 9:19 pm, edited 1 time in total.
Help us help you: attach a .love.

User avatar
appleide
Party member
Posts: 323
Joined: Fri Jun 27, 2008 2:50 pm

Re: So you have a crappy computer

Post by appleide » Fri Mar 19, 2010 12:22 pm

Pillows

User avatar
Robin
The Omniscient
Posts: 6506
Joined: Fri Feb 20, 2009 4:29 pm
Location: The Netherlands
Contact:

Re: So you have a crappy computer

Post by Robin » Sat Mar 20, 2010 7:22 pm

I made a mistake. But I fixed it.
unlove.sh.txt
Quoting is risky business
(783 Bytes) Downloaded 260 times
Help us help you: attach a .love.

User avatar
zachwlewis
Citizen
Posts: 70
Joined: Fri Mar 19, 2010 7:58 am
Location: Huntsville, AL
Contact:

Re: So you have a crappy computer

Post by zachwlewis » Wed Mar 24, 2010 6:26 pm

What is "po2"?

User avatar
Robin
The Omniscient
Posts: 6506
Joined: Fri Feb 20, 2009 4:29 pm
Location: The Netherlands
Contact:

Re: So you have a crappy computer

Post by Robin » Wed Mar 24, 2010 6:43 pm

zachwlewis wrote:What is "po2"?
It is short for power of 2 (2^N). Old graphic cards or drivers have problems handling images not of such a width or height. It can be solved by padding the image.
Help us help you: attach a .love.

User avatar
zachwlewis
Citizen
Posts: 70
Joined: Fri Mar 19, 2010 7:58 am
Location: Huntsville, AL
Contact:

Re: So you have a crappy computer

Post by zachwlewis » Wed Mar 24, 2010 6:43 pm

That makes sense. Just never seen that shorthand before. :)

Geti
Party member
Posts: 112
Joined: Tue Oct 20, 2009 6:38 am

Re: So you have a crappy computer

Post by Geti » Fri Mar 26, 2010 10:35 am

This is handy. Of course, coders should put padding in regardless.

User avatar
Robin
The Omniscient
Posts: 6506
Joined: Fri Feb 20, 2009 4:29 pm
Location: The Netherlands
Contact:

Re: So you have a crappy computer

Post by Robin » Thu Jul 01, 2010 8:55 pm

Reuploaded for the greater good.
unlove.sh.txt
Freakin aliens
(783 Bytes) Downloaded 335 times
Help us help you: attach a .love.

User avatar
Luiji
Party member
Posts: 396
Joined: Mon May 17, 2010 6:59 pm

Re: So you have a crappy computer

Post by Luiji » Fri Jul 02, 2010 12:07 am

I don't quite understand, what does padding do?
Good bye.

User avatar
rikkit
Prole
Posts: 4
Joined: Mon Jun 28, 2010 2:44 am
Location: Leicestershire, UK
Contact:

Re: So you have a crappy computer

Post by rikkit » Fri Jul 02, 2010 1:08 am

Luiji wrote:I don't quite understand, what does padding do?
As far as I can gather, it adds transparent extra bits to the image so that it is "po2."

Post Reply

Who is online

Users browsing this forum: No registered users and 7 guests