nueva tabla high nibble 2bpp
This commit is contained in:
parent
05e302a7d5
commit
5fb42f51de
|
@ -859,31 +859,34 @@ el dispositivo de pantalla tratará esta dirección como un sprite 2bpp cuando u
|
|||
|
||||
¡veamos cómo utilizar el sprite byte para dibujar tiles de 2bpp!
|
||||
|
||||
### sprite de nibble alto para 2bpp
|
||||
### nibble alto de sprite para 2bpp
|
||||
|
||||
el nibble alto para los sprites de 2bpp nos permitirá elegir la capa que queremos que se dibuje y la dirección de rotación.
|
||||
|
||||
los ocho valores posibles para este nibble son:
|
||||
|
||||
+ <table>
|
||||
+ <tr><th>nibble alto</th><th>capa</th><th>inv-y</th><th>inv-x</th></tr>
|
||||
+ <tr><td>8</td><td>plano de fondo</td><td>no</td><td>no</td></tr>
|
||||
+ <tr><td>9</td><td>plano de fondo</td><td>no</td><td>sí</td></tr>
|
||||
+ <tr><td>a</td><td>plano de fondo</td><td>sí</td><td>no</td></tr>
|
||||
+ <tr><td>b</td><td>plano de fondo</td><td>sí</td><td>sí</td></tr>
|
||||
+ <tr><td>c</td><td>primer plano</td><td>no</td><td>no</td></tr>
|
||||
+ <tr><td>d</td><td>primer plano</td><td>no</td><td>sí</td></tr>
|
||||
+ <tr><td>e</td><td>primer plano</td><td>sí</td><td>no</td></tr>
|
||||
+ <tr><td>f</td><td>primer plano</td><td>sí</td><td>sí</td></tr>
|
||||
+ <tr><th>sprite alto</th><th>capa</th><th>inv-y</th><th>inv-x</th></tr>
|
||||
+ <tr><td class="num">8</td><td>fn</td><td>no</td><td>no</td></tr>
|
||||
+ <tr><td class="num">9</td><td></td><td></td><td>sí</td></tr>
|
||||
+ <tr><td class="num">a</td><td></td><td>sí</td><td>no</td></tr>
|
||||
+ <tr><td class="num">b</td><td></td><td></td><td>sí</td></tr>
|
||||
+ <tr><td class="num">c</td><td>pp</td><td>no</td><td>no</td></tr>
|
||||
+ <tr><td class="num">d</td><td></td><td></td><td>sí</td></tr>
|
||||
+ <tr><td class="num">e</td><td></td><td>sí</td><td>no</td></tr>
|
||||
+ <tr><td class="num">f</td><td></td><td></td><td>sí</td></tr>
|
||||
+ </table>
|
||||
& * 8: dibujar un sprite de 2bpp en el fondo, con la orientación original
|
||||
& * 9: dibujar un sprite de 2bpp en el fondo, invertido horizontalmente
|
||||
& * a: dibujar un sprite 2bpp en el fondo, invertido verticalmente
|
||||
& * b: dibujar un sprite de 2bpp en el fondo, invertido horizontal y verticalmente
|
||||
& * c: dibujar un sprite de 2bpp en primer plano, con la orientación original
|
||||
& * d: dibujar un sprite de 2bpp en primer plano, invertido horizontalmente
|
||||
& * e: dibujar un sprite de 2bpp en primer plano, invertido verticalmente
|
||||
& * f: dibujar un sprite de 2bpp en primer plano, invertido horizontal y verticalmente
|
||||
& fondo:
|
||||
& * 8: dibujar un sprite de 2bpp, con la orientación original
|
||||
& * 9: dibujar un sprite de 2bpp, invertido horizontalmente
|
||||
& * a: dibujar un sprite 2bpp, invertido verticalmente
|
||||
& * b: dibujar un sprite de 2bpp, invertido horizontal y verticalmente
|
||||
&
|
||||
& primer plano:
|
||||
& * c: dibujar un sprite de 2bpp, con la orientación original
|
||||
& * d: dibujar un sprite de 2bpp, invertido horizontalmente
|
||||
& * e: dibujar un sprite de 2bpp, invertido verticalmente
|
||||
& * f: dibujar un sprite de 2bpp, invertido horizontal y verticalmente
|
||||
|
||||
notemos que estos ocho valores tienen todos un bit más a la izquierda en 1: este bit señala que vamos a dibujar un sprite de 2bpp. los otros tres bits del nibble se comportan como se ha descrito anteriormente en el caso de 1bpp.
|
||||
|
||||
|
|
|
@ -573,11 +573,11 @@ the eight possible values of the sprite high nibble, used for drawing a 1bpp spr
|
|||
|
||||
+ <table>
|
||||
+ <tr><th>sprite high</th><th>layer</th><th>flip-y</th><th>flip-x</th></tr>
|
||||
+ <tr><td class="num">0</td><td>bg</td><td>no</td><td>no</td></tr>
|
||||
+ <tr><td class="num">0</td><td>background</td><td>no</td><td>no</td></tr>
|
||||
+ <tr><td class="num">1</td><td></td><td></td><td>yes</td></tr>
|
||||
+ <tr><td class="num">2</td><td></td><td>yes</td><td>no</td></tr>
|
||||
+ <tr><td class="num">3</td><td></td><td></td><td>yes</td></tr>
|
||||
+ <tr><td class="num">4</td><td>fg</td><td>no</td><td>no</td></tr>
|
||||
+ <tr><td class="num">4</td><td>foreground</td><td>no</td><td>no</td></tr>
|
||||
+ <tr><td class="num">5</td><td></td><td></td><td>yes</td></tr>
|
||||
+ <tr><td class="num">6</td><td></td><td>yes</td><td>no</td></tr>
|
||||
+ <tr><td class="num">7</td><td></td><td></td><td>yes</td></tr>
|
||||
|
@ -590,7 +590,7 @@ the eight possible values of the sprite high nibble, used for drawing a 1bpp spr
|
|||
&
|
||||
& foreground:
|
||||
& * 4: draw a 1bpp sprite, original orientation
|
||||
& * 5: draw a 1bpp sprite, flipped horizontally
|
||||
& * 5: draw a 1bpp sprite, flipped horizontally
|
||||
& * 6: draw a 1bpp sprite, flipped vertically
|
||||
& * 7: draw a 1bpp sprite, flipped horizontally and vertically
|
||||
|
||||
|
@ -866,24 +866,27 @@ the high nibble for 2bpp sprites will allow us to choose the layer we want it to
|
|||
the eight possible values for this nibble are:
|
||||
|
||||
+ <table>
|
||||
+ <tr><th>high nibble</th><th>layer</th><th>flip-y</th><th>flip-x</th></tr>
|
||||
+ <tr><td>8</td><td>background</td><td>no</td><td>no</td></tr>
|
||||
+ <tr><td>9</td><td>background</td><td>no</td><td>yes</td></tr>
|
||||
+ <tr><td>a</td><td>background</td><td>yes</td><td>no</td></tr>
|
||||
+ <tr><td>b</td><td>background</td><td>yes</td><td>yes</td></tr>
|
||||
+ <tr><td>c</td><td>foreground</td><td>no</td><td>no</td></tr>
|
||||
+ <tr><td>d</td><td>foreground</td><td>no</td><td>yes</td></tr>
|
||||
+ <tr><td>e</td><td>foreground</td><td>yes</td><td>no</td></tr>
|
||||
+ <tr><td>f</td><td>foreground</td><td>yes</td><td>yes</td></tr>
|
||||
+ <tr><th>sprite high</th><th>layer</th><th>flip-y</th><th>flip-x</th></tr>
|
||||
+ <tr><td class="num">8</td><td>background</td><td>no</td><td>no</td></tr>
|
||||
+ <tr><td class="num">9</td><td></td><td></td><td>yes</td></tr>
|
||||
+ <tr><td class="num">a</td><td></td><td>yes</td><td>no</td></tr>
|
||||
+ <tr><td class="num">b</td><td></td><td></td><td>yes</td></tr>
|
||||
+ <tr><td class="num">c</td><td>foreground</td><td>no</td><td>no</td></tr>
|
||||
+ <tr><td class="num">d</td><td></td><td></td><td>yes</td></tr>
|
||||
+ <tr><td class="num">e</td><td></td><td>yes</td><td>no</td></tr>
|
||||
+ <tr><td class="num">f</td><td></td><td></td><td>yes</td></tr>
|
||||
+ </table>
|
||||
& * 8: draw a 2bpp sprite in the background, original orientation
|
||||
& * 9: draw a 2bpp sprite in the background, flipped horizontally
|
||||
& * a: draw a 2bpp sprite in the background, flipped vertically
|
||||
& * b: draw a 2bpp sprite in the background, flipped horizontally and vertically
|
||||
& * c: draw a 2bpp sprite in the foreground, original orientation
|
||||
& * d: draw a 2bpp sprite in the foreground, flipped horizontally
|
||||
& * e: draw a 2bpp sprite in the foreground, flipped vertically
|
||||
& * f: draw a 2bpp sprite in the foreground, flipped horizontally and vertically
|
||||
& background:
|
||||
& * 8: draw a 2bpp sprite, original orientation
|
||||
& * 9: draw a 2bpp sprite, flipped horizontally
|
||||
& * a: draw a 2bpp sprite, flipped vertically
|
||||
& * b: draw a 2bpp sprite, flipped horizontally and vertically
|
||||
&
|
||||
& foreground:
|
||||
& * c: draw a 2bpp sprite, original orientation
|
||||
& * d: draw a 2bpp sprite, flipped horizontally
|
||||
& * e: draw a 2bpp sprite, flipped vertically
|
||||
& * f: draw a 2bpp sprite, flipped horizontally and vertically
|
||||
|
||||
note that these eight values all have a leftmost bit in 1: this bit signals that we will be drawing a 2bpp sprite. the other three bits of the nibble behave as described above in the 1bpp case.
|
||||
|
||||
|
|
Loading…
Reference in New Issue