pobieranie; pdf; ebook; download; do ÂściÂągnięcia
 
Cytat
Felicitas multos habet amicos - szczęście ma wielu przyjaciół.
Indeks Eddings_Dav D20021169 arteuza
 
  Witamy


[ Pobierz całość w formacie PDF ]

specifies a pulse width of the channel when generating a square wave.
V 1CORG / This register is the control register for the sound channel. It controls the type of
waveform as well as the synchronization mode. The enable bit for the channel is in
this register.
The following registers affect all three voice channels.
F LCNLO The least significant 3 bits of this register are the low order 3 bits of an 11 bit value
that controls the filter frequency.
FLCNHI This register contains the high order 8 bits of an 11 bit value that determines the filter
frequency.
MODVOL The filtering mode and the maximum volume for all three voice channels is controlled
by this register.
RESFLT This register contains the resonance value and the filter enables for all three channels
The last two registers used by the Sound Editor of a second. When the 16 bit value has been
are not SID registers but RAM locations. These decremented to $0000, the release sequence is in-
-egisters are treated as a 16 bit value that is used itiated for all three channels.
as a time counter. They are decremented every 1/60
SNDTM1 This is the low order 8 bits of a 16 bit value that determines the time in 1/60
second intervals before the release sequence is initiated.
SNDTM1+ 1 This is the high order 8 bits of a 16 bit value that determines the time in 1/60
second intervals before the release sequence is initiated.
45
By experimenting with different values in the greatly speed up the time it takes to polish a game,
registers, you will very quickly get a feel for what as the values for the sounds can be determined
effect different values have on the sound. Being able separately from the main program.
to specify the amount of time to play the sound can
/
46
Chapter 9
Creating Graphics
Up until now,this book has been primarily con- Before you sit down to enter graphics data, you
cerned with background information necessary for
should have a good idea of what you want the final
creating the program that will ultimately become
object to look like. You will need to know the
a game. This is certainly an important part of learn- graphics mode that you will be working in. Also,
ing to program a game, but by no means all of it.
you must decide what colors you are going to use.
Because a video game is an audio-visual experience, For instance, if you are using multicolored sprites,
it will be necessary to create the graphics data that
each sprite can have one color of its own and can
will be operated on by the program.
use 2 colors that are common to all the other sprites.
There are a number of methods that can be To ensure that you will have the proper colors
used to create and enter graphics information into available to you, it would wise to have decided
the computer. The method that you choose is pure- how all of the characters should look before you
ly a matter of personal preference. This chapter will start.
discuss a few of the options available to you when
Once you have chosen a graphics mode to work
it is time to create graphics data. Also, instructions in, you will be able to start drawing your characters.
for using the graphics utility programs in Appen- In Figs. 9-1 through 9-7 you will find some sample
dix C are given in this chapter.
graphics layout sheets. These sheets have a fine grid
that is proportional to the dimensions of a pixel on
HAND CODING GRAPHICS
the TV screen. The heavy grid is proportional to
At some point, you will probably be entering one character cell on the screen. There are 25 lines
graphics data into your machine by hand. As this of 40 characters each on the Commodore 64.
can be a very time consuming process, this section One thing that you should keep in mind when
will show you some techniques that may make your you are creating graphics for use on the Commodore
job a little easier. 64 is that it is often necessary to use more than one
47
Fig. 9-1. A grid showing character spaces and individual pixels.
48
Fig. 9-2. A grid showing character spaces and double-wide dots for multicolor modes.
49
Fig. 9-3. A grid showing character spaces.
50
pixel of a color on a line to guarantee that the pixel
can be seen on the television. Television sets were
not designed to be able to display drastic color
changes on adjacent pixels. Depending on your color
choices, a single pixel in an area of the screen may
not be seen. This is due to the time that it takes
the TV to turn on and off the appropriate electron
guns that brighten a pixel. If the TV does not have
enough time to adjust the guns, the pixel will have
just started to light when the beams are changed
for the next pixel. On the other hand, if you have
2 or more adjacent pixels on a line of the same col-
or, there will be enough time for the beams to be
readjusted and the pixels displayed.
The form in Fig. 9-1 is the form to use if you
are going to be using the standard bitmapped
graphics mode. You will notice
t each pixel is rec- be sure to modify your program to change the
tangular in shape, rather then sq re as might have
SPRXSZ and SPRYSZ registers to the size option
been expected. Thus, care must
taken when at- that you desire. The size of the grid on the sprite
tempting to draw geometric patterns on the screen.
form is identical to the grid on the other graphics
Since the pixels are rectangular, the normal equa- forms. This allows the sprites that you create to be
tions for generating geometric shapes do not hold
placed on top of your background graphics forms
true. However, if you take into account the 4/3
to see how the entire screen will look.
aspect ratio of the pixels, any shape can be drawn
Once you have translated your drawing into a
properly.
series of bytes, you have a couple of options as to
The form in Fig. 9-2 is to be used if you are go- what to do with the data. If you have a machine
ing to be using one of the multicolor modes for your
language monitor, you may choose to use the
graphics. You will notice that each pixel on this form
Memory Display option to display the range of
is twice as wide as the pixels on the form 9-1.This
memory where you would like your graphics data
is because it takes two bits to represent the four col- to go. At this point, your monitor should allow you
ors available to each block in the multicolor mode,
to change the data on the screen. By using the data
as opposed to the one bit that is needed to deter- from your drawings to modify the data on the
mine whether the foreground or background color
screen, you will create a section of memory that
will be used in the standard color mode. Once again,
represents your graphics. After you have finished
the pixels are not square, and care must be taken
entering the data into the monitor, be sure to save
when you are creating shapes.
the range of memory that you have just modified
The form in Fig. 9-3 is generally used to repre- to the disk. The next step is to enter the address
sent the screen in the character graphics mode. It
of your graphics into your program so that it can
also can be used as an overlay to represent one of
find the graphics later.
the color memory areas in the bitmapped graphics
Your other option is to enter the data into your
mode. [ Pobierz całość w formacie PDF ]

  • zanotowane.pl
  • doc.pisz.pl
  • pdf.pisz.pl
  • natalcia94.xlx.pl
  • comp
    IndeksCarolyn Faulkner Submissive Desires (pdf)MacLean Alistair (1975) CyrkAnne McCaffrey Cykl Planeta piratów (1) SassinakHot Nights 3 Make Me, Take Me Amanda Usen61 Weekend w Tokyo Darcy EmmaBrenden Laila Hannah 25 BezsilnośÂ›ć‡Hammond Rosemary M晜źczyzna nie w jej typieStrugaccy A. i B. Poniedzialek zaczyna sie w soboteGraham Heather Na zawsze, moja mićąĂ˘Â€ÂšoćąĂ˘Â€ĹźciMiernicki Sebastian Pan Samochodzik i ... Buzdygan hetmana Mazepy
  • zanotowane.pl
  • doc.pisz.pl
  • pdf.pisz.pl
  • annkula.pev.pl
  • Cytat

    Długi język ma krótkie nogi. Krzysztof Mętrak
    Historia kroczy dziwnymi grogami. Grecy uczyli się od Trojan, uciekinierzy z Troi założyli Rzym, a Rzymianie podbili Grecję, po to jednak, by przejąć jej kulturę. Erik Durschmied
    A cruce salus - z krzyża (pochodzi) zbawienie.
    A ten zwycięzcą, kto drugim da / Najwięcej światła od siebie! Adam Asnyk, Dzisiejszym idealistom
    Ja błędy popełniam nieustannie, ale uważam, że to jest nieuniknione i nie ma co się wobec tego napinać i kontrolować, bo przestanę być normalnym człowiekiem i ze spontanicznej osoby zmienię się w poprawną nauczycielkę. Jeżeli mam uczyć dalej, to pod warunkiem, że będę sobą, ze swoimi wszystkimi głupotami i mądrościami, wadami i zaletami. s. 87 Zofia Kucówna - Zdarzenia potoczne

    Valid HTML 4.01 Transitional

    Free website template provided by freeweblooks.com