Old 28th May 2003, 09:55   #1
sidd
Major Dude
 
sidd's Avatar
 
Join Date: May 2003
Location: Australia
Posts: 1,353
Variable Tracker For AVS!!!

w00t
roll-up roll-up

Thanks to nic01, magicX, jaheck and Unconed.
this whole thing was done in less than a day, those people have managed to help me out with some coding in the last few hours!
Attached Files
File Type: zip number.zip (970 Bytes, 212 views)
sidd is offline   Reply With Quote
Old 28th May 2003, 10:47   #2
Magic.X
Major Dude
 
Magic.X's Avatar
 
Join Date: Feb 2002
Location: Leipzig / Germany
Posts: 859
Here's a li'l remix, no big deal.

Cool idea Sid, just hardly usable. Dont have a clue where i'd need this except for a scorecounter within an avs game
Attached Files
File Type: zip number magic rmx.zip (1.3 KB, 182 views)


-=[The Ultimate VJ-Tool for AVS]=-

Hotlist 2.3 developement thread (old)
Magic.X is offline   Reply With Quote
Old 28th May 2003, 11:05   #3
UnConeD
Whacked Moderator
 
UnConeD's Avatar
 
Join Date: Jun 2001
Posts: 2,104
Why not improve it by floating the floating point? Use ex=log10(val)-.499999;ex=(abs(ex)%(abs(ex)+1))*sign(ex); to get the floating-point-shift. Though you might still want to leave the original behaviour in so that you can switch between 'fix' and 'sci' (like a real calculator).

Oh and I don't like the 9's with missing bottom stripe , change:
six=(equal(pval,0)+equal(pval,2)+equal(pval,3)+equal(pval,5)+equal(pval,6)+equal(pval,8)+equal(pval,9));
(though you should now invert it to speed it up)

Also, 'val=abs(val);' is run per-point, this can be put at the end of per-frame.
And finally, for that fancy LED-look, set line width to 2...

Anyway, it's very cool and compact, but is it useful?


It has turned up one thing though: AVS uses banker's rounding, which rounds N.5 to the nearest even number, rather than just all up/down. So 4.5 -> 4, but 5.5 -> 6. That proves by you have to use .4999 to force it to round down.

UnConeD is offline   Reply With Quote
Old 28th May 2003, 11:07   #4
sidd
Major Dude
 
sidd's Avatar
 
Join Date: May 2003
Location: Australia
Posts: 1,353
eh. its not meant to be good for presets and finished products..

its just useful when you have a crazy complicated code and you want to keep track of a variable.
nice remix.. you did that pretty quick
sidd is offline   Reply With Quote
Old 28th May 2003, 11:09   #5
UnConeD
Whacked Moderator
 
UnConeD's Avatar
 
Join Date: Jun 2001
Posts: 2,104
Sorry, I edited after you replied . Read again...

UnConeD is offline   Reply With Quote
Old 28th May 2003, 11:18   #6
sidd
Major Dude
 
sidd's Avatar
 
Join Date: May 2003
Location: Australia
Posts: 1,353
Lol, i do that all the time..

The floating point thing: i was going to do that, but got sick of fucking around. Thanks for the code, but i dont get it, so i dont know how to implement it. I had at one point started doing what you mentioned, i had flt=-1 as a floating float.

Thanks for the thing about the nine, i forgot about that.. btw, you managed to pick apart my coding prety quickely, even knowing the inverting thingo. fix of your fix:
six=1-(equal(pval,1)+equal(pval,4)+equal(pval,7));

I was going to ask you about that rounding thing, i got really confused by it.
sidd is offline   Reply With Quote
Old 28th May 2003, 11:55   #7
UnConeD
Whacked Moderator
 
UnConeD's Avatar
 
Join Date: Jun 2001
Posts: 2,104
Well in any case, you shouldn't expect any decent accuracy from AVS, as you can see from the readout itself . It seems the .49999 thing doesn't fix much for fractions, but only helps for integers.

Here's a version with dynamic point, but you can still toggle the old behaviour by setting fix=1 in init.

ex is the adjusting exponent (basically log10(abs(val)) rounded, but with signs and AVS-freaky rounding taken into account). flp is the dynamic point position, but wrapped so it never goes too far.

If you want to go extreme, you could program it for scientific notation 1.245e+10, but that's left as an exercise for the reader :P

