Attend XDA's Second Annual Developer Conference, XDA:DevCon 2014!
5,804,576 Members 43,930 Now Online
XDA Developers Android and Mobile Development Forum

[TOOL] [Linux / OSX] Splash Screen creator / flasher

Tip us?
 
elegos
Old
(Last edited by elegos; 18th May 2010 at 11:24 PM.)
#1  
elegos's Avatar
Senior Member - OP
Thanks Meter 125
Posts: 404
Join Date: Jul 2009
Location: Milano
Arrow [TOOL] [Linux / OSX] Splash Screen creator / flasher

Hello there!

This is a G1 / Magic tool to easily convert images in splash screen ones.
This tool is based upon ffmpeg and you need it installed on your system before proceeding (it will prompt you about the program missing in any case)

REQUIREMENTS
  1. ffmpeg installed on your system
  2. a 320x480 image
  3. a 320x480 device (i.e. G1 / Magic) with engineering SPL

USAGE
Code:
./file [--help][-h]
Prints out how to use the script

Code:
./file your_image_file
Converts your image into a flashable splash screen, if you want the script will continue flashing the file directly.

NOTE: if you wish to make this script work with the Nexus One or any other device which doesn't share the same 320x480 resolution, just change these two variables:
Code:
size_check=307200
size_desc="320x480"
size_check is in bytes, size_desc is just a descriptive string.




I ASSUME NO RESPONSABILITY ABOUT THE USAGE OF THIS SCRIPT. USE IT "AS IS", LOOK AT THE OUTPUTS AND YOU'LL AVOID BRICKS!

Please, if you wish to redistribute this script, give the right credits and don't change the prog_header please (maybe link this discussion in a text file)!


Here the code is, just slap it in a text file, give it the executive permission (chmod +x filename) and use it!
Code:
#!/bin/bash
prog_header() {
	echo "###############################"
	echo "####### EleGoS's FFMPEG #######"
	echo "# G1/Sapphire/MyTouch3G/Magic #"
	echo "### Splash Screen converter ###"
	echo "###############################"
	echo "version 1.0"
	echo ""
}

if [ "$1" == "--help" ] || [ "$1" == "-h"  ]; then
	prog_header
	echo "Usage"
	echo "$0 your_image_file"
	exit 0
fi


warning() {
	printf "\e[0;31m$1\e[0m \n"
}

check_ok() {
	printf "\e[0;32m$1\e[0m \n"
}

ffmpeg_check=$(which ffmpeg)
size_check=307200
size_desc="320x480"

if [ "$ffmpeg_check" != "" ]; then
	OUTPUT=$(echo "$1" | cut -d'.' -f1).raw565
	clear
	prog_header
	ffmpeg -i $1 -f rawvideo -pix_fmt rgb565 $OUTPUT
	clear
	prog_header
	FILESIZE=$(cat $OUTPUT | wc -c)
	if [ $FILESIZE -eq $size_check ]; then
		check_ok "$OUTPUT is ready to be flashed."
	else
		rm $OUTPUT
		warning "$OUTPUT filesize mismatches! Wrong image size ($size_desc)? Aborted."
		exit 0
	fi
	echo "In order to flash this image you have to plug your phone in fastboot mode."
	read -p "Flash it now? (y/n) "
	if [ "$REPLY" == "y" ] || [ "$REPLY" == "Y" ]; then
		fastboot devices | grep -q "fastboot"
		if [ $? -ne 0 ]; then
			warning "The USB cable is not plugged, or the device is not in fastboot mode."
			echo "To flash the splash screen, manually execute this command once in fastboot mode:"
			echo "fastboot flash splash1 $OUTPUT"
			exit 0
		else
			fastboot flash splash1 $OUTPUT
		fi
	else
		echo "To flash the splash screen, execute this command once in fastboot mode:"
		echo "fastboot flash splash1 $OUTPUT"
		exit 0
	fi
else
	warning "ffmpeg not found! Please install it before running this script!\ni.e. (DEBIAN) apt-get install ffmpeg / (OSX) sudo port install ffmpeg"
fi
Some ready-to-flash raw565 images (link on the images):
The Following User Says Thank You to elegos For This Useful Post: [ Click to Expand ]
 
dferreira
Old
#2  
dferreira's Avatar
Senior Member
Thanks Meter 60
Posts: 1,370
Join Date: Jan 2007
Location: Oulu

 
DONATE TO ME
Thanks, this simplifies the process Works great on my Mac OSX SL.
Dropbox | Homepage | Twitter
How-to: Install Google ION Android 1.6 ROM | Compile AOSP for Sapphire | Nexus One
Google Marketplace: Overcharged | Calendar Awareness | CallerName
Donations: You can offer me a beer if you wish
 
