No announcement yet.

Tips&Tricks in AVS

This is a sticky topic.
  • Filter
  • Time
  • Show
Clear All
new posts

  • #46
    long essay

    This one is all about the 2 in 1 scopes, I wrote all this when I was offline in notepad and then posted it here:
    the previous two explainations just explained the concept, now here's the explaination of the actual code:

    Lets just consider the pixel part first because the beat and frame part is just for the movement of the scope.
    here's the code for the ssc:

    some variables required at initin fact, all the variables in the actual init are required )

    (I will explain their use later on)

    reset values per frame :

    pixel part:

    1) value of cp swaps beetween 1 and 0 every point. this is basically used to make solid scopes.
    eg:- when we multiply x and y with cp, and when
    a) cp=1, then x=x and y=y
    b) if cp=0 then x=0 and y=0.
    So, after every alternate point, the co-ordinates of the next point are (0,0). so, when we render the scope as lines, the entire part is filled with lines and we get a solid scope (provided the no of pts (n) is quite high)

    2) cn:- this is the number of the point drawn. it is reseted to 0 every frame.

    3) i1:- Custom i value. i1 is incremented by a1 every point.
    value of a1 is 1/(499-1). ie. 488. ie.0.0208333...

    4) colc:- used for hiding the point which connects the two objects.
    So, when cn=501, bnot(equal(cn,501)) will return 0 else it will retun 1
    cn is the number of the point. bu assigning rgb values to colc, the values for the 501th point will be 0 and for the other points will be 1.

    5) trans:- no connection with its name and its values. I too dont remember why I used such a variable name.
    trans=above(cn,500); this will return 1 if cn is above 500, else it will return 0. (use explained later).

    6) v1: Custom v value.
    if cn is divided by vrem(n/10 i.e 1000/10 i.e 100)
    and the remainder is zero ( vrem is a factor of cn) then return v else return v1+abs(v/10);
    In short v1 is used for the waves created in the outer circle. whenever vrem is a factor of cn, then value of v1 will jump to v ( i.e after every 100 point value of v1 will be v), else it will be v1+abs(v/10), the will create the normal waves.

    7) d is distance for the outer circle. this will swap beetween .98 and 1+v1*.2 as cp swaps beetween 1 and 0.

    8) th:- angle ( usually r ) th = t+i1*tpi;
    we have used cutom i value, so at the start i1=0 and at the end it is roughly 2. this is because we want to draw basically 2 circles.

    9) outx=sin(th)*d;
    the outer circle. conversion of polar coords into rectangular coords.

    10) inx=bnot(cp)*sin(th)*.3;
    the inner circle (d=.3). value swaps beetween 0 and sin(th)*.3 or cos(th)*.3 for the solid fill effect.

    11) x=if(trans,outx,inx)+ox;
    so, if cn<500 draws the outer circle, else draw the inner circle.

    12) red=colc;green=colc*.5;blue=0;
    if cn=501, then red=0; green=0;blue=0;
    if cn!=501 then red=1; green=.5;blue=0.
    this is for the orange colour.

    finally, i did it. hope you understand this, I havent explained the movment part because it is all normal and basic stuff.

    this is the preset I used the scope in:
    found in my first pack.

    btw. good way to increase posts
    Last edited by shreyas_potnis; 14 March 2003, 12:58.****~shreyaspotnis


    • #47
      rovastar did a good job here, merged the two threads, Thanks.
      edit: What about converting this thread into a sticky? can we do that?****~shreyaspotnis


      • #48
        I was about to tell you to use the edit button until I realized that these posts have some time separating them. Yay for Rovastar, someone listened to my request!

        [Over The Monkey] | [My DeviantArt] | [Seti] | [Atmo Digital Design Forums]


        • #49
          me too sent a private message to him!
          and what about the sticky?


          • #50
            good idea i must say, i like it!
            Phi = (1+sqrt(5))/2


            • #51
              Good, it's stickied now. Here's a tip for AVS n00bs: Don't submit your packs to without first posting them here. We will give you a lot of constructive criticism and you can then fix your presets to make them even better. And beware the Atero.

              [Over The Monkey] | [My DeviantArt] | [Seti] | [Atmo Digital Design Forums]


              • #52
                Actually, it's more like check the forums for your question, doublecheck, triplecheck, quadruplecheck, and pentuple check for it before posting a new topic about your question or face the wrath of Atero (And the rest of the regulars dogpiling on you)
                [soon to leave, sirs]


                • #53

                  Custom inversion :

                  White SSC in an effect list, XOR output. Any other white surface will do.

                  AVS Lingo :

                  SSC - Superscope
                  DM - Dynamic Movement
                  DDM - Dynamic Distance Modifier
                  DS - Dynamic Shift
                  MP - Moving Particles
                  Convo Filter (Or just plain convo) - Convolution Filter
                  Fast Brite - Fast Brightness
                  (There are more, figure out yourself)

                  Chroming :
                  Chroming is changing the spectrum from 0...255 into 0..255...0 where 128 is now 255 - So it filters out anything too white.
                  It can be done in several ways :
                  -Effect list - Fast brite - Replace input, SubBlend2 output, another fast brite outside.
                  -Buffer save, clear screen, 3 effect lists. One colormap for each list, additive blend for each list (except for the top). Each taking different color, with buffer restore on top of them. Change the white into the corresponding colors, drag them to middle. Add a black in the end. (SLOW, too much work, just saying it)
                  -List (Replace input, max output) with invert in it, then an invert (outside the list) and a fast brite.
                  -Jheriko's multi filter. Fastest.

                  Rotation Delay :

                  (Copied directly from fsk's guide. For the preset in action, go to, galleries, and then "Zvezda")

                  rotation dellay


                  on beat:

                  per fr.:

                  rz1=rz1+g; srz1=sin(rz1)/10; rz2=rz2+srz1;
                  usualy you just use the rz1 but in this case you have to put it thru another sin to make the changes in the rotation soft (dunno how to put it otherwise - remeber the first tentacle I sent you, it didn't have tis and it kinnda jumped on beat)

                  per point:


                  The distance from center

                  this is the effect part

                  srz1 is the current change in rotation, so if you aplly les (-) rotation to the points further away from the center (*dst) you get the desired effect .

                  this needs to be in the per point.


                  That is it . For 3D aplly to all three axes and use a 3D distance


                  Shape Engines :

                  Use point-by-point assigning (p=p+1 in pixel, p=0 in frame, and assign coordinates). Put in p%(points used in the shape) in place of the p in equal(p,n).
                  Use p1=if(equal(p%(points used in the shape),1),p1+1,p1) in pixel and p1=0 in frame to assign numbers for the shape.


                  Fix aspect ratio before posting your pack, or UnConeD will be angry at you.

                  Don't do the normal getosc syncing, or Atero will be angry at you.
                  Heck, he'll be angry at you anyways - The standard greeting.
                  [soon to leave, sirs]


                  • #54
                    There is another way of syncing other than with getoscs or getspecs?
                    please explaino.

                    There are some *hidden* coding paramerters for sscs and dms etc.
                    exp(x) returnes the 'e' (the exponential constant) to the power of x.
                    atan2(a,b) i really have no idea.
                    and (for the true n00b)
                    alpha=0..1 -alpha sets the level of alpha blending in a dm if the blend setting is activated. this is done per point, so that mixtures/grandients of input and output can be created. can also be used to add fog and/or cover 'uglyedge' syndrome for 3d scopes. But i wont get into that. If you can ray-trace, then i think you can work this out for yourself.

                    also pi=acos(-1);
                    cheers to whoever enlightened us on this one. (methinks steven)

                    thats all i can think of for now..

                    Oh Yeah.. With SSC. Never restrict yourself to creating shapes strictly from x/y= some form of 'i'.
                    This is a very restrictive mothod in some cases.

                    init-- t=0; s=0; n=64

                    perframe-- t=0; s=0
                    perpoint-- s=if(equal(t,8),s+1,s);
                    x=s/8; y=t/8

                    this should creat a 8x8 dot grid, but i cant test it on this comp so correkt me if im wrong.
                    use colour coding to blacken the bits where lines cross over screen.


                    • #55
                      AVS Axer :

                      Exp(x) and atan2(a,b) are already known, alpha is well known, pi is already a basic knowledge.

                      Oh, and your code is wrong (I didn't test, so not 100% sure).
                      1. T is never 8, so there is never any increase of t or s, so the counter won't work.
                      2. The x will just draw across the screen, so the correction should be x=s/8-t+1;
                      [soon to leave, sirs]


                      • #56
                        Heaven forbid that any newbie actually looks at this thread, cause if they do they will be completely overwhelmed.

                        My best advice is to not go into Whacko AVS or El-vis's stuff & try to pick apart how the hell those codes work. First go in, & try some very simple codes. Then check out other presets with very simple codes and see how they work. I think most of my stuff is pretty easy, I don't use too many varibles & other crap. (shameless self promotion).

                        All in all, start out small & build from there.


                        • #57
                          hey nic01.. i didnt mean they arnt well known.. they just explained in the program. so newbs may not know about them


                          • #58
                            n00b mus be quie happ wih all his suff


                            • #59
                              Originally posted by NemoOrange
                              Heaven forbid that any newbie actually looks at this thread, cause if they do they will be completely overwhelmed.
                              This wasnt meant to be a newbie startup thread but a knowledge topic for advanced AVSers (correct me if i got something wrong)

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

                              Hotlist 2.3 developement thread (old)


                              • #60
                                This isn't supposed to help anyone in particular, just anything that may be useful to anyone goes in here.