Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - Hot_Dog

Pages: 1 ... 137 138 [139] 140 141 ... 194
2071
ASM / Re: Frequency and Channels of a Custom Sound
« on: August 18, 2010, 10:35:14 pm »
Well if it can be sped up or down, that's not an issue.  I don't care about the speed since most notes will repeat (in order to be held out) anyways.  After all, on computer midi, if you start with a single recorded note (like a piano note), the sound will run faster and faster the higher up you go.

2072
ASM / Re: Frequency and Channels of a Custom Sound
« on: August 18, 2010, 10:30:10 pm »
This also looks like an interesting topic.  I'm curious as well.  Thanks for asking a great question Hot Dog. ;D

Well, I'm tossing around the idea with having about 16 "midi" instruments and making music for S.A.D. for 15 Mhz calculators.  If I can't get enough channels and can't change single notes, however, it ain't going to happen

So you're planning to run this on top of a game? :O I'm not sure how possible this is when using all of the processing time.

Like I said, it's an idea I'm tossing around.  But if nobody knows if it's possible for many channels, as well as if it's possible to have a single recorded note and change pitch and duration...

* Hot Dog runs off to experiment

EDIT:  I'll keep up on this post as to what I find out, for those of you curious

2073
ASM / Re: Frequency and Channels of a Custom Sound
« on: August 18, 2010, 10:26:02 pm »
This also looks like an interesting topic.  I'm curious as well.  Thanks for asking a great question Hot Dog. ;D

Well, I'm tossing around the idea with having about 16 "midi" instruments and making music for S.A.D. for 15 Mhz calculators.  If I can't get enough channels and can't change single notes, however, it ain't going to happen

2074
ASM / Re: Frequency and Channels of a Custom Sound
« on: August 18, 2010, 10:23:41 pm »
It's actually 4-bit, I believe.

Alright, granted, but that still doesn't answer my questions 8)

EDIT:  At least the file sent and converted to a program is 8-bit

2075
ASM / Re: Frequency and Channels of a Custom Sound
« on: August 18, 2010, 10:17:17 pm »
Your routine is built to play how many bits per sample, and at what sample rate?

Well, it's not actually my routine.  But it is 11 Khz, 8-bit mono

2076
Escheron: Shadow over Ragnoth / Re: Escheron: Shadow over Ragnoth
« on: August 18, 2010, 08:01:43 pm »
Great job, Iambian!  I love the screenie!

2077
ASM / Re: Frequency and Channels of a Custom Sound
« on: August 18, 2010, 07:03:17 pm »
So are you wanting some sort of WAV playback, or do you want beeps?

WAV.  What I'm looking at is a recorded note (such as .1 seconds of violin, like they do with midi), and since the code above can play waves, I'm wondering if that note can be adjusted for length and pitch, and played in two or 4 channels.

2078
Sorry, I had to remove that link because it had the instructions for illegally downloading a ROM.  However, I uploaded the correct .pdf in the place where all the lessons can get downloaded.  Just go to lesson 4 downloads :)

2079
Quote
Also I sometimes notice references to your tutorials on other forums or IRC when someone asks what's a good ASM tutorial, plus your tutorials are downloaded quite often, so it tells you did an amazing job on them so far.

Dude, thanks for telling me that!  It was definitely my goal to make ASM easy to understand.

Unfortunately, though, the pdf for lesson 4 might not be up for some time.  It's low on my list of priorities :(

2080
Hi, guys,

This is the code I'm using to teach people how to draw any-size sprites:  (In this case, an OR routine)

Code: [Select]
Put_Sprite_OR:
; A = x coordinate
; L = y coordinate
; B = number of rows
; Sprite_Width holds the width of the sprite
; IX = address of sprite
    LD     H, 0
    LD     D, H
    LD     E, L
    ADD    HL, HL
    ADD    HL, DE
    ADD    HL, HL
    ADD    HL, HL

    LD     E, A
    SRL    E
    SRL    E
    SRL    E
    ADD    HL, DE

    LD     DE, plotsscreen
    ADD    HL, DE
   
   
    AND    7
    JR     Z, _AlignedOR

    LD     C, A
    PUSH HL
    LD A, 12
    LD HL, Sprite_Width
    SUB (HL)
    LD D,0
    LD E, A
    POP HL   
   
