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.


Topics - squidgetx

Pages: [1] 2 3 ... 9
1
Music Showcase / new tracks by squid
« on: May 25, 2014, 11:45:06 pm »
Hey guys, it's been a while but I thought I'd share some new tracks I've been working on as of late, I'm learning more and more about the different DAWs and some basic electronic instrument effects.


737: playing with a mixylodian scale and some water drop samples
No Change: filters, woo. Four Tet inspired mathrock-IDM-house track
Shirley: messing around with a friends' voice and the sounds of my feet in the hallway
Clouds: featuring my friends' spoken word poetry, turned out OK.
El Viento: root-5th-root-5th-root-7th is the best pattern ever


Feedback and criticism more than welcome!

2
The Axe Parser Project / MOVED: Flappy Bird in Axe !
« on: February 17, 2014, 03:33:49 pm »
This topic has been moved to TI Z80 Calculator Projects.

http://ourl.ca/20702

3
TI Z80 / AxeSynth 2.0
« on: February 16, 2014, 11:53:14 pm »
Hey everybody~ (It's been a while, hasn't it?)

Life has been really busy with university and things, however I think I've found a project that has sparked my interest and will keep me a bit more occupied/active in the next few weeks. I'm aiming to dramatically expand my Axe sound synthesizer, AxeSynth to a (sort of) full on Digital Audio Workstation for the 83+/84+ series.

Planned features:
-Drum hits (kick, snare, and hi hat, all with customizable parameters)
-Clip editing mode; allows for editing and saving of series' of notes, rests, or drum hits.
-Clip launching mode; playback/looping of recorded clips

Completed so far:
Diving back into the code, refamiliaraizing myself, and updating to Axe 1.2.1 standards (Yes, I know that 1.2.2 is out)
Bugfixes
Improving flow/modularity
Ok sounding kick
Decent sounding snare

4
In class (scheme) we recently learned about the syntax that allows a function to take an arbitrary amount of arguments eg;
Code: [Select]
(define len
  (lambda args
    (length args)))

>(len 1 2 3)
3
What are the advantages of using this form over simply passing the arguments as a single list in the first place? How do you even pass arguments to these kinds of functions within a program (and not on the command line)? Is there a way to make a procedure that returns a series of values that aren't wrapped within a list?

5
Other / Yaad yet another Dropbox: copy.com
« on: June 04, 2013, 02:42:50 pm »
I'm always on the lookout for more and more cloud storage services, well because they're free and fun to have insane amounts of space if I ever need it. Anyway copy.com just launched recently and they're offering 15gb free with 5gb for referrals- for both referrer and referree- making total 20gb if you use this link or if you only want 15gb you can go through copy.com and not give me anything, your call.

The iOS app looks great and well designed although it looks like it doesn't yet support instant uploads of photos/videos. The desktop client, while I haven't yet installed it, looks similar to Google Drive and Dropbox has and the same functionality of having a Copy Folder that syncs its content automatically. Have yet to see if it supports previous version function though.

6
Ash: Phoenix / Optimization help [A:P]
« on: January 26, 2013, 10:59:48 pm »
If anyone wants to take a crack at optimizing any of these routines, I'd be very grateful ;D. I've gone over them a few times, but haven't been able to get too much out of 'em.
Custom Menu Routine
Code: [Select]
:Lbl CMen
.Creates a menu and returns the int index of the value chosen, returns -1 if canceled with Alpha
.r1-X, r2-Y, r3- NUM OPTIONS,r4 longest entry length, r5 pointer to string data for choices, broken by 0's
:0→F
:41→K
:r1→A
:r2→B
:r3→C*7+4→r6
:r4→D*4+10→r3
:r6→r4
:Box()   \\box drawing routine that takes similar arguments to Rect
:B+3→r2
:r5→E→r3
:For(C)
:¦ A+8→r1
:¦ CText()  \\custom text routine, same argument format as text().
:¦ r2+7→r2  \\r2 is untouched in the routine, the x coord at the end of the text drawn returns at r1
:¦ r3++
:End
:Text(B+2*256+A+4→A+4)
:While 1
:¦ !If +6
:¦ ReturnEFFFF
:End
:If K
:=1-(K=4)+F
:!If +1
:+1
:End
:min(-1,C-1)→F
:{E86D7}-4→{E86D7}
:DrawF "   "
:Text(F*7*256+A)
:DrawF Str1P
:Else
:Delay()
:End
:DispGraphrr
:End!If getKey→K-54
:ReturnF
Custom decimal drawing routine
Code: [Select]
:Lbl CDec
.custom decimal drawing routine, arguments X,Y,Num
:.E0504→{E8251}r
:!If r3
:16
:CChar()
:Return
:End
:r3/10000→{E8452}
:r3/10/10/10^10→{E8453}
:r3/10/10^10→{E8454}
:r3/10^10→{E8455}
:r3^10→{E8456}
:0→{E8457}
:E8452→r3
:For(5)
:¦ If {r3}
:¦ !If {E8457}
:¦ 1→{E8457}
:End
:End
:If {E8457}
:{r3}+16
:CChar()
:End
:r3++
:End
:Return
Scrolling list implementation
Code: [Select]
:Lbl ItemS
:.SELECT ITEMS
.creates a scrolling menu, A is the visible offset of the cursor, B is the offset of the window
.r1 is the argument for starting value of the cursor
.oItem points to the beginning of item data which is in the format item ID, quantity
:If r1>5
:r1/6*6→B
:r1^6→A
:Else
:r1→A
:0→B
:End
:PrepI() \\prepares for dealing with items (just a getcalc call)
:41→K
:length(oItem)→L
:While 1
:¦ !If +6
:¦ Return‾1
:End
:If +48
:Box(30,0,66,40)
:3→r2
:B*2+oItem→F
:For(E,0,5)
:¦ If {F}→r1
:¦ GetI() \\copies item information using r1 to L5+e20
:¦ L5+E20→r3  \\this is the name of the item
:¦ CText(40)
:¦ Text(r2-1*256+84)
:¦ DrawF "x"
:¦ DrawF {F+1}►Dec \\quantity of item
:¦ Else
:¦ Str0N→r3
:¦ CText(40)
:End
:r2+7→r2
:F+2→F
:End
:
:!If K-1
:A++
:!If -5
:4→A
:If A+E≤L
:B++
:End
:End
:End
:!If K-4
:A--
:!If +1
:→A
:B--
:!If +1
:→B
:End
:End
:End
:
:Text(A*7+2*256+34)
:DrawF Str1P
:
:InfI({A+B*2+oItem}) \\displays information about the item in another box
:Else
:Delay()
:End
:
:DispGraphrr
:End!If getKey→K-54
:A+B+1
:Return
Size over speed tilemapper (only used to draw starting images)
Code: [Select]
:Lbl DrawM
.basic tilemapper, I care nothing about speed here, go for size. Draw1 is just a routine to draw a 12x12 bitmap in grayscale
.Y1 is tiles
.x, y char offset is 4,3
:ClrDrawrr
:.DRAW MAP θ=MAPFILE PTR
:‾8→T
:PY-3*48+θ+PX-4→F
:For(B,0,5)
:¦ For(A,0,8)
:¦ ¦ conj({F+A}*48+Y1,L1,48)
:¦ ¦
:¦ ¦ Draw1(A*4*3,T,L1)
:¦ End
:¦ T+12→T
:¦ F+48→F
:End
Asm 16x16 4level gray mask routine
Code: [Select]
#include "Axe.inc"

.db $00,$00


mask16:
;Grayscale mask command with 16x16 sprites

;Masked Sprite Format
;3 layers, 12x16
;Mask applied to both buffers
;Front Buffer
;Back Buffer
;SpritePointer always $8528
;byte to draw axv_R2 (X + y*12*12 + 48)
;aligned/unaligned by 4px axv_R1 0 or 1
ld hl,(axv_R1)
ld b,l
xor a \ cp b
jr z, draw
ld hl,$8528
ld b, 16
shiftMask:
ld a, $FF
rrd \ inc hl
rrd \ inc hl
djnz shiftMask
ld b, 32
xor a
shiftSprites:
rrd \ inc hl
rrd \ inc hl
djnz shiftSprites

