From 63e8b134ac8536b60784863ccbbca25d3cc7a3e1 Mon Sep 17 00:00:00 2001 From: Pawel Bogut Date: Fri, 30 Mar 2018 21:10:45 +0200 Subject: [PATCH] Fix raytracing render for python3 --- src/Mod/Raytracing/Gui/Command.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Mod/Raytracing/Gui/Command.cpp b/src/Mod/Raytracing/Gui/Command.cpp index c0edaa8441..2e99b28155 100644 --- a/src/Mod/Raytracing/Gui/Command.cpp +++ b/src/Mod/Raytracing/Gui/Command.cpp @@ -647,7 +647,7 @@ void CmdRaytracingRender::activated(int) std::stringstream h; h << height; std::string par = hGrp->GetASCII("OutputParameters", "+P +A"); - doCommand(Doc,"PageFile = open(App.activeDocument().%s.PageResult,'r')",Sel[0].getFeatName()); + doCommand(Doc,"PageFile = open(App.activeDocument().%s.PageResult,'rb')",Sel[0].getFeatName()); doCommand(Doc,"import os,subprocess,tempfile"); doCommand(Doc,"fd, TempFile = tempfile.mkstemp(suffix='.pov')"); doCommand(Doc,"f = open(TempFile,'wb')"); @@ -675,7 +675,7 @@ void CmdRaytracingRender::activated(int) } openCommand("Render project"); - doCommand(Doc,"PageFile = open(App.activeDocument().%s.PageResult,'r')",Sel[0].getFeatName()); + doCommand(Doc,"PageFile = open(App.activeDocument().%s.PageResult,'rb')",Sel[0].getFeatName()); doCommand(Doc,"import subprocess,tempfile"); doCommand(Doc,"TempFile = tempfile.mkstemp(suffix='.lxs')[1]"); doCommand(Doc,"f = open(TempFile,'wb')");