Roxen.git / server / modules / graphics / cimg.pike

version» Context lines:

Roxen.git/server/modules/graphics/cimg.pike:1:   // This is a roxen module. Copyright © 1999 - 2000, Roxen IS.   //      #include <module.h>   inherit "module";   constant thread_safe=1;      roxen.ImageCache the_cache;    - constant cvs_version = "$Id: cimg.pike,v 1.35 2000/11/19 21:32:54 kuntri Exp $"; + constant cvs_version = "$Id: cimg.pike,v 1.36 2000/12/05 00:25:10 nilsson Exp $";   constant module_type = MODULE_TAG;   constant module_name = "Image converter";   constant module_doc = "Provides the tag <tt>&lt;cimg&gt;</tt> that can be used "   "to convert images between different image formats.";         mapping tagdocumentation() {    Stdio.File file=Stdio.File();    if(!file->open(__FILE__,"r")) return 0;    mapping doc=compile_string("#define manual\n"+file->read())->tagdoc;
Roxen.git/server/modules/graphics/cimg.pike:194:    inherit RXML.Tag;    constant name = "emit";    constant plugin_name = "cimg";       array get_dataset( mapping args, RequestID id )    {    mapping res = ([ ]);    mapping a = get_my_args( check_args( args ), id );    string data;    -  res->src = (query_internal_location()+the_cache->store( a,id )); +  res->src = (query_absolute_internal_location(id) + +  the_cache->store( a,id ));    data = the_cache->data( a, id , 0 );    res["file-size"] = strlen(data);    res["file-size-kb"] = strlen(data)/1024;    res["data"] = data;    res |= the_cache->metadata( a, id, 0 ); // enforce generation    return ({ res });    }   }      class TagCImg
Roxen.git/server/modules/graphics/cimg.pike:218:    constant flags = RXML.FLAG_EMPTY_ELEMENT;       class Frame    {    inherit RXML.Frame;       array do_return(RequestID id)    {    mapping a = get_my_args( check_args( args ), id );    args -= a; -  args->src = query_internal_location()+the_cache->store( a,id ); +  args->src = query_absolute_internal_location(id) + +  the_cache->store( a,id );    if( mapping size = the_cache->metadata( a, id, 1 ) )    {    // image in cache (1 above prevents generation on-the-fly)    args->width = size->xsize;    args->height = size->ysize;    }    int xml=!args->noxml;    m_delete(args, "noxml");    result = Roxen.make_tag( "img", args, xml );    return 0;
Roxen.git/server/modules/graphics/cimg.pike:244:    inherit RXML.Tag;    constant name = "cimg-url";    constant flags = RXML.FLAG_EMPTY_ELEMENT;       class Frame    {    inherit RXML.Frame;       array do_return(RequestID id)    { -  result = query_internal_location()+ +  result = query_absolute_internal_location(id)+    the_cache->store(get_my_args(check_args( args ), id ),id);    return 0;    }    }   }