projects
/
synfig.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Prevent all remaining 'unused parameter' warnings when compiling with debug enabled.
[synfig.git]
/
synfig-core
/
trunk
/
src
/
synfig
/
target_scanline.cpp
diff --git
a/synfig-core/trunk/src/synfig/target_scanline.cpp
b/synfig-core/trunk/src/synfig/target_scanline.cpp
index
3021884
..
23b86b3
100644
(file)
--- a/
synfig-core/trunk/src/synfig/target_scanline.cpp
+++ b/
synfig-core/trunk/src/synfig/target_scanline.cpp
@@
-2,7
+2,7
@@
/*! \file target_scanline.cpp
** \brief Template File
**
/*! \file target_scanline.cpp
** \brief Template File
**
-** $Id
: target_scanline.cpp,v 1.1.1.1 2005/01/04 01:23:15 darco Exp
$
+** $Id$
**
** \legal
** Copyright (c) 2002-2005 Robert B. Quattlebaum Jr., Adrian Bentley
**
** \legal
** Copyright (c) 2002-2005 Robert B. Quattlebaum Jr., Adrian Bentley
@@
-125,7
+125,7
@@
synfig::Target_Scanline::render(ProgressCallback *cb)
curr_frame_=0;
if( !init() ){
curr_frame_=0;
if( !init() ){
- if(cb) cb->error(_("Target initiali
s
ation failure"));
+ if(cb) cb->error(_("Target initiali
z
ation failure"));
return false;
}
return false;
}
@@
-173,7
+173,7
@@
synfig::Target_Scanline::render(ProgressCallback *cb)
#ifdef SYNFIG_OPTIMIZE_LAYER_TREE
Canvas::Handle op_canvas(Canvas::create());
#ifdef SYNFIG_OPTIMIZE_LAYER_TREE
Canvas::Handle op_canvas(Canvas::create());
- optimize_layers(canvas->get_context(), op_canvas);
+ optimize_layers(canvas->get_
time(), canvas->get_
context(), op_canvas);
context=op_canvas->get_context();
#else
context=canvas->get_context();
context=op_canvas->get_context();
#else
context=canvas->get_context();
@@
-199,16
+199,16
@@
synfig::Target_Scanline::render(ProgressCallback *cb)
#if USE_PIXELRENDERING_LIMIT
if(desc.get_w()*desc.get_h() > PIXEL_RENDERING_LIMIT)
{
#if USE_PIXELRENDERING_LIMIT
if(desc.get_w()*desc.get_h() > PIXEL_RENDERING_LIMIT)
{
- synfig::info("Render BROKEN UP! (%d pixels)", desc.get_w()*desc.get_h());
-
Surface surface;
int rowheight = PIXEL_RENDERING_LIMIT/desc.get_w();
Surface surface;
int rowheight = PIXEL_RENDERING_LIMIT/desc.get_w();
+ if (!rowheight) rowheight = 1; // TODO: render partial lines to stay within the limit?
int rows = desc.get_h()/rowheight;
int lastrowheight = desc.get_h() - rows*rowheight;
rows++;
int rows = desc.get_h()/rowheight;
int lastrowheight = desc.get_h() - rows*rowheight;
rows++;
- synfig::info("\t blockh=%d,remh=%d,totrows=%d", rowheight,lastrowheight,rows);
+ synfig::info("Render broken up into %d block%s %d pixels tall, and a final block %d pixels tall",
+ rows-1, rows==2?"":"s", rowheight, lastrowheight);
// loop through all the full rows
if(!start_frame())
// loop through all the full rows
if(!start_frame())
@@
-222,7
+222,7
@@
synfig::Target_Scanline::render(ProgressCallback *cb)
RendDesc blockrd = desc;
//render the strip at the normal size unless it's the last one...
RendDesc blockrd = desc;
//render the strip at the normal size unless it's the last one...
- if(i == rows)
+ if(i == rows
-1
)
{
if(!lastrowheight) break;
blockrd.set_subwindow(0,i*rowheight,desc.get_w(),lastrowheight);
{
if(!lastrowheight) break;
blockrd.set_subwindow(0,i*rowheight,desc.get_w(),lastrowheight);
@@
-307,7
+307,7
@@
synfig::Target_Scanline::render(ProgressCallback *cb)
#ifdef SYNFIG_OPTIMIZE_LAYER_TREE
Canvas::Handle op_canvas(Canvas::create());
#ifdef SYNFIG_OPTIMIZE_LAYER_TREE
Canvas::Handle op_canvas(Canvas::create());
- optimize_layers(canvas->get_context(), op_canvas);
+ optimize_layers(canvas->get_
time(), canvas->get_
context(), op_canvas);
context=op_canvas->get_context();
#else
context=canvas->get_context();
context=op_canvas->get_context();
#else
context=canvas->get_context();
@@
-333,17
+333,17
@@
synfig::Target_Scanline::render(ProgressCallback *cb)
#if USE_PIXELRENDERING_LIMIT
if(desc.get_w()*desc.get_h() > PIXEL_RENDERING_LIMIT)
{
#if USE_PIXELRENDERING_LIMIT
if(desc.get_w()*desc.get_h() > PIXEL_RENDERING_LIMIT)
{
- synfig::info("Render BROKEN UP! (%d pixels)", desc.get_w()*desc.get_h());
-
Surface surface;
int totalheight = desc.get_h();
int rowheight = PIXEL_RENDERING_LIMIT/desc.get_w();
Surface surface;
int totalheight = desc.get_h();
int rowheight = PIXEL_RENDERING_LIMIT/desc.get_w();
+ if (!rowheight) rowheight = 1; // TODO: render partial lines to stay within the limit?
int rows = desc.get_h()/rowheight;
int lastrowheight = desc.get_h() - rows*rowheight;
rows++;
int rows = desc.get_h()/rowheight;
int lastrowheight = desc.get_h() - rows*rowheight;
rows++;
- synfig::info("\t blockh=%d,remh=%d,totrows=%d", rowheight,lastrowheight,rows);
+ synfig::info("Render broken up into %d block%s %d pixels tall, and a final block %d pixels tall",
+ rows-1, rows==2?"":"s", rowheight, lastrowheight);
// loop through all the full rows
if(!start_frame())
// loop through all the full rows
if(!start_frame())
@@
-357,7
+357,7
@@
synfig::Target_Scanline::render(ProgressCallback *cb)
RendDesc blockrd = desc;
//render the strip at the normal size unless it's the last one...
RendDesc blockrd = desc;
//render the strip at the normal size unless it's the last one...
- if(i == rows)
+ if(i == rows
-1
)
{
if(!lastrowheight) break;
blockrd.set_subwindow(0,i*rowheight,desc.get_w(),lastrowheight);
{
if(!lastrowheight) break;
blockrd.set_subwindow(0,i*rowheight,desc.get_w(),lastrowheight);