draw:
ld hl,$9340 ;drawposition in hl
ld ix,$8528 ;sprite mask pointer
ld de,(axv_R2)
add hl, de
ld b,16
ld de, 11
drawFront:

ld a, (ix)
and (hl)
or (ix+32)
ld (hl), a
inc hl
inc ix

ld a, (ix)
and (hl)
or (ix+32)
ld (hl), a
add hl,de
inc ix

djnz drawFront


ld hl,$9872 ;reset registers
ld ix,$8528
ld de,(axv_R2)
add hl, de
ld b, 16
ld de,11
drawBack:
ld a, (ix)
and (hl)
or (ix+64)
ld (hl), a
inc hl
inc ix

ld a, (ix)
and (hl)
or (ix+64)
ld (hl), a
add hl,de
inc ix

djnz drawBack
Edit: one more, the map loading code. Seems like this could be cleaned up quite a bit
Code: [Select]
:Lbl LoadM
.Loads a map into theta using OverY and OverX coordinates
.24x24 tilemap for overX, overY coords storted at theta+2304
:OverY*24+OverX+θ+2304→r6
:.LOAD WARPS,NPCs,ETC
:conj({}-1*32+Y2,L5,32) \\load map information into L5
:{L5+E1E}r→A
:If {L5+E17}*5→B
:conj(Y2+A,E8000,B)
:End
:E8000+B→Ptrg
:A+B→A
:If {L5+E18}*4→B
:conj(A+Y2,Ptrg,B)
:End
:Ptrg+B→Pwrp
:A+B→A
:If {L5+E19}*6→B
:conj(A+Y2,Pwrp,B)
:
:End
:!If OverY
:Fill(θ,768,72)
:Else
:!If OverX
:
:FillM(θ) \\fill map with 16x16 square of 72s at theta
:Else
:DeCoM(r6-25,θ) \\decompress 16x16 map at r6-25 into theta
:End
:DeCoM(r6-24,θ+16)
:!If OverX-23
:FillM(θ+32)
:Else
:DeCoM(r6-23,θ+32)
:End
:End
:
:!If OverX
:FillM(θ+768)
:Else
:DeCoM(r6-1,θ+768)
:End
:DeCoM(r6,θ+768+16)
:!If OverX-23
:FillM(θ+768+32)
:Else
:DeCoM(r6+1,θ+768+32)
:End
:
:!If OverY-23
:Fill(θ+1536,768,72)
:Else
:!If OverX
:FillM(θ+1536)
:Else
:DeCoM(r6+23,θ+1536)
:End
:DeCoM(r6+24,θ+1536+16)
:!If OverX-23
:FillM(θ+1536+32)
:Else
:DeCoM(r6+25,θ+1536+32)
:End
:End
:Return

7
Java / passing a type?
« on: January 15, 2013, 09:19:24 pm »
I actually found a workaround for this problem, but I figured it's still worth asking about. Basically, I'm wondering if it's possible to pass an object type as an argument to a function. How do you do it? And is it considered good/bad practice?

8
Axe / MOVED: News Rpg game
« on: January 09, 2013, 07:47:36 pm »
This topic has been moved to TI Z80 Calculator Projects.

http://ourl.ca/18128

9
Computer Usage and Setup Help / Linux Mint help- driver issue?
« on: January 07, 2013, 11:14:28 am »
Hi everyone,

Today I installed HL2 via wine and while it does run, it is unusably slow and the audio stutters a lot. On my WinXP partition however, it works more or less fine. I'm suspecting that Mint is not correctly identifying my old integrated crappy graphics card.

System Information:
Mint 13 MATE
Pentium 4 2.8GHz
1gb RAM

Relevant LSPCI output:
Code: [Select]
*-pci
          description: Host bridge
          product: 82915G/P/GV/GL/PL/910GL Memory Controller Hub
          vendor: Intel Corporation
          physical id: 100
          bus info: [email protected]:00:00.0
          version: 04
          width: 32 bits
          clock: 33MHz
          configuration: driver=agpgart-intel
          resources: irq:0
        *-display:0
             description: VGA compatible controller
             product: 82915G/GV/910GL Integrated Graphics Controller
             vendor: Intel Corporation
             physical id: 2
             bus info: [email protected]:00:02.0
             version: 04
             width: 32 bits
             clock: 33MHz
             capabilities: pm vga_controller bus_master cap_list rom
             configuration: driver=i915 latency=0
             resources: irq:16 memory:cfe00000-cfe7ffff ioport:cc00(size=8) memory:d0000000-dfffffff memory:cfdc0000-cfdfffff
        *-display:1 UNCLAIMED
             description: Display controller
             product: 82915G Integrated Graphics Controller
             vendor: Intel Corporation
             physical id: 2.1
             bus info: [email protected]:00:02.1
             version: 04
             width: 32 bits
             clock: 33MHz
             capabilities: pm bus_master cap_list
             configuration: latency=0
             resources: memory:cfe80000-cfefffff
...

The UNCLAIMED display1 is what's getting me at thinking that the graphics driver might be the problem. I've been on Intel's website, and apt is telling me I have xserver-xorg-video intel all up to date. Is this a driver problem? If so, how can I fix it? If not, what else could it be?

Thanks in advance

10
Java / [solved] public variables and null pointers.
« on: December 27, 2012, 10:56:44 pm »
Ok, so here's my code basically. Normally I'd spend a bit more time trying to figure it out but I'll be away for the next couple days so I thought I could run it by you guys first :)


Code: [Select]
public class stuff {

public static Tile[] tileReference;
//a reference array to keep tile objects reference-able by tile number (this is a calc/computer project)
public static TileSelector tileContainer; //need to declare this outside of the main class so it can be accessed by other nested static classes in 'stuff'
...
public static class TileSelector extends JPanel {
..stuff
 public void paintComponent(Graphics g) {
  //initial drawing stuff
  for(int i =0; i<tileReference.length, i++)
   tileReference[i].drawTile(blah blah blah)
 }
}
...
public static void main(String[] args) {
...stuff initializing contents of tileReference
tileContainer = new TileSelector();
...
}
Right at that tileReference[].drawTile method I get a NullPointerException at runtime. In the main method, the first creation of a TileSelector occurs after I've initialized the contents of tileReference.

Does anybody have any ideas on how to get around this? If anyone has suggestions on how to better organize my code, I'm also welcome to that. I need tileReference[] to be accessible by many different methods and classes, and the instance tileContainer needs to be accessible by one other class (well to be specific, the active tile, which is encapsulated in the tileSelector class needs to be accessible. I suppose I could make that another instance of the main class "stuff" but i might run into complications, as mouse events in the tileSelector need to be able to modify the active tile. I might be ablet o give it a go but I'm not sure if that would solve the problem) .
* squidgetx is pretty new to oop, so feel free to also elaborate on the philosophical and practical differences between nested static and inner classes.

edit: solved on irc, thanks runer and jacobly

11
Ash: Phoenix / [A:P] Computer IDE
« on: December 24, 2012, 02:18:22 pm »
I've now made enough progress on this to start a thread on it. Basically, the goal of this side project is to be able to easily generate content for the game. Right now, warp tiles, NPC positions, items, moves and such have to be coded in by hand (ugh).

It's coded in Java, and so far I've got most of the drawing routines done, the GUI layout, and lots of asm/hex/int conversion routines written. Tilefile support is pretty much done, the tricky part is next going to be importing the map files.

Features list (planned, some implemented already)
-Tile Editor
--24x24 mode for creating large tiles as 4 12x12s
--Double click to edit tile
--Copy/Paste at least
-Map Editor
--Display of entire game map on the side for better map design
--Right click to add NPC, trigger, or warp
-Save and load as z80 source

12
News / Axe Omega 1.2.0 released
« on: November 22, 2012, 09:02:50 pm »
Happy Thanksgiving! (if you're into that)

It's been over six months since the last Axe update. Quigibo's activity began to decline, and soon Axe development seemed to have ground to a halt. However, management of the project has been temporarily passed to Runer112, an extremely proficient assembly and Axe coder and responsible for many of the optimizations now thought standard by the community and for many of the speedy routines you can find in Axe 1.1.2.

After a lot of work, Runer112 has released a fresh update. The original post can be found here.

Axe Parser
Omega 1.2.0



It's Thanksgiving, and this year, we can all give thanks for Axe living on! Just temporarily under new management. :)

New Features:
  • Have the need for speed? Using #ExprOn will request that all following code and called Axe routines be optimized for speed instead of size! Using #ExprOff does the reverse. Currently this only affects a few Axe routines (*, Pt-On(), Pt-Change(), DrawInv, Horizontal+/-, >Hex), but more will come! Axe Fusion always uses the fastest Axe routines available.
  • Continuing with the speed theme, DispGraphRecallPic has been added! It's the same as DispGraph and then RecallPic, but it's almost as fast as DispGraph alone.
  • Fixed point division! Syntax is: /*
  • Fixed point square! Syntax is: ²r
  • Labels and constant names can be up to 13 characters long!
  • No longer corrputs the OS when unlocking flash!
  • Even shinier commands list! BIG thanks to jacobly! I'm also trying to add size and speed data for everything; it's a work in progress, so please excuse errors/missing values for now.
  • Full support for big endian variables.
  • Signed min() and max(): just throw on an r.

Changed:
  • Better string parsing, including spelling out multi-character tokens, more reliable "var", and "grp" (w) is now "tmp"; these arbitrary-size variables will be automatically deleted on exiting.
  • Optimized most DispGraph variants: all but 4-level DispGraphClrDraw are smaller, which is larger because...
  • 4-level DispGraphClrDraw is about 15% faster. Also, 4-level DispGraph is about 5% faster.
  • Optimized >Hex, stdDev(), Horizontal-(EXPR), getKey(EXPR), -1, interrupts, and all archived variable routines slightly.
  • Optimized more stuff that I forgot.
  • nib{}r now always reads from the half of memory your code exists in.
  • inData(0,DATA) now returns 0, so no more adding 1 to all your key checks!
  • ln(0) now returns -1, it seems slightly more proper than 255.
  • Disp >Tok accepts the same argument type as Text >Tok.
  • Added "signed" equal and not equal operators.
  • Added optimizations for ^10, //0, and //-1, not that the latter two will ever be needed.
  • The A-theta variables have been moved, so L1 is now 768 bytes long by default.
  • When pointed into a variable in RAM, the Y1T and Y2T variables will be updated automatically if the variable is moved.
  • The X1T and X2T variables will act similarly when pointed into a VAT entry.
  • The X4T-Y6T variables have been added.
  • Slightly larger but faster multiplications by some large powers of 2.
  • Fixed a bug when a string displayed in an app went offscreen.
  • Fixed drawing sprites to arbitrary buffers.
  • Fixed rectangle clipping.
  • Fixed the size of the stdDev() subroutine.
  • Fixed some Axe fusion-related bugs.
  • Fixed some bugs with the token hook.
  • Fixed some bugs with comments.
  • Fixed some peephole optimization bugs.
  • Fixed a silly typo in an error message.
  • Fixed many errors in the command list.
  • Fixed many other bugs that I forgot about.
  • And probably introduced some bugs!


13
Axe / MOVED: sprite
« on: November 18, 2012, 11:46:24 am »
This topic has been moved to Pixel Art and Drawing.

http://ourl.ca/17520


14
This topic has been moved to General Calculator Help.

http://ourl.ca/17482

Pages: [1] 2 3 ... 9