ripxplore 0.4.0 → 0.5.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/bin/ripxplore.rb +103 -95
- data/doc/classes/AppleDos.html +20 -22
- data/doc/classes/AppleDos.src/M000036.html +18 -0
- data/doc/classes/AppleDos.src/M000037.html +18 -0
- data/doc/classes/AppleDos.src/M000038.html +18 -0
- data/doc/classes/AppleDos.src/M000039.html +73 -0
- data/doc/classes/AppleDosPic.html +20 -20
- data/doc/classes/AppleDosPic.src/M000051.html +20 -0
- data/doc/classes/AppleDosPic.src/M000052.html +18 -0
- data/doc/classes/AppleDosPic.src/M000053.html +18 -0
- data/doc/classes/AppleDosPic.src/M000054.html +18 -0
- data/doc/classes/AppleHiResPic.html +32 -38
- data/doc/classes/AppleHiResPic.src/M000012.html +18 -0
- data/doc/classes/AppleHiResPic.src/M000013.html +18 -0
- data/doc/classes/AppleHiResPic.src/M000014.html +53 -0
- data/doc/classes/AppleHiResPic.src/M000015.html +18 -0
- data/doc/classes/AppleHiResPic.src/M000016.html +18 -0
- data/doc/classes/AppleHiResPic.src/M000017.html +18 -0
- data/doc/classes/AxePackedAppleDosPic.html +145 -0
- data/doc/classes/AxePackedAppleDosPic.src/M000010.html +59 -0
- data/doc/classes/ImageSniffing.html +8 -8
- data/doc/classes/ImageSniffing.src/M000008.html +121 -0
- data/doc/classes/NADOLPic.html +10 -10
- data/doc/classes/NADOLPic.src/M000049.html +20 -0
- data/doc/classes/NADOLPic.src/M000050.html +18 -0
- data/doc/classes/NativeFileType.html +91 -91
- data/doc/classes/NativeFileType.src/M000018.html +22 -0
- data/doc/classes/NativeFileType.src/M000019.html +18 -0
- data/doc/classes/NativeFileType.src/M000020.html +18 -0
- data/doc/classes/NativeFileType.src/M000021.html +18 -0
- data/doc/classes/NativeFileType.src/M000022.html +18 -0
- data/doc/classes/NativeFileType.src/M000023.html +18 -0
- data/doc/classes/NativeFileType.src/M000024.html +18 -0
- data/doc/classes/NativeFileType.src/M000025.html +23 -0
- data/doc/classes/NativeFileType.src/M000026.html +18 -0
- data/doc/classes/NativeFileType.src/M000027.html +18 -0
- data/doc/classes/NativeFileType.src/M000028.html +24 -0
- data/doc/classes/NativeFileType.src/M000029.html +41 -0
- data/doc/classes/NativeFileType.src/M000030.html +24 -0
- data/doc/classes/NativeFileType.src/M000031.html +18 -0
- data/doc/classes/NativeFileType.src/M000032.html +18 -0
- data/doc/classes/NativeFileType.src/M000033.html +18 -0
- data/doc/classes/NativeFileType.src/M000034.html +20 -0
- data/doc/classes/NativeFileType.src/M000035.html +28 -0
- data/doc/classes/PackedAppleDosPic.html +9 -8
- data/doc/classes/PackedAppleDosPic.src/M000009.html +40 -0
- data/doc/classes/PackedProDosPic.html +145 -0
- data/doc/classes/PackedProDosPic.src/M000011.html +40 -0
- data/doc/classes/PascalPic.html +10 -10
- data/doc/classes/PascalPic.src/M000047.html +20 -0
- data/doc/classes/PascalPic.src/M000048.html +18 -0
- data/doc/classes/ProDosBINFile.html +186 -0
- data/doc/classes/ProDosBINFile.src/M000040.html +20 -0
- data/doc/classes/ProDosBINFile.src/M000041.html +18 -0
- data/doc/classes/ProDosBINFile.src/M000042.html +18 -0
- data/doc/classes/ProDosBINFile.src/M000043.html +18 -0
- data/doc/classes/ProDosBinPic.html +15 -15
- data/doc/classes/ProDosBinPic.src/M000044.html +20 -0
- data/doc/classes/ProDosBinPic.src/M000045.html +18 -0
- data/doc/classes/ProDosBinPic.src/M000046.html +18 -0
- data/doc/classes/ProDosFile.html +15 -15
- data/doc/classes/ProDosFile.src/M000005.html +20 -0
- data/doc/classes/ProDosFile.src/M000006.html +18 -0
- data/doc/classes/ProDosFile.src/M000007.html +19 -0
- data/doc/classes/RipXplore.html +1 -1
- data/doc/classes/ScrunchedAppleDosPic.html +139 -0
- data/doc/classes/ScrunchedAppleDosPic.src/M000004.html +37 -0
- data/doc/created.rid +1 -1
- data/doc/files/bin/ripxplore_rb.html +1 -1
- data/doc/files/lib/NativeFileType_rb.html +3 -3
- data/doc/files/lib/RipXplore_rb.html +2 -2
- data/doc/files/lib/file_systems/AppleDos_rb.html +2 -2
- data/doc/files/lib/native_file_types/apple2/AppleHiResPic_rb.html +1 -1
- data/doc/files/lib/native_file_types/apple2/PackedHiResPicFormats_rb.html +101 -0
- data/doc/files/lib/native_file_types/apple2/ProDosFile_rb.html +1 -1
- data/doc/files/test/tc_apple_2_rb.html +1 -1
- data/doc/files/test/testhelper_rb.html +17 -17
- data/doc/files/test/testhelper_rb.src/M000001.html +21 -0
- data/doc/files/test/testhelper_rb.src/M000002.html +18 -0
- data/doc/files/test/testhelper_rb.src/M000003.html +50 -8
- data/doc/fr_class_index.html +14 -0
- data/doc/fr_file_index.html +8 -0
- data/doc/fr_method_index.html +54 -0
- data/doc/index.html +1 -1
- data/lib/NativeFileType.rb +3 -2
- data/lib/RipXplore.rb +1 -1
- data/lib/file_systems/AppleDos.rb +16 -29
- data/lib/native_file_types/apple2/AppleHiResPic.rb +11 -10
- data/lib/native_file_types/apple2/PackedHiResPicFormats.rb +207 -0
- data/lib/native_file_types/apple2/ProDosFile.rb +21 -0
- data/test/native_files/30026e5208f55f2cbae4fc591f51de4a-5.png +0 -0
- data/test/native_files/f05d95201b4e736216448ba9f9902db6-11.png +0 -0
- data/test/native_files/f8819465c0c0eb1e74fa88c7e1e59405-7.png +0 -0
- data/test/tc_apple_2.rb +23 -4
- data/test/testhelper.rb +2 -0
- data/test/testlog.txt +56809 -119242
- metadata +68 -3
- data/lib/native_file_types/apple2/PackedAppleDosPic.rb +0 -85
@@ -94,12 +94,12 @@ generic class for a HI-RES picture
|
|
94
94
|
<h3 class="section-bar">Methods</h3>
|
95
95
|
|
96
96
|
<div class="name-list">
|
97
|
-
<a href="#
|
98
|
-
<a href="#
|
99
|
-
<a href="#
|
100
|
-
<a href="#
|
101
|
-
<a href="#
|
102
|
-
<a href="#
|
97
|
+
<a href="#M000012">file_system_file_types</a>
|
98
|
+
<a href="#M000013">matching_score</a>
|
99
|
+
<a href="#M000017">picture_format</a>
|
100
|
+
<a href="#M000016">picture_height</a>
|
101
|
+
<a href="#M000015">picture_width</a>
|
102
|
+
<a href="#M000014">to_picture</a>
|
103
103
|
</div>
|
104
104
|
</div>
|
105
105
|
|
@@ -119,13 +119,7 @@ generic class for a HI-RES picture
|
|
119
119
|
<tr class="top-aligned-row context-row">
|
120
120
|
<td class="context-item-name">HGR_BLACK</td>
|
121
121
|
<td>=</td>
|
122
|
-
<td class="context-item-value">PNG::Color::Black
|
123
|
-
<td width="3em"> </td>
|
124
|
-
<td class="context-item-desc">
|
125
|
-
colours cribbed from <a
|
126
|
-
href="http://groups.google.com.au/group/comp.sys.apple2/browse_thread/thread/b9aa36ead6935c42/faa0f4df3e89060f">groups.google.com.au/group/comp.sys.apple2/browse_thread/thread/b9aa36ead6935c42/faa0f4df3e89060f</a>
|
127
|
-
|
128
|
-
</td>
|
122
|
+
<td class="context-item-value">PNG::Color::Black #color=0,4</td>
|
129
123
|
</tr>
|
130
124
|
<tr class="top-aligned-row context-row">
|
131
125
|
<td class="context-item-name">HGR_GREEN</td>
|
@@ -140,7 +134,7 @@ href="http://groups.google.com.au/group/comp.sys.apple2/browse_thread/thread/b9a
|
|
140
134
|
<tr class="top-aligned-row context-row">
|
141
135
|
<td class="context-item-name">HGR_WHITE</td>
|
142
136
|
<td>=</td>
|
143
|
-
<td class="context-item-value">PNG::Color::White
|
137
|
+
<td class="context-item-value">PNG::Color::White #color=3,7</td>
|
144
138
|
</tr>
|
145
139
|
<tr class="top-aligned-row context-row">
|
146
140
|
<td class="context-item-name">HGR_ORANGE</td>
|
@@ -175,12 +169,12 @@ href="http://groups.google.com.au/group/comp.sys.apple2/browse_thread/thread/b9a
|
|
175
169
|
<div id="methods">
|
176
170
|
<h3 class="section-bar">Public Class methods</h3>
|
177
171
|
|
178
|
-
<div id="method-
|
179
|
-
<a name="
|
172
|
+
<div id="method-M000012" class="method-detail">
|
173
|
+
<a name="M000012"></a>
|
180
174
|
|
181
175
|
<div class="method-heading">
|
182
|
-
<a href="AppleHiResPic.src/
|
183
|
-
onclick="popupCode('AppleHiResPic.src/
|
176
|
+
<a href="AppleHiResPic.src/M000012.html" target="Code" class="method-signature"
|
177
|
+
onclick="popupCode('AppleHiResPic.src/M000012.html');return false;">
|
184
178
|
<span class="method-name">file_system_file_types</span><span class="method-args">()</span>
|
185
179
|
</a>
|
186
180
|
</div>
|
@@ -192,12 +186,12 @@ should be a subclass for each file system
|
|
192
186
|
</div>
|
193
187
|
</div>
|
194
188
|
|
195
|
-
<div id="method-
|
196
|
-
<a name="
|
189
|
+
<div id="method-M000013" class="method-detail">
|
190
|
+
<a name="M000013"></a>
|
197
191
|
|
198
192
|
<div class="method-heading">
|
199
|
-
<a href="AppleHiResPic.src/
|
200
|
-
onclick="popupCode('AppleHiResPic.src/
|
193
|
+
<a href="AppleHiResPic.src/M000013.html" target="Code" class="method-signature"
|
194
|
+
onclick="popupCode('AppleHiResPic.src/M000013.html');return false;">
|
201
195
|
<span class="method-name">matching_score</span><span class="method-args">()</span>
|
202
196
|
</a>
|
203
197
|
</div>
|
@@ -208,12 +202,12 @@ should be a subclass for each file system
|
|
208
202
|
|
209
203
|
<h3 class="section-bar">Public Instance methods</h3>
|
210
204
|
|
211
|
-
<div id="method-
|
212
|
-
<a name="
|
205
|
+
<div id="method-M000017" class="method-detail">
|
206
|
+
<a name="M000017"></a>
|
213
207
|
|
214
208
|
<div class="method-heading">
|
215
|
-
<a href="AppleHiResPic.src/
|
216
|
-
onclick="popupCode('AppleHiResPic.src/
|
209
|
+
<a href="AppleHiResPic.src/M000017.html" target="Code" class="method-signature"
|
210
|
+
onclick="popupCode('AppleHiResPic.src/M000017.html');return false;">
|
217
211
|
<span class="method-name">picture_format</span><span class="method-args">()</span>
|
218
212
|
</a>
|
219
213
|
</div>
|
@@ -222,12 +216,12 @@ should be a subclass for each file system
|
|
222
216
|
</div>
|
223
217
|
</div>
|
224
218
|
|
225
|
-
<div id="method-
|
226
|
-
<a name="
|
219
|
+
<div id="method-M000016" class="method-detail">
|
220
|
+
<a name="M000016"></a>
|
227
221
|
|
228
222
|
<div class="method-heading">
|
229
|
-
<a href="AppleHiResPic.src/
|
230
|
-
onclick="popupCode('AppleHiResPic.src/
|
223
|
+
<a href="AppleHiResPic.src/M000016.html" target="Code" class="method-signature"
|
224
|
+
onclick="popupCode('AppleHiResPic.src/M000016.html');return false;">
|
231
225
|
<span class="method-name">picture_height</span><span class="method-args">()</span>
|
232
226
|
</a>
|
233
227
|
</div>
|
@@ -236,12 +230,12 @@ should be a subclass for each file system
|
|
236
230
|
</div>
|
237
231
|
</div>
|
238
232
|
|
239
|
-
<div id="method-
|
240
|
-
<a name="
|
233
|
+
<div id="method-M000015" class="method-detail">
|
234
|
+
<a name="M000015"></a>
|
241
235
|
|
242
236
|
<div class="method-heading">
|
243
|
-
<a href="AppleHiResPic.src/
|
244
|
-
onclick="popupCode('AppleHiResPic.src/
|
237
|
+
<a href="AppleHiResPic.src/M000015.html" target="Code" class="method-signature"
|
238
|
+
onclick="popupCode('AppleHiResPic.src/M000015.html');return false;">
|
245
239
|
<span class="method-name">picture_width</span><span class="method-args">()</span>
|
246
240
|
</a>
|
247
241
|
</div>
|
@@ -250,12 +244,12 @@ should be a subclass for each file system
|
|
250
244
|
</div>
|
251
245
|
</div>
|
252
246
|
|
253
|
-
<div id="method-
|
254
|
-
<a name="
|
247
|
+
<div id="method-M000014" class="method-detail">
|
248
|
+
<a name="M000014"></a>
|
255
249
|
|
256
250
|
<div class="method-heading">
|
257
|
-
<a href="AppleHiResPic.src/
|
258
|
-
onclick="popupCode('AppleHiResPic.src/
|
251
|
+
<a href="AppleHiResPic.src/M000014.html" target="Code" class="method-signature"
|
252
|
+
onclick="popupCode('AppleHiResPic.src/M000014.html');return false;">
|
259
253
|
<span class="method-name">to_picture</span><span class="method-args">()</span>
|
260
254
|
</a>
|
261
255
|
</div>
|
@@ -0,0 +1,18 @@
|
|
1
|
+
<?xml version="1.0" encoding="iso-8859-1"?>
|
2
|
+
<!DOCTYPE html
|
3
|
+
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
4
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
5
|
+
|
6
|
+
<html>
|
7
|
+
<head>
|
8
|
+
<title>file_system_file_types (AppleHiResPic)</title>
|
9
|
+
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
10
|
+
<link rel="stylesheet" href="../.././rdoc-style.css" type="text/css" media="screen" />
|
11
|
+
</head>
|
12
|
+
<body class="standalone-code">
|
13
|
+
<pre><span class="ruby-comment cmt"># File lib/native_file_types/apple2/AppleHiResPic.rb, line 12</span>
|
14
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">file_system_file_types</span>
|
15
|
+
{}
|
16
|
+
<span class="ruby-keyword kw">end</span></pre>
|
17
|
+
</body>
|
18
|
+
</html>
|
@@ -0,0 +1,18 @@
|
|
1
|
+
<?xml version="1.0" encoding="iso-8859-1"?>
|
2
|
+
<!DOCTYPE html
|
3
|
+
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
4
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
5
|
+
|
6
|
+
<html>
|
7
|
+
<head>
|
8
|
+
<title>matching_score (AppleHiResPic)</title>
|
9
|
+
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
10
|
+
<link rel="stylesheet" href="../.././rdoc-style.css" type="text/css" media="screen" />
|
11
|
+
</head>
|
12
|
+
<body class="standalone-code">
|
13
|
+
<pre><span class="ruby-comment cmt"># File lib/native_file_types/apple2/AppleHiResPic.rb, line 53</span>
|
14
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">matching_score</span>
|
15
|
+
[<span class="ruby-constant">AppleBinary</span>.<span class="ruby-identifier">matching_score</span><span class="ruby-operator">+</span><span class="ruby-value">1</span>,<span class="ruby-constant">NADOLFile</span>.<span class="ruby-identifier">matching_score</span><span class="ruby-operator">+</span><span class="ruby-value">1</span>].<span class="ruby-identifier">max</span>
|
16
|
+
<span class="ruby-keyword kw">end</span></pre>
|
17
|
+
</body>
|
18
|
+
</html>
|
@@ -0,0 +1,53 @@
|
|
1
|
+
<?xml version="1.0" encoding="iso-8859-1"?>
|
2
|
+
<!DOCTYPE html
|
3
|
+
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
4
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
5
|
+
|
6
|
+
<html>
|
7
|
+
<head>
|
8
|
+
<title>to_picture (AppleHiResPic)</title>
|
9
|
+
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
10
|
+
<link rel="stylesheet" href="../.././rdoc-style.css" type="text/css" media="screen" />
|
11
|
+
</head>
|
12
|
+
<body class="standalone-code">
|
13
|
+
<pre><span class="ruby-comment cmt"># File lib/native_file_types/apple2/AppleHiResPic.rb, line 57</span>
|
14
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">to_picture</span>
|
15
|
+
<span class="ruby-identifier">buffer</span>=<span class="ruby-identifier">unpacked_picture_bytes</span>
|
16
|
+
<span class="ruby-identifier">canvas</span> = <span class="ruby-constant">PNG</span><span class="ruby-operator">::</span><span class="ruby-constant">Canvas</span>.<span class="ruby-identifier">new</span> <span class="ruby-constant">HGR_COLS</span>, <span class="ruby-constant">HGR_ROWS</span>, <span class="ruby-constant">PNG</span><span class="ruby-operator">::</span><span class="ruby-constant">Color</span><span class="ruby-operator">::</span><span class="ruby-constant">Black</span>
|
17
|
+
<span class="ruby-constant">HGR_ROWS</span>.<span class="ruby-identifier">times</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">y</span><span class="ruby-operator">|</span>
|
18
|
+
<span class="ruby-identifier">last_bit_set</span>=<span class="ruby-keyword kw">false</span>
|
19
|
+
<span class="ruby-value">40</span>.<span class="ruby-identifier">times</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">x_byte</span><span class="ruby-operator">|</span>
|
20
|
+
<span class="ruby-identifier">offset</span>=<span class="ruby-ivar">@@scanline_offsets</span>[<span class="ruby-identifier">y</span>]<span class="ruby-operator">+</span><span class="ruby-identifier">x_byte</span>
|
21
|
+
<span class="ruby-identifier">current_byte</span>=<span class="ruby-identifier">buffer</span>[<span class="ruby-identifier">offset</span>]
|
22
|
+
<span class="ruby-identifier">current_byte</span>=<span class="ruby-value">0</span> <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">current_byte</span>.<span class="ruby-identifier">nil?</span> <span class="ruby-comment cmt">#if we overrun the buffer then assume it's black</span>
|
23
|
+
<span class="ruby-value">7</span>.<span class="ruby-identifier">times</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">x_bit</span><span class="ruby-operator">|</span>
|
24
|
+
<span class="ruby-identifier">x</span>=<span class="ruby-identifier">x_byte</span><span class="ruby-operator">*</span><span class="ruby-value">7</span><span class="ruby-operator">+</span><span class="ruby-identifier">x_bit</span>
|
25
|
+
<span class="ruby-identifier">bit_set</span>=((<span class="ruby-identifier">current_byte</span> <span class="ruby-operator">&</span> (<span class="ruby-value">2</span><span class="ruby-operator">**</span><span class="ruby-identifier">x_bit</span>))<span class="ruby-operator">></span><span class="ruby-value">0</span>)
|
26
|
+
<span class="ruby-keyword kw">if</span> (<span class="ruby-identifier">bit_set</span>) <span class="ruby-keyword kw">then</span>
|
27
|
+
<span class="ruby-keyword kw">if</span> (<span class="ruby-identifier">last_bit_set</span>) <span class="ruby-keyword kw">then</span>
|
28
|
+
<span class="ruby-comment cmt">#adjacent pixels should both be white</span>
|
29
|
+
<span class="ruby-constant">AppleHiResPic</span>.<span class="ruby-identifier">set_pixel</span>(<span class="ruby-identifier">canvas</span>,<span class="ruby-identifier">x</span><span class="ruby-operator">-</span><span class="ruby-value">1</span>,<span class="ruby-identifier">y</span>,<span class="ruby-constant">HGR_WHITE</span>)
|
30
|
+
<span class="ruby-constant">AppleHiResPic</span>.<span class="ruby-identifier">set_pixel</span>(<span class="ruby-identifier">canvas</span>,<span class="ruby-identifier">x</span>,<span class="ruby-identifier">y</span>,<span class="ruby-constant">HGR_WHITE</span>)
|
31
|
+
<span class="ruby-keyword kw">else</span>
|
32
|
+
<span class="ruby-keyword kw">if</span> <span class="ruby-identifier">current_byte</span><span class="ruby-operator">>=</span><span class="ruby-value">0x80</span> <span class="ruby-keyword kw">then</span>
|
33
|
+
<span class="ruby-identifier">pallete</span>=[<span class="ruby-constant">HGR_BLUE</span>,<span class="ruby-constant">HGR_ORANGE</span>]
|
34
|
+
<span class="ruby-keyword kw">else</span>
|
35
|
+
<span class="ruby-identifier">pallete</span>=[<span class="ruby-constant">HGR_VIOLET</span>,<span class="ruby-constant">HGR_GREEN</span>]
|
36
|
+
<span class="ruby-keyword kw">end</span>
|
37
|
+
<span class="ruby-identifier">this_pixel_colour</span>=<span class="ruby-identifier">pallete</span>[<span class="ruby-identifier">x</span><span class="ruby-operator">%</span><span class="ruby-value">2</span>]
|
38
|
+
<span class="ruby-constant">AppleHiResPic</span>.<span class="ruby-identifier">set_pixel</span>(<span class="ruby-identifier">canvas</span>,<span class="ruby-identifier">x</span>,<span class="ruby-identifier">y</span>,<span class="ruby-identifier">this_pixel_colour</span>)
|
39
|
+
<span class="ruby-constant">AppleHiResPic</span>.<span class="ruby-identifier">set_pixel</span>(<span class="ruby-identifier">canvas</span>,<span class="ruby-identifier">x</span><span class="ruby-operator">+</span><span class="ruby-value">1</span>,<span class="ruby-identifier">y</span>,<span class="ruby-identifier">this_pixel_colour</span>) <span class="ruby-keyword kw">unless</span> <span class="ruby-identifier">x</span><span class="ruby-operator">>=</span><span class="ruby-constant">HGR_COLS</span><span class="ruby-operator">-</span><span class="ruby-value">1</span>
|
40
|
+
<span class="ruby-keyword kw">end</span>
|
41
|
+
<span class="ruby-keyword kw">end</span>
|
42
|
+
|
43
|
+
<span class="ruby-identifier">last_bit_set</span>=<span class="ruby-identifier">bit_set</span>
|
44
|
+
<span class="ruby-keyword kw">end</span>
|
45
|
+
<span class="ruby-keyword kw">end</span>
|
46
|
+
<span class="ruby-keyword kw">end</span>
|
47
|
+
|
48
|
+
<span class="ruby-identifier">png</span> = <span class="ruby-constant">PNG</span>.<span class="ruby-identifier">new</span> <span class="ruby-identifier">canvas</span>
|
49
|
+
<span class="ruby-identifier">result</span>=<span class="ruby-identifier">png</span>.<span class="ruby-identifier">raw_bytes</span>
|
50
|
+
<span class="ruby-identifier">result</span>
|
51
|
+
<span class="ruby-keyword kw">end</span></pre>
|
52
|
+
</body>
|
53
|
+
</html>
|
@@ -0,0 +1,18 @@
|
|
1
|
+
<?xml version="1.0" encoding="iso-8859-1"?>
|
2
|
+
<!DOCTYPE html
|
3
|
+
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
4
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
5
|
+
|
6
|
+
<html>
|
7
|
+
<head>
|
8
|
+
<title>picture_width (AppleHiResPic)</title>
|
9
|
+
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
10
|
+
<link rel="stylesheet" href="../.././rdoc-style.css" type="text/css" media="screen" />
|
11
|
+
</head>
|
12
|
+
<body class="standalone-code">
|
13
|
+
<pre><span class="ruby-comment cmt"># File lib/native_file_types/apple2/AppleHiResPic.rb, line 96</span>
|
14
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">picture_width</span>
|
15
|
+
<span class="ruby-constant">HGR_COLS</span>
|
16
|
+
<span class="ruby-keyword kw">end</span></pre>
|
17
|
+
</body>
|
18
|
+
</html>
|
@@ -0,0 +1,18 @@
|
|
1
|
+
<?xml version="1.0" encoding="iso-8859-1"?>
|
2
|
+
<!DOCTYPE html
|
3
|
+
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
4
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
5
|
+
|
6
|
+
<html>
|
7
|
+
<head>
|
8
|
+
<title>picture_height (AppleHiResPic)</title>
|
9
|
+
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
10
|
+
<link rel="stylesheet" href="../.././rdoc-style.css" type="text/css" media="screen" />
|
11
|
+
</head>
|
12
|
+
<body class="standalone-code">
|
13
|
+
<pre><span class="ruby-comment cmt"># File lib/native_file_types/apple2/AppleHiResPic.rb, line 99</span>
|
14
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">picture_height</span>
|
15
|
+
<span class="ruby-constant">HGR_ROWS</span>
|
16
|
+
<span class="ruby-keyword kw">end</span></pre>
|
17
|
+
</body>
|
18
|
+
</html>
|
@@ -0,0 +1,18 @@
|
|
1
|
+
<?xml version="1.0" encoding="iso-8859-1"?>
|
2
|
+
<!DOCTYPE html
|
3
|
+
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
4
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
5
|
+
|
6
|
+
<html>
|
7
|
+
<head>
|
8
|
+
<title>picture_format (AppleHiResPic)</title>
|
9
|
+
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
10
|
+
<link rel="stylesheet" href="../.././rdoc-style.css" type="text/css" media="screen" />
|
11
|
+
</head>
|
12
|
+
<body class="standalone-code">
|
13
|
+
<pre><span class="ruby-comment cmt"># File lib/native_file_types/apple2/AppleHiResPic.rb, line 103</span>
|
14
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">picture_format</span>
|
15
|
+
<span class="ruby-identifier">:png</span>
|
16
|
+
<span class="ruby-keyword kw">end</span></pre>
|
17
|
+
</body>
|
18
|
+
</html>
|
@@ -0,0 +1,145 @@
|
|
1
|
+
<?xml version="1.0" encoding="iso-8859-1"?>
|
2
|
+
<!DOCTYPE html
|
3
|
+
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
4
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
5
|
+
|
6
|
+
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
|
7
|
+
<head>
|
8
|
+
<title>Class: AxePackedAppleDosPic</title>
|
9
|
+
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
10
|
+
<meta http-equiv="Content-Script-Type" content="text/javascript" />
|
11
|
+
<link rel="stylesheet" href=".././rdoc-style.css" type="text/css" media="screen" />
|
12
|
+
<script type="text/javascript">
|
13
|
+
// <![CDATA[
|
14
|
+
|
15
|
+
function popupCode( url ) {
|
16
|
+
window.open(url, "Code", "resizable=yes,scrollbars=yes,toolbar=no,status=no,height=150,width=400")
|
17
|
+
}
|
18
|
+
|
19
|
+
function toggleCode( id ) {
|
20
|
+
if ( document.getElementById )
|
21
|
+
elem = document.getElementById( id );
|
22
|
+
else if ( document.all )
|
23
|
+
elem = eval( "document.all." + id );
|
24
|
+
else
|
25
|
+
return false;
|
26
|
+
|
27
|
+
elemStyle = elem.style;
|
28
|
+
|
29
|
+
if ( elemStyle.display != "block" ) {
|
30
|
+
elemStyle.display = "block"
|
31
|
+
} else {
|
32
|
+
elemStyle.display = "none"
|
33
|
+
}
|
34
|
+
|
35
|
+
return true;
|
36
|
+
}
|
37
|
+
|
38
|
+
// Make codeblocks hidden by default
|
39
|
+
document.writeln( "<style type=\"text/css\">div.method-source-code { display: none }</style>" )
|
40
|
+
|
41
|
+
// ]]>
|
42
|
+
</script>
|
43
|
+
|
44
|
+
</head>
|
45
|
+
<body>
|
46
|
+
|
47
|
+
|
48
|
+
|
49
|
+
<div id="classHeader">
|
50
|
+
<table class="header-table">
|
51
|
+
<tr class="top-aligned-row">
|
52
|
+
<td><strong>Class</strong></td>
|
53
|
+
<td class="class-name-in-header">AxePackedAppleDosPic</td>
|
54
|
+
</tr>
|
55
|
+
<tr class="top-aligned-row">
|
56
|
+
<td><strong>In:</strong></td>
|
57
|
+
<td>
|
58
|
+
<a href="../files/lib/native_file_types/apple2/PackedHiResPicFormats_rb.html">
|
59
|
+
lib/native_file_types/apple2/PackedHiResPicFormats.rb
|
60
|
+
</a>
|
61
|
+
<br />
|
62
|
+
</td>
|
63
|
+
</tr>
|
64
|
+
|
65
|
+
<tr class="top-aligned-row">
|
66
|
+
<td><strong>Parent:</strong></td>
|
67
|
+
<td>
|
68
|
+
<a href="AppleDosPic.html">
|
69
|
+
AppleDosPic
|
70
|
+
</a>
|
71
|
+
</td>
|
72
|
+
</tr>
|
73
|
+
</table>
|
74
|
+
</div>
|
75
|
+
<!-- banner header -->
|
76
|
+
|
77
|
+
<div id="bodyContent">
|
78
|
+
|
79
|
+
|
80
|
+
|
81
|
+
<div id="contextContent">
|
82
|
+
|
83
|
+
<div id="description">
|
84
|
+
<p>
|
85
|
+
picture packed with "The Axe Packer"
|
86
|
+
</p>
|
87
|
+
|
88
|
+
</div>
|
89
|
+
|
90
|
+
|
91
|
+
</div>
|
92
|
+
|
93
|
+
<div id="method-list">
|
94
|
+
<h3 class="section-bar">Methods</h3>
|
95
|
+
|
96
|
+
<div class="name-list">
|
97
|
+
<a href="#M000010">unpacked_picture_bytes</a>
|
98
|
+
</div>
|
99
|
+
</div>
|
100
|
+
|
101
|
+
</div>
|
102
|
+
|
103
|
+
|
104
|
+
<!-- if includes -->
|
105
|
+
|
106
|
+
<div id="section">
|
107
|
+
|
108
|
+
|
109
|
+
|
110
|
+
|
111
|
+
|
112
|
+
|
113
|
+
|
114
|
+
|
115
|
+
<!-- if method_list -->
|
116
|
+
<div id="methods">
|
117
|
+
<h3 class="section-bar">Public Instance methods</h3>
|
118
|
+
|
119
|
+
<div id="method-M000010" class="method-detail">
|
120
|
+
<a name="M000010"></a>
|
121
|
+
|
122
|
+
<div class="method-heading">
|
123
|
+
<a href="AxePackedAppleDosPic.src/M000010.html" target="Code" class="method-signature"
|
124
|
+
onclick="popupCode('AxePackedAppleDosPic.src/M000010.html');return false;">
|
125
|
+
<span class="method-name">unpacked_picture_bytes</span><span class="method-args">()</span>
|
126
|
+
</a>
|
127
|
+
</div>
|
128
|
+
|
129
|
+
<div class="method-description">
|
130
|
+
</div>
|
131
|
+
</div>
|
132
|
+
|
133
|
+
|
134
|
+
</div>
|
135
|
+
|
136
|
+
|
137
|
+
</div>
|
138
|
+
|
139
|
+
|
140
|
+
<div id="validator-badges">
|
141
|
+
<p><small><a href="http://validator.w3.org/check/referer">[Validate]</a></small></p>
|
142
|
+
</div>
|
143
|
+
|
144
|
+
</body>
|
145
|
+
</html>
|
@@ -0,0 +1,59 @@
|
|
1
|
+
<?xml version="1.0" encoding="iso-8859-1"?>
|
2
|
+
<!DOCTYPE html
|
3
|
+
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
4
|
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
5
|
+
|
6
|
+
<html>
|
7
|
+
<head>
|
8
|
+
<title>unpacked_picture_bytes (AxePackedAppleDosPic)</title>
|
9
|
+
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
|
10
|
+
<link rel="stylesheet" href="../.././rdoc-style.css" type="text/css" media="screen" />
|
11
|
+
</head>
|
12
|
+
<body class="standalone-code">
|
13
|
+
<pre><span class="ruby-comment cmt"># File lib/native_file_types/apple2/PackedHiResPicFormats.rb, line 12</span>
|
14
|
+
<span class="ruby-keyword kw">def</span> <span class="ruby-identifier">unpacked_picture_bytes</span>
|
15
|
+
|
16
|
+
<span class="ruby-comment cmt"># puts @@scanline_offsets.length</span>
|
17
|
+
<span class="ruby-identifier">packed_buffer</span>=<span class="ruby-identifier">data_without_header</span>
|
18
|
+
<span class="ruby-identifier">unpacked_buffer</span>=<span class="ruby-value str">"\000"</span><span class="ruby-operator">*</span><span class="ruby-value">8192</span>
|
19
|
+
<span class="ruby-identifier">p</span>=<span class="ruby-value">0</span>
|
20
|
+
<span class="ruby-identifier">parity</span>=<span class="ruby-value">1</span>
|
21
|
+
<span class="ruby-identifier">row</span>=<span class="ruby-value">1</span>
|
22
|
+
<span class="ruby-identifier">column</span>=<span class="ruby-value">0</span>
|
23
|
+
<span class="ruby-identifier">done</span>=<span class="ruby-keyword kw">false</span>
|
24
|
+
<span class="ruby-keyword kw">while</span> <span class="ruby-operator">!</span><span class="ruby-identifier">done</span> <span class="ruby-keyword kw">do</span>
|
25
|
+
<span class="ruby-identifier">b</span>=<span class="ruby-identifier">packed_buffer</span>[<span class="ruby-identifier">p</span>]
|
26
|
+
<span class="ruby-keyword kw">if</span> <span class="ruby-identifier">b</span><span class="ruby-operator">==</span><span class="ruby-value">0</span> <span class="ruby-keyword kw">then</span>
|
27
|
+
<span class="ruby-identifier">run_length</span>=<span class="ruby-identifier">packed_buffer</span>[<span class="ruby-identifier">p</span><span class="ruby-operator">+</span><span class="ruby-value">1</span>]
|
28
|
+
<span class="ruby-identifier">colour</span>=<span class="ruby-identifier">packed_buffer</span>[<span class="ruby-identifier">p</span><span class="ruby-operator">+</span><span class="ruby-value">2</span>]
|
29
|
+
<span class="ruby-identifier">p</span><span class="ruby-operator">+=</span><span class="ruby-value">2</span>
|
30
|
+
<span class="ruby-keyword kw">else</span>
|
31
|
+
<span class="ruby-identifier">run_length</span>=<span class="ruby-value">1</span>
|
32
|
+
<span class="ruby-identifier">colour</span>=<span class="ruby-identifier">b</span>
|
33
|
+
<span class="ruby-keyword kw">end</span>
|
34
|
+
<span class="ruby-identifier">run_length</span>.<span class="ruby-identifier">times</span> <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">i</span><span class="ruby-operator">|</span>
|
35
|
+
<span class="ruby-identifier">destination_offset</span>=<span class="ruby-ivar">@@scanline_offsets</span>[<span class="ruby-identifier">row</span>]<span class="ruby-operator">+</span><span class="ruby-identifier">column</span>
|
36
|
+
<span class="ruby-identifier">unpacked_buffer</span>[<span class="ruby-identifier">destination_offset</span>]=<span class="ruby-identifier">colour</span>
|
37
|
+
<span class="ruby-identifier">row</span><span class="ruby-operator">+=</span><span class="ruby-value">2</span>
|
38
|
+
<span class="ruby-keyword kw">if</span> <span class="ruby-identifier">row</span><span class="ruby-operator">>=</span><span class="ruby-value">192</span> <span class="ruby-keyword kw">then</span>
|
39
|
+
<span class="ruby-identifier">row</span>=<span class="ruby-identifier">parity</span>
|
40
|
+
<span class="ruby-identifier">column</span><span class="ruby-operator">+=</span><span class="ruby-value">1</span>
|
41
|
+
<span class="ruby-keyword kw">if</span> <span class="ruby-identifier">column</span><span class="ruby-operator">>=</span><span class="ruby-value">40</span> <span class="ruby-keyword kw">then</span>
|
42
|
+
<span class="ruby-keyword kw">if</span> <span class="ruby-identifier">parity</span><span class="ruby-operator">==</span><span class="ruby-value">0</span> <span class="ruby-keyword kw">then</span>
|
43
|
+
<span class="ruby-identifier">done</span>=<span class="ruby-keyword kw">true</span>
|
44
|
+
<span class="ruby-keyword kw">else</span>
|
45
|
+
<span class="ruby-identifier">row</span>=<span class="ruby-value">0</span>
|
46
|
+
<span class="ruby-identifier">column</span>=<span class="ruby-value">0</span>
|
47
|
+
<span class="ruby-identifier">parity</span>=<span class="ruby-value">0</span>
|
48
|
+
<span class="ruby-keyword kw">end</span>
|
49
|
+
<span class="ruby-keyword kw">end</span>
|
50
|
+
<span class="ruby-keyword kw">end</span>
|
51
|
+
<span class="ruby-keyword kw">end</span>
|
52
|
+
<span class="ruby-identifier">p</span><span class="ruby-operator">+=</span><span class="ruby-value">1</span>
|
53
|
+
<span class="ruby-identifier">done</span>=<span class="ruby-keyword kw">true</span> <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">p</span><span class="ruby-operator">==</span><span class="ruby-identifier">packed_buffer</span>.<span class="ruby-identifier">length</span>
|
54
|
+
<span class="ruby-keyword kw">end</span>
|
55
|
+
|
56
|
+
<span class="ruby-identifier">unpacked_buffer</span>
|
57
|
+
<span class="ruby-keyword kw">end</span></pre>
|
58
|
+
</body>
|
59
|
+
</html>
|
@@ -55,8 +55,8 @@
|
|
55
55
|
<tr class="top-aligned-row">
|
56
56
|
<td><strong>In:</strong></td>
|
57
57
|
<td>
|
58
|
-
<a href="../files/test/
|
59
|
-
test/
|
58
|
+
<a href="../files/test/tc_apple_2_rb.html">
|
59
|
+
test/tc_apple_2.rb
|
60
60
|
</a>
|
61
61
|
<br />
|
62
62
|
</td>
|
@@ -86,7 +86,7 @@
|
|
86
86
|
<h3 class="section-bar">Methods</h3>
|
87
87
|
|
88
88
|
<div class="name-list">
|
89
|
-
<a href="#
|
89
|
+
<a href="#M000008">test_apple_2_images</a>
|
90
90
|
</div>
|
91
91
|
</div>
|
92
92
|
|
@@ -108,13 +108,13 @@
|
|
108
108
|
<div id="methods">
|
109
109
|
<h3 class="section-bar">Public Instance methods</h3>
|
110
110
|
|
111
|
-
<div id="method-
|
112
|
-
<a name="
|
111
|
+
<div id="method-M000008" class="method-detail">
|
112
|
+
<a name="M000008"></a>
|
113
113
|
|
114
114
|
<div class="method-heading">
|
115
|
-
<a href="ImageSniffing.src/
|
116
|
-
onclick="popupCode('ImageSniffing.src/
|
117
|
-
<span class="method-name">
|
115
|
+
<a href="ImageSniffing.src/M000008.html" target="Code" class="method-signature"
|
116
|
+
onclick="popupCode('ImageSniffing.src/M000008.html');return false;">
|
117
|
+
<span class="method-name">test_apple_2_images</span><span class="method-args">()</span>
|
118
118
|
</a>
|
119
119
|
</div>
|
120
120
|
|