comparison snow.c @ 3075:961af1358c7f libavcodec

add static keyword to some functions patch by Dieter <freebsd at sopwith solgatos com>
author mru
date Mon, 30 Jan 2006 23:33:19 +0000
parents f02d0b59279c
children e1cbe2635325
comparison
equal deleted inserted replaced
3074:d89dcf01cae2 3075:961af1358c7f
1574 spatial_compose97i_init(&cs, buffer, height, stride); 1574 spatial_compose97i_init(&cs, buffer, height, stride);
1575 while(cs.y <= height) 1575 while(cs.y <= height)
1576 spatial_compose97i_dy(&cs, buffer, width, height, stride); 1576 spatial_compose97i_dy(&cs, buffer, width, height, stride);
1577 } 1577 }
1578 1578
1579 void ff_spatial_idwt_buffered_init(dwt_compose_t *cs, slice_buffer * sb, int width, int height, int stride_line, int type, int decomposition_count){ 1579 static void ff_spatial_idwt_buffered_init(dwt_compose_t *cs, slice_buffer * sb, int width, int height, int stride_line, int type, int decomposition_count){
1580 int level; 1580 int level;
1581 for(level=decomposition_count-1; level>=0; level--){ 1581 for(level=decomposition_count-1; level>=0; level--){
1582 switch(type){ 1582 switch(type){
1583 case 0: spatial_compose97i_buffered_init(cs+level, sb, height>>level, stride_line<<level); break; 1583 case 0: spatial_compose97i_buffered_init(cs+level, sb, height>>level, stride_line<<level); break;
1584 case 1: spatial_compose53i_buffered_init(cs+level, sb, height>>level, stride_line<<level); break; 1584 case 1: spatial_compose53i_buffered_init(cs+level, sb, height>>level, stride_line<<level); break;
1587 av_log(NULL, AV_LOG_ERROR, "spatial_composeX neither buffered nor slicified yet.\n"); break; 1587 av_log(NULL, AV_LOG_ERROR, "spatial_composeX neither buffered nor slicified yet.\n"); break;
1588 } 1588 }
1589 } 1589 }
1590 } 1590 }
1591 1591
1592 void ff_spatial_idwt_init(dwt_compose_t *cs, DWTELEM *buffer, int width, int height, int stride, int type, int decomposition_count){ 1592 static void ff_spatial_idwt_init(dwt_compose_t *cs, DWTELEM *buffer, int width, int height, int stride, int type, int decomposition_count){
1593 int level; 1593 int level;
1594 for(level=decomposition_count-1; level>=0; level--){ 1594 for(level=decomposition_count-1; level>=0; level--){
1595 switch(type){ 1595 switch(type){
1596 case 0: spatial_compose97i_init(cs+level, buffer, height>>level, stride<<level); break; 1596 case 0: spatial_compose97i_init(cs+level, buffer, height>>level, stride<<level); break;
1597 case 1: spatial_compose53i_init(cs+level, buffer, height>>level, stride<<level); break; 1597 case 1: spatial_compose53i_init(cs+level, buffer, height>>level, stride<<level); break;
1599 case 2: spatial_composeX(buffer, width>>level, height>>level, stride<<level); break; 1599 case 2: spatial_composeX(buffer, width>>level, height>>level, stride<<level); break;
1600 } 1600 }
1601 } 1601 }
1602 } 1602 }
1603 1603
1604 void ff_spatial_idwt_slice(dwt_compose_t *cs, DWTELEM *buffer, int width, int height, int stride, int type, int decomposition_count, int y){ 1604 static void ff_spatial_idwt_slice(dwt_compose_t *cs, DWTELEM *buffer, int width, int height, int stride, int type, int decomposition_count, int y){
1605 const int support = type==1 ? 3 : 5; 1605 const int support = type==1 ? 3 : 5;
1606 int level; 1606 int level;
1607 if(type==2) return; 1607 if(type==2) return;
1608 1608
1609 for(level=decomposition_count-1; level>=0; level--){ 1609 for(level=decomposition_count-1; level>=0; level--){
1617 } 1617 }
1618 } 1618 }
1619 } 1619 }
1620 } 1620 }
1621 1621
1622 void ff_spatial_idwt_buffered_slice(dwt_compose_t *cs, slice_buffer * slice_buf, int width, int height, int stride_line, int type, int decomposition_count, int y){ 1622 static void ff_spatial_idwt_buffered_slice(dwt_compose_t *cs, slice_buffer * slice_buf, int width, int height, int stride_line, int type, int decomposition_count, int y){
1623 const int support = type==1 ? 3 : 5; 1623 const int support = type==1 ? 3 : 5;
1624 int level; 1624 int level;
1625 if(type==2) return; 1625 if(type==2) return;
1626 1626
1627 for(level=decomposition_count-1; level>=0; level--){ 1627 for(level=decomposition_count-1; level>=0; level--){
1635 } 1635 }
1636 } 1636 }
1637 } 1637 }
1638 } 1638 }
1639 1639
1640 void ff_spatial_idwt(DWTELEM *buffer, int width, int height, int stride, int type, int decomposition_count){ 1640 static void ff_spatial_idwt(DWTELEM *buffer, int width, int height, int stride, int type, int decomposition_count){
1641 if(type==2){ 1641 if(type==2){
1642 int level; 1642 int level;
1643 for(level=decomposition_count-1; level>=0; level--) 1643 for(level=decomposition_count-1; level>=0; level--)
1644 spatial_composeX (buffer, width>>level, height>>level, stride<<level); 1644 spatial_composeX (buffer, width>>level, height>>level, stride<<level);
1645 }else{ 1645 }else{
3774 } 3774 }
3775 3775
3776 return 0; 3776 return 0;
3777 } 3777 }
3778 3778
3779 static void init_qexp(){ 3779 static void init_qexp(void){
3780 int i; 3780 int i;
3781 double v=128; 3781 double v=128;
3782 3782
3783 for(i=0; i<QROOT; i++){ 3783 for(i=0; i<QROOT; i++){
3784 qexp[i]= lrintf(v); 3784 qexp[i]= lrintf(v);