• fullscreen
  • Capitulo7pub.pde
  • byte cap7[];
    int txtWidth = 75;
    int incX = 4;
    int incY = 18;
    int sz;
    int x = 0;
    int y = 0;
    int c = 0;
    int txtHeight;
    
    //.-----------------------------------------------
    void setup(){
        frameRate(12);
        cap7 = loadBytes("capitulo7.txt");
        sz = cap7.length;
        txtHeight = sz/txtWidth;
        size(txtWidth*incX+100, txtHeight*incY+100);
        println("Hay " + sz + " en capitulo 7");
    }
    
    
    //.-----------------------------------------------
    void draw(){
    
        fill(80*sin(0.02*frameCount)+120,
        64*cos(0.005*frameCount)+100,
        64*sin(0.0025*frameCount + (PI/4))+64,
        50*sin(0.001*frameCount)+50);
        
        rect(0,0,txtWidth*incX+100, txtHeight*incY+100);
    
    
        for(int i = 0; i < txtHeight ; i++){
          for(int j = 0; j < txtWidth; j++){
              x = j * incX + 50;
              y = i * incY + 50;
    /*          fill(cap7[(i+j*i+c)%sz], 
                   cap7[(i+j*i+1+c)%sz], 
                   cap7[(i+j*i+2+c)%sz], 
                   cap7[(i+j*i+3+c)%sz]);*/
              
              fill(cap7[(i+(j*i)+c) % sz],      
    //          fill(cap7[(i+(j*i)+(int)(128*sin(0.00002*frameCount)+127)) % sz], 
                   0, 
                   0, 
                   cap7[(i+(j*i)+(int)(100*sin(0.02*frameCount)+100))%sz]);
         
              stroke(cap7[(i+(j*i)+(int)(15*sin(0.02*frameCount)+15))%sz],
              cap7[(i+(j*i)+(int)(15*sin(0.04*frameCount)+15))%sz],
              cap7[(i+(j*i)+(int)(15*sin(0.06*frameCount)+15))%sz],
              cap7[(i+(j*i)+(int)(15*sin(0.02*frameCount)+15))%sz]);
              rect(x,y,incX, incY);
           
      
            }
           }      
     c = (c + 1) % sz;
    }
    

    code

    tweaks (0)

    about this sketch

    This sketch is running as Java applet, exported from Processing.

    license

    advertisement

    Report Sketch

    Report for inappropriate content

    Please provide details if possible:

    Your have successfully reported the sketch. Thank you very much for helping to keep OpenProcessing clean and tidy :)

    Make a Copyright Infringement claim

    Mauro Herrera Machuca

    Capitulo7

    Add to Faves Me Likey@!
    You must login/register to add this sketch to your favorites.

    Carga el texto del Capitulo 7 de Rayuela y lo convierte en una cadena de bytes, una representación numérica del texto.
    Esta representación es leída por el programa a forma de canon para darle movimiento (las cosas tienen movimiento).
    Así, el resultado visual que ves es una lectura más del Capitulo 7, una lectura para ti...

    You need to login/register to comment.