Old 27th August 2007, 12:45   #1
bdrv
Senior Member
 
Join Date: Apr 2007
Posts: 183
framespace invader and other weirdness

....

smoky grinding shaky alien futuristic graphics for you...very nicey.
bdrv is offline   Reply With Quote
Old 27th August 2007, 12:47   #2
bdrv
Senior Member
 
Join Date: Apr 2007
Posts: 183
HERE is the file---oops
Attached Files
File Type: rar general weird milkdrop presets.rar (17.7 KB, 403 views)
bdrv is offline   Reply With Quote
Old 27th August 2007, 15:43   #3
Flexi
wellspring of milk
Major Dude
 
Flexi's Avatar
 
Join Date: Apr 2007
Location: 54.089866,12.11168,18.75
Posts: 2,055
Send a message via ICQ to Flexi
hehe
rly mental - as you would say

here are some very very quick remixes with my last-mentioned colorfade script (plus my latest 3 ultra drippy presets!). - Amazing!

(depending on the music my presets may need a minute or two to accelerate to their final velocity. sry - thats the tribute to such dynamic systems)

Flexi
Attached Files
File Type: zip bdrv & flexi - weirdness.zip (25.8 KB, 451 views)
Flexi is offline   Reply With Quote
Old 27th August 2007, 18:41   #4
X-pand
Junior Member
 
Join Date: Jul 2007
Location: Lutsk, Ukraine
Posts: 29


Perfectly coordinate-oriented work!...
I could not use similar in my presets because... I am not able make so now

Fun!...



p.s. (for bdrv) : did you can use mesh size 80x60 or more (15 fps - are normal in this mode) ?
X-pand is offline   Reply With Quote
Old 28th August 2007, 09:52   #5
bdrv
Senior Member
 
Join Date: Apr 2007
Posts: 183
thanks flexi thats wicked, I have done some excellent remixes with your code someplace but I just have to figure what I remixed everything with and where...

I only use medium mesh size and everything runs smooth on a 1920 pixel monitor with only a basic laptop ATI graphics card -the laptop is going on to the 1920 monitor.

the interesting thing about these presets is they use a diamond shape which fits better into the mesh compared to a square shape or a round shape- the mesh only goes horizontal vertical and diagonal, and round edges look really blocky,but a square turned round into diamond shape fits better than a horizontal square.

to be honest I only figured out what the mesh is a few months ago, it looks more like a bug because it is so blocky, it can only cope with slow changes in coordinates...

actually all the per pixel code -DX zoom rotation- works in exactly the same way it just tells different directions for the pixels to move and the value makes different speeds, but you can program the zoom and a rotation just by combining DXDY so that they turn the pixels around or that they zoom the pixels into and out from the centre etc

is just a shame that this amazing program doesn't have any kind of formula management because it makes it slow and confusing to program...I have kind of added an extra layer to the program however because all those lots of small lines of definitions is just to copy the pixels movement code to one value, reset them, take the value of the next pixel movement formula, and then mix the two together by multiplying at the end, like this you can mix them together at any speed and with any proportion for example in the centre...

anyway, I will try and do a tutorial to explain what I learned about Zoom and Rotation, basically the program handles slow changes in pixel speed across the screen very well, but if it is very slow at one side and very fast at the other the mesh becomes really buggy. best thing to learn what all the code does is try everything with very small values for examples zoom 1.01...and Zoom 0.3

so anyway-I will try and upload more things.cheers
bdrv is offline   Reply With Quote
Old 28th August 2007, 17:29   #6
Flexi
wellspring of milk
Major Dude
 
Flexi's Avatar
 
Join Date: Apr 2007
Location: 54.089866,12.11168,18.75
Posts: 2,055
Send a message via ICQ to Flexi
you have to know, your per-pixel code is not calculated for every pixel exactly - that would be waaaaayy to much calculation for our present computers ;-)(I mean in realtime)

That's why the dx/dy code is only calculated for the mesh-dots, the whole rest is interpolated between the nearest dots. I guess it's a simple linear interpolation. This makes also a lot of sense, because all the little squares in the mesh can be filled with a warped clipping of the texture of the last frame. This warping is in fact a matrix-calculation, which gets as parameters the dx/dy-values of the edges of the square (which is to be filled). (graphics-cards are optimized for those matrix-calculations!)
[am i right, rova and redi-jedi? And are zoom and rot effects calculated the same way?]

That also means nonlinear details, that are finer than one of the squares, cannot be resolved.

@bdrv: you achieve ugly(or sometimes cool) blocky results, if you model discontinuities in functions, where your motion-vectors reach farther than one little square.

Quote:
have kind of added an extra layer to the program however because all those lots of small lines of definitions is just to copy the pixels movement code to one value, reset them, take the value of the next pixel movement formula, and then mix the two together by multiplying at the end
look, there's a late birthday present for you!
going abstract in modelling is exactly the way to go!

the per-pixel code in the preset below is a fully commented script to rotate every dx/dy-code you want Have fun with this fine remixing tool!

