summaryrefslogtreecommitdiff
path: root/tools/buildzip.pl
diff options
context:
space:
mode:
authorAndrew Mahone <andrew.mahone@gmail.com>2009-05-23 07:55:14 +0000
committerAndrew Mahone <andrew.mahone@gmail.com>2009-05-23 07:55:14 +0000
commit802ea462d052f191a6fb4c6998c84fda934a522f (patch)
treee366a35823dafa646187fb0329682581dc3ff4ac /tools/buildzip.pl
parent9be554cb6a2a7c9ca0a4aea5c6b1967b76347f91 (diff)
downloadrockbox-802ea462d052f191a6fb4c6998c84fda934a522f.tar.gz
rockbox-802ea462d052f191a6fb4c6998c84fda934a522f.zip
Load PictureFlow logo from disk, discarding it after splash screen is done and freeing the used space for the slide cache.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@21051 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'tools/buildzip.pl')
-rwxr-xr-xtools/buildzip.pl29
1 files changed, 24 insertions, 5 deletions
diff --git a/tools/buildzip.pl b/tools/buildzip.pl
index 12fa5ed1e2..d21fd8e557 100755
--- a/tools/buildzip.pl
+++ b/tools/buildzip.pl
@@ -95,6 +95,8 @@ sub gettargetinfo {
95#ifdef HAVE_LCD_BITMAP 95#ifdef HAVE_LCD_BITMAP
96Bitmap: yes 96Bitmap: yes
97Depth: LCD_DEPTH 97Depth: LCD_DEPTH
98LCD Width: LCD_WIDTH
99LCD Height: LCD_HEIGHT
98Icon Width: CONFIG_DEFAULT_ICON_WIDTH 100Icon Width: CONFIG_DEFAULT_ICON_WIDTH
99Icon Height: CONFIG_DEFAULT_ICON_HEIGHT 101Icon Height: CONFIG_DEFAULT_ICON_HEIGHT
100#endif 102#endif
@@ -119,7 +121,7 @@ STOP
119 121
120 open(TARGET, "$c|"); 122 open(TARGET, "$c|");
121 123
122 my ($bitmap, $depth, $swcodec, $icon_h, $icon_w); 124 my ($bitmap, $width, $height, $depth, $swcodec, $icon_h, $icon_w);
123 my ($remote_depth, $remote_icon_h, $remote_icon_w); 125 my ($remote_depth, $remote_icon_h, $remote_icon_w);
124 my ($recording); 126 my ($recording);
125 my $icon_count = 1; 127 my $icon_count = 1;
@@ -131,6 +133,12 @@ STOP
131 elsif($_ =~ /^Depth: (\d*)/) { 133 elsif($_ =~ /^Depth: (\d*)/) {
132 $depth = $1; 134 $depth = $1;
133 } 135 }
136 elsif($_ =~ /^LCD Width: (\d*)/) {
137 $width = $1;
138 }
139 elsif($_ =~ /^LCD Height: (\d*)/) {
140 $height = $1;
141 }
134 elsif($_ =~ /^Icon Width: (\d*)/) { 142 elsif($_ =~ /^Icon Width: (\d*)/) {
135 $icon_w = $1; 143 $icon_w = $1;
136 } 144 }
@@ -157,7 +165,7 @@ STOP
157 close(TARGET); 165 close(TARGET);
158 unlink("gcctemp"); 166 unlink("gcctemp");
159 167
160 return ($bitmap, $depth, $icon_w, $icon_h, $recording, 168 return ($bitmap, $depth, $width, $height, $icon_w, $icon_h, $recording,
161 $swcodec, $remote_depth, $remote_icon_w, $remote_icon_h); 169 $swcodec, $remote_depth, $remote_icon_w, $remote_icon_h);
162} 170}
163 171
@@ -174,8 +182,9 @@ sub buildzip {
174 182
175 print "buildzip: image=$image fonts=$fonts\n" if $verbose; 183 print "buildzip: image=$image fonts=$fonts\n" if $verbose;
176 184
177 my ($bitmap, $depth, $icon_w, $icon_h, $recording, $swcodec, 185 my ($bitmap, $depth, $width, $height, $icon_w, $icon_h, $recording,
178 $remote_depth, $remote_icon_w, $remote_icon_h) = &gettargetinfo(); 186 $swcodec, $remote_depth, $remote_icon_w, $remote_icon_h) =
187 &gettargetinfo();
179 188
180 # print "Bitmap: $bitmap\nDepth: $depth\nSwcodec: $swcodec\n"; 189 # print "Bitmap: $bitmap\nDepth: $depth\nSwcodec: $swcodec\n";
181 190
@@ -351,7 +360,17 @@ STOP
351 } 360 }
352 361
353 if(-e "$rbdir/rocks/demos/pictureflow.rock") { 362 if(-e "$rbdir/rocks/demos/pictureflow.rock") {
354 copy("$ROOT/apps/plugins/bitmaps/native/pictureflow_emptyslide.100x100x16.bmp", "$rbdir/rocks/demos/pictureflow_emptyslide.bmp"); 363 copy("$ROOT/apps/plugins/bitmaps/native/pictureflow_emptyslide.100x100x16.bmp",
364 "$rbdir/rocks/demos/pictureflow_emptyslide.bmp");
365 my ($pf_logo);
366 if ($width < 200) {
367 $pf_logo = "pictureflow_logo.100x18x16.bmp";
368 } else {
369 $pf_logo = "pictureflow_logo.193x34x16.bmp";
370 }
371 copy("$ROOT/apps/plugins/bitmaps/native/$pf_logo",
372 "$rbdir/rocks/demos/pictureflow_splash.bmp");
373
355 } 374 }
356 375
357 if($image) { 376 if($image) {