_RowLoopOR:

    PUSH   BC
   
    ;Stores width into B, which will be decreased 1 by 1 until one row is complete
    LD A, (Sprite_Width)
    LD B, A
   

_ColumnLoopOR:
    PUSH BC
       
    LD     B, C
    LD     C, (IX)
    OR    A

_ShiftLoopOR:
    SRL    C
    RRA
 
    DJNZ   _ShiftLoopOR
 

    INC    HL
    OR   (HL)
    LD     (HL), A

    DEC    HL
    LD     A, C
    OR    (HL)
    LD     (HL), A

    POP BC
    INC HL
    INC IX
 
    DJNZ _ColumnLoopOR
   
    ADD    HL, DE
   
    POP    BC
    DJNZ   _RowLoopOR
   
    RET

_AlignedOR:
   
    PUSH HL
    LD A, 12
    LD HL, Sprite_Width
    SUB (HL)
    LD D,0
    LD E, A
    POP HL 
     
_PutLoopOR:
    PUSH BC
    LD A, (Sprite_Width)
    LD B, A

_PutLoopOR2:
   
    LD     A, (IX)
    OR (HL)
    LD     (HL), A
    INC  IX
 
    INC HL
    DJNZ _PutLoopOR2
_PutLoopORAdd:
    POP BC
   

 ADD HL, DE
 DJNZ _PutLoopOR
    RET

But, even though it's important that someone knows about clipping sprites, I an unskilled in that area, and I need help knowing how to do it with this particular routine.  The thing is, it has to be for THIS routine because this is one that beginners up to this point can understand.

Thanks for any help you can offer

2081
Lesson 15 is now up.  You won't learn to input names yet, because I realized that the lesson was starting to get too long.

Now I'll be doing lesson 17, which teaches you how to draw sprites!  For all you eager beavers, that might come as soon as next week.

2083
ASM / Frequency and Channels of a Custom Sound
« on: August 18, 2010, 12:32:28 am »
For those of you who think you will laugh and point at me for asking a reasonable question, please leave immediately.

So, this is part of the code for PlayWav:

Code: [Select]
di           
 ld   a, 0FDh
 out  (01h), a 

main:
 ld   a, (hl)
 and  0Fh
 ld   c, a   
 call Label15
 ld   a, (hl)
 srl  a       
 srl  a       
 srl  a       
 srl  a       
 and  0Fh
 ld   c, a
 push iy
 pop  iy ;slow this down a little
 call Label15
 inc  hl     
 dec  de     
 ld   a, d   
 push iy ;slow this down a little
 pop  iy
 or   e       
 jr   nz,main
 ei         
 ret
         
quit:
 pop af
 pop af ;fix the stack
 pop af
 ret

Label15:
 ld   b, c   
 inc  b       
 ld   a, 0D3h

Label18:
 out  (00h), a 
 djnz Label18
 ld   a, 10h
 sub  c       
 ld   b, a   
 ld   a, 0D0h

Label19:
 out  (00h), a 
 djnz Label19
 ret

1. If I were to use a custom sound, one single recorded note, would it be possible to adjust the frequency and duration of that sound to allow more notes?
2. Would it be possible to have 2--or even 4--channels of said single recorded notes at said frequencies and durations?

I'm not asking for code (cause I have an idea of what I want to do), I'm just asking if it's reasonably possible.

2084
TI Z80 / Re: Star Fox
« on: August 17, 2010, 06:53:07 pm »
You know, if you were to enable music for this game, I could make a pretty sweet rendition of the Star Fox 64 Versus music :)

2085
Escheron: Shadow over Ragnoth / Re: Escheron: Shadow over Ragnoth
« on: August 17, 2010, 02:48:59 pm »
Sounds great, Iambian!  Keep up the good work!

* Hot Dog gives Iambian some cherries to give him strength during his project

Pages: 1 ... 137 138 [139] 140 141 ... 194