by the way: to avoid discontinuities, i mostly use a sigmoid function. see wikipedia or so ;-)
Attached Files
File Type: zip rotating per-pixel tutorial.zip (3.7 KB, 309 views)
Flexi is offline   Reply With Quote
Old 28th August 2007, 19:19   #7
bdrv
Senior Member
 
Join Date: Apr 2007
Posts: 183
thanks ALOT for that explanation, I understand that. As a result I guess the most processing power goes into interpolating everything.

I did some examples to explain the jagged thing here-

flexi that tutorial is ultra complicated!
Attached Files
File Type: rar bdrv - aztec ruins.rar (18.6 KB, 457 views)

Last edited by bdrv; 28th August 2007 at 19:55.
bdrv is offline   Reply With Quote
Old 28th August 2007, 22:29   #8
Flexi
wellspring of milk
Major Dude
 
Flexi's Avatar
 
Join Date: Apr 2007
Location: 54.089866,12.11168,18.75
Posts: 2,055
Send a message via ICQ to Flexi
really so hard? all you need to know is, that you use the indented dx1/dy1 instead of dx/dy. and now you can rotate it via the 'w' variable. (If you want to go in deeper, check http://en.wikipedia.org/wiki/Rotation_matrix )

I only inserted my shroomy script, because it's very compact in its 2 lines (apart of its visual impact )

replace the dx1/dy1 lines with your own code. If you give me a preset, where you set only the dx/dy vars (but not zoom/rot/sx/sy/...) i can show you, what i mean.

(all the other vars next to dx/dy are only shortcuts to calculations on 'em - and generally, every warping code can be expressed by only setting dx/dy and x/y as parameters. In fact it's quite to hard for me to comprehend warps, which are modelled with zoom/rot/etc. - i simply can't visualize em - ehm... i mean on my mind )

as if you knew, there was a simple preset in your last archive.
btw: nice effects once again!

see this one
Attached Files
File Type: zip bdrv - cuddly blob23 [rotating].zip (2.0 KB, 300 views)
Flexi is offline   Reply With Quote
Old 29th August 2007, 15:13   #9
bdrv
Senior Member
 
Join Date: Apr 2007
Posts: 183
oooh kool, I had some of it figured, I mean it would be confusing for a beginner-its a good idea to do a tutorial within some script, so you can interactively modify stuff.
bdrv is offline   Reply With Quote
Old 31st August 2007, 00:01   #10
Rovastar
Moderator
 
Join Date: Jun 2001
Location: London, England
Posts: 3,632
Send a message via AIM to Rovastar
Quote:
Originally posted by Flexi
you have to know, your per-pixel code is not calculated for every pixel exactly - that would be waaaaayy to much calculation for our present computers ;-)(I mean in realtime)

That's why the dx/dy code is only calculated for the mesh-dots, the whole rest is interpolated between the nearest dots. I guess it's a simple linear interpolation. This makes also a lot of sense, because all the little squares in the mesh can be filled with a warped clipping of the texture of the last frame. This warping is in fact a matrix-calculation, which gets as parameters the dx/dy-values of the edges of the square (which is to be filled). (graphics-cards are optimized for those matrix-calculations!)
[am i right, rova and redi-jedi? And are zoom and rot effects calculated the same way?]
That sound pretty good explaination to me. I have not checked the source code for some time and cannot remember how it performs them but a matrix calc seems a good bet.

For rot and zoom they are just shortcuts for little snipets of code for dx/dy stuff.

I cannot remember exactly what they are but they can all be easily reproduced as normal dx/dy code. Search for the forums for "custom zoom" and you should find an explaination of how to reproduce it with just dx and dy commands.

The warp command is the same (it is confusing talking about warps in teh mesh when there is a warp command in milkdrop (that again can recreated with multiple dx and dy commands)

hope that makes sense.....

"Rules are for the guidance of wisemen and the obedience of fools"

Visuals - Morphyre www.Morphyre.com
Rovastar is offline   Reply With Quote
Old 31st August 2007, 00:24   #11
Rovastar
Moderator
 
Join Date: Jun 2001
Location: London, England
Posts: 3,632
Send a message via AIM to Rovastar
Ummh looking at the source again for zoom

Code

float fZoom2 = powf(fZoom, powf(fZoomExp, m_vertinfo[n].rad*2.0f - 1.0f));
// initial texcoords, w/built-in zoom factor
float fZoom2Inv = 1.0f/fZoom2;
float u = m_verts[n].x*0.5f*fZoom2Inv + 0.5f;
float v = -m_verts[n].y*0.5f*fZoom2Inv + 0.5f;

Milkdrop code

my_zoom_exp = 1; // defined in perframe or perpixel - using 1 for this example
my_zoom = 1; // defined in perframe or perpixel - using 1 for this example
a = pow(my_zoom, pow(my_zoom_exp, rad*2-1));
dx = (x - .5)*a + .5 - x;
dy = (y - .5)*a + .5 - y;

Along those lines will work.

I hoep you can understand that and picture it more.

If needs be I can convert rot and warp at some point too.

"Rules are for the guidance of wisemen and the obedience of fools"

Visuals - Morphyre www.Morphyre.com
Rovastar is offline   Reply With Quote
Old 1st September 2007, 03:53   #12
redi jedi
Will code for food
 
Join Date: Mar 2005
Location: orlando
Posts: 521
the "grid" is a long list of triangles, starting in the top left of the screen and kinda making squares across the screen, then wraps back around kinda like this:
code:

___________ ___________ ___________ ___________
|\ | /|\ | /|\ | /|\ | /|
| \ | / | \ | / | \ | / | \ | / |
| \ | / | \ | / | \ | / | \ | / |
| \ | / | \ | / | \ | / | \ | / |
|____\|/____|____\|/____|____\|/____|____\|/____|
|\ | /|\ | /|\ | /|\ | /|
| \ | / | \ | / | \ | / | \ | / |
| \ | / | \ | / | \ | / | \ | / |
| \ | / | \ | / | \ | / | \ | / |
|____\|/____|____\|/____|____\|/____|____\|/____|



like ya said each triangle is textured with its portion of the screen from the frame before(Motion vectors are drawn before this happens... I think thats what actually makes them work)

to start with each point or corner(whatever ya wanna call it) is set with the texture cords equal to its position cords, so basically a direct map of the last screen.

with all dx/dy(everything else is compiled into them like rova said) vars at 0(or 1 or .5) nothing really happens.. maybe some distortion..(down and to the left anyone?) but if dx or dy have a value its added to the corresponding coordinate, so for instance if dx is -.005 for all points in the grid the entire thing will pull from .005 to one side(cant remember which side)

on a side note:
the "decay" effect is done by the color at which the texture is drawn, this color basically modulates the color in the texture.. I think it acts as a multiplier not 100% here, its a DirectX thing so I cant see the code that actually does it.

Version 1.04 just took the decay variable and set it to the RGB components of all the points on the grid, in the beta I simply searched for all occurrences of decay and added the decay_r/g/b vars under the existing decay var, then did the same with the dx per pixel variables to make it work just like dx does and feed the info into the points on the grid.

Blah!
redi jedi is offline   Reply With Quote
Old 1st September 2007, 15:18   #13
Rovastar
Moderator
 
Join Date: Jun 2001
Location: London, England
Posts: 3,632
Send a message via AIM to Rovastar
Quote:
Originally posted by redi jedi
with all dx/dy(everything else is compiled into them like rova said) vars at 0(or 1 or .5) nothing really happens.. maybe some distortion..(down and to the left anyone?) but if dx or dy have a value its added to the corresponding coordinate, so for instance if dx is -.005 for all points in the grid the entire thing will pull from .005 to one side(cant remember which side)
There shouldn't be any movement when dx and dy are 0. Any movement like you are seeing is down to you graphics card most likely. I imagine it get worse if you use low texture sizes.

I problem goes back years but it is fault of the graphics cars companies drivers and their texel alignment.
To get the image stationary we used to add values like:
dx = dx - 0.005
dy = dy - 0.005
to the preset sto get them to be stationary.

Then we got ryan to fix teh code and add teh correct values - it was fixed as with dx|dy += -1/(texsize*2) which was needed several years ago as all cards seemed to use the same pixel alignment expect for the MAtrox card that Ryan developed MD on. So it was fixed for all cards apart from the Matrox.

I think it is whether the texel alignment was even or odd number (to donote teh placement of the texels) if even added dx|dy += -1/(texsize*2) if odd do nothing. (or it could be the other way around).

If you really want to know it is here.
http://forums.winamp.com/showthread.php?threadid=83401

NOw in recent years it seems that soem graphics card companies have changed the defualt texel alignment in some cards and/or drivers (ATi notably) leading you to once again add dx=dx-0.005 etc to you presets.

Hope that makes sense.

"Rules are for the guidance of wisemen and the obedience of fools"

Visuals - Morphyre www.Morphyre.com
Rovastar is offline   Reply With Quote
Old 10th September 2007, 23:45   #14
bdrv
Senior Member
 
Join Date: Apr 2007
Posts: 183
i'll stick to writing presets-10 variables-can't go wrong-that programming thing is really hard,

sorry I started posting preset and putting my name on the front because its tidy and I'm a bit of a wonker like that, but it turns out that having done 2000 presets or 5000 or something all with my name on the front when half of it is other people's code seems a bit like a hijack...

don't worry I'm going to scrap attributions altogether it takes too much time I just do automatic machine names now.

all I can dream of is a 3D version of milkdrop with the same level of complexity as the pixel movement applied to a way of generating wire frames.

Ryan does metablobs and it is possible to extend the concept of metablobs to create landscapes that you can travel through with any amount of surface textures in three dimensions and shape floating about in three dimensions.

like that people can make computer games and there's money in it.
Attached Files
File Type: rar bdrv adderasi- funky pipe2.rar (2.7 KB, 375 views)

Last edited by bdrv; 11th September 2007 at 01:17.
bdrv is offline   Reply With Quote
Reply
Go Back   Winamp & SHOUTcast Forums > Visualizations > MilkDrop > MilkDrop Presets

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