PS: MagicX, you mean for e.g. an AVS pinball game?
Attached Files
File Type: zip number2.zip (989 Bytes, 177 views)


Last edited by UnConeD; 28th May 2003 at 12:16.
UnConeD is offline   Reply With Quote
Old 28th May 2003, 12:24   #8
Magic.X
Major Dude
 
Magic.X's Avatar
 
Join Date: Feb 2002
Location: Leipzig / Germany
Posts: 859
a PINBALL GAME! *drooooooooooooool*

Thats it! And possible too!!!

We need: an input field that grabs keyboard input prog

An ape that renders the paddles and requests the keystate from the input prog. And it renders the ball based on physics of a table and that scans for borders. If there is a border, the color defines the amount of bounce (like texer does point scanning)!

The rest can be done through scopes!

Unfortunately this is 2 sizes too big for my programming skills and would take a looong time to work out.

But it WILL work!

*droooooool*


-=[The Ultimate VJ-Tool for AVS]=-

Hotlist 2.3 developement thread (old)
Magic.X is offline   Reply With Quote
Old 28th May 2003, 12:29   #9
shreyas_potnis
Major Dude
 
shreyas_potnis's Avatar
 
Join Date: Jan 2003
Location: Mumbai, India
Posts: 787
Damn cool idea. I like the font of the numbers

http://home.iitb.ac*****~shreyaspotnis
shreyas_potnis is offline   Reply With Quote
Old 28th May 2003, 12:55   #10
sidd
Major Dude
 
sidd's Avatar
 
Join Date: May 2003
Location: Australia
Posts: 1,353
nice work, i came back on to post my fix, but it had already been done!

my version works like this. You set the number of decimals with 'dec' in init. Or, you set 'dec' to -1, which activates the dynamic floater, which works from the left.
i fixed up the nine aswell, and made the decimals easyer to read.

you can really see how bad that rounding glitch is, considering this example is just adding integers!.
Attached Files
File Type: zip tracker1.1.zip (1.1 KB, 163 views)
sidd is offline   Reply With Quote
Old 28th May 2003, 16:09   #11
Jaheckelsafar
Major Dude
 
Join Date: Feb 2002
Location: home
Posts: 1,318
Nice. I could have used this when making Goo Cube. I would have cleaned up soo many problems alto quicker than I did.

Stoke me a clipper. I'll be back for Christmas.

- Arnold Rimmer
Red Dwarf
Jaheckelsafar is offline   Reply With Quote
Old 28th May 2003, 20:44   #12
UnConeD
Whacked Moderator
 
UnConeD's Avatar
 
Join Date: Jun 2001
Posts: 2,104
Magic.X: who said anything about APEs?

UnConeD is offline   Reply With Quote
Old 18th June 2003, 11:43   #13
Magic.X
Major Dude
 
Magic.X's Avatar
 
Join Date: Feb 2002
Location: Leipzig / Germany
Posts: 859
[sorry for reviving but i have to]

UnConeD, you think this would work without any APE?

How would you realize the intput then?


-=[The Ultimate VJ-Tool for AVS]=-

Hotlist 2.3 developement thread (old)
Magic.X is offline   Reply With Quote
Old 18th June 2003, 15:33   #14
mikm
Major Dude
 
mikm's Avatar
 
Join Date: May 2001
Location: somewhere else
Posts: 1,286
he's saying that there would be no user input

powered by C₈H₁₀N₄O₂
mikm is offline   Reply With Quote
Old 18th June 2003, 21:19   #15
UnConeD
Whacked Moderator
 
UnConeD's Avatar
 
Join Date: Jun 2001
Posts: 2,104
Well no, an ape would be required for the input, but that's basically it. All the stuff you talk about (flippers, collisions) is perfectly done in AVS...

UnConeD is offline   Reply With Quote
Old 19th June 2003, 06:53   #16
Magic.X
Major Dude
 
Magic.X's Avatar
 
Join Date: Feb 2002
Location: Leipzig / Germany
Posts: 859
Ok, maybe i just don't get it. How would you code a Ball SSC without knowledge of the sourceframe which is needed to render a collission?

The only thing i could imagine is that the SSC already contains the table layout. Then again, how would that go with the flippers?


-=[The Ultimate VJ-Tool for AVS]=-

Hotlist 2.3 developement thread (old)
Magic.X is offline   Reply With Quote
Reply
Go Back   Winamp & Shoutcast Forums > Visualizations > AVS

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump