Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlfredo de Greef <eeshlo@yahoo.com>2006-06-30 08:53:59 +0400
committerAlfredo de Greef <eeshlo@yahoo.com>2006-06-30 08:53:59 +0400
commit3ba91bce8e21239f41804617d5519e0c5a2534e5 (patch)
tree74ef64a8a79ad39e598d2cbe8c541aa4fe641acd /source/blender/yafray/intern/export_File.cpp
parent7e614bbac9504738f2df41766f2b5e4d1f4df1dc (diff)
bug #4532, when field rendering enabled in blender (not supported in yafray),
blender doubles the aspect ratio. This is now taken into account.
Diffstat (limited to 'source/blender/yafray/intern/export_File.cpp')
-rwxr-xr-xsource/blender/yafray/intern/export_File.cpp7
1 files changed, 6 insertions, 1 deletions
diff --git a/source/blender/yafray/intern/export_File.cpp b/source/blender/yafray/intern/export_File.cpp
index 2e1b63b2ecc..f4ba9f59409 100755
--- a/source/blender/yafray/intern/export_File.cpp
+++ b/source/blender/yafray/intern/export_File.cpp
@@ -1790,7 +1790,12 @@ void yafrayFileRender_t::writeCamera()
if ((re->winx * re->r.xasp) <= (re->winy * re->r.yasp))
f_aspect = float(re->winx * re->r.xasp) / float(re->winy * re->r.yasp);
ostr << "\n\tfocal=\"" << mainCamLens/(f_aspect*32.f);
- ostr << "\" aspect_ratio=\"" << re->ycor << "\"";
+ // bug #4532, when field rendering is enabled, ycor is doubled
+ if (re->r.mode & R_FIELDS)
+ ostr << "\" aspect_ratio=\"" << (re->ycor * 0.5f) << "\"";
+ else
+ ostr << "\" aspect_ratio=\"" << re->ycor << "\"";
+
// dof params, only valid for real camera
float fdist = 1; // only changes for ortho