Gen00
Old
#3  
Gen00's Avatar
Senior Member
Thanks Meter 122
Posts: 985
Join Date: Apr 2010
Location: Miami
Where can i download it for the Mac would love to create my own Splash Screen..
Phone: T-Mobile Galaxy Note 3
Recovery: TWRP 2.7.0.0
Kernel: ColonelX13
ROM: Jedi Elite v1 NB4 4.4.2
SD: 16GB Class 10
Home: Nova Launcher
MOD: Killjoy Injection

Tablet: Nexus 7
Recovery: TWRP 2.6.3.0
Kernel: M-Kernal
ROM: CM10.2
Home: Nova Launcher

Twitter: @blancoei

 
elegos
Old
#4  
elegos's Avatar
Senior Member - OP
Thanks Meter 125
Posts: 404
Join Date: Jul 2009
Location: Milano
You need:
- MacPorts installed
- ffmpeg installed via macports (sudo port install ffmpeg)

- Open the terminal -> nano splash_creator
- copy / paste the code
- [CTRL]+O, then [ENTER]. [CTRL]+X
- chmod +x splash_creator

- Put the image you want as splash screen in a folder where the script is (it is actually in your home)
- Open terminal -> cd your/folder/here
- ./splash_creator your_image_here.whatever
 
ari197
Old
#5  
Senior Member
Thanks Meter 8
Posts: 245
Join Date: Jul 2009
Location: Jakarta
Default great tools

really great tools man .. works really nice on my ubuntu ..

anyway, have any idea how to create the boot animation?
 
elegos
Old
#6  
elegos's Avatar
Senior Member - OP
Thanks Meter 125
Posts: 404
Join Date: Jul 2009
Location: Milano
nope, I only know it's in /system/media/bootanimation.zip (at least in the latest cyanogenmod), but I haven't figured out how's supposed to be created =\
 
sim64one
Old
(Last edited by sim64one; 26th May 2010 at 07:38 PM.) Reason: add pic
#7  
sim64one's Avatar
Member
Thanks Meter 0
Posts: 71
Join Date: Apr 2009
Location: Fanna - FVG - ITaly
Wink splash

Thank you guys.

The best/simple guide to change boot splash screen in 1 minute!

I've only added "sudo" to my ubuntu terminal to run it!

my own splash
Google Nexus S
ICS from OTA

-------------------------
Google Nexus One
Latest CM

-------------------------
HTC Dream
Latest CM COS

-------------------------
HTC Wildfire
stock rom

-------------------------
Acer Iconia A 500
Harkon HC 3.2

-------------------------
Gpad G12
android 2.1.1 (china quality)
 
dancerobot
Old
(Last edited by dancerobot; 28th May 2010 at 05:43 AM.)
#8  
dancerobot's Avatar
Member
Thanks Meter 7
Posts: 95
Join Date: Aug 2009
Location: Montreal
Thumbs up Thanks!

Wow, thanks, works like a charm.

For anyone who happens to like Jeanne d'Arc (Joan of Arc), here is my splash screen, feel free to use it:



And an associated boot animation

(I wrote my undergrad thesis about her)

Thanks again!
HTC One S - Liberty Rom - The 6th Element
hboot 2.16
Fido Canada
 
marquardt1219
Old
#9  
marquardt1219's Avatar
Member
Thanks Meter 2
Posts: 72
Join Date: Aug 2010
Location: fayettville,nc
ok where is the link lol?
 
lannister80
Old
#10  
Senior Member
Thanks Meter 28
Posts: 241
Join Date: Jul 2010
Location: Chicagoland
Quote:
Originally Posted by elegos View Post
You need:
- MacPorts installed
- ffmpeg installed via macports (sudo port install ffmpeg)

- Open the terminal -> nano splash_creator
- copy / paste the code
- [CTRL]+O, then [ENTER]. [CTRL]+X
- chmod +x splash_creator

- Put the image you want as splash screen in a folder where the script is (it is actually in your home)
- Open terminal -> cd your/folder/here
- ./splash_creator your_image_here.whatever
You don't necessarily need to download macports. Just grab an ffmpeg binary from wherever (included in lots of software distributions on Mac, like the KMTTG TiVo file decoder, Handbrake, etc) and just do it from the command line.

ffmpeg -i mygraphic.jpg -f rawvideo -pix_fmt rgb565 mygraphic.raw656

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes


Use Facebook Pictures as a LWP with Facebook View

One of the best things that Android has always offeredits users is the ability to tailor … more

Share Your Thoughts Anonymously with A Minimalist Social Network

Nowadays, almost everyone has a second life onthe Internet. Among the best … more

Enable Heads Up Notifications For The Sprint Galaxy S3

Heads up notifications, in case you didn’t already know, are an experimental … more

Android One Goes Live in India!

Android One is a Google initiative set to bring an AOSP-like experience tosome emergingmarkets like India, … more