Commit 6c08afa3 authored by loring's avatar loring
Browse files

fix r27514 windows build issues


git-svn-id: http://visit.ilight.com/svn/visit/trunk/src@27560 18c085ea-50e0-402c-830e-de6fd14e8384
parent eb57793e
......@@ -46,6 +46,7 @@
#include <cstring>
#include <limits>
#include <algorithm>
#include <cmath>
#include <avtParallel.h>
#include <vtkActor.h>
......@@ -84,6 +85,12 @@
using std::vector;
using std::numeric_limits;
#ifdef _MSC_VER
template <typename num_t>
num_t log2(num_t num)
{ return log(num)/log(num_t(2)); }
#endif
// ****************************************************************************
// Class: Bounds
//
......
......@@ -645,8 +645,8 @@ NetworkManager::ClearNetworksWithDatabase(const std::string &db)
{
// Clear out the networks before the databases. This is because if we
// delete the databases first, the networks will have dangling pointers.
size_t nNets = networkCache.size();
for (size_t i = 0; i < nNets; ++i)
int nNets = static_cast<int>(networkCache.size());
for (int i = 0; i < nNets; ++i)
{
NetnodeDB *ndb;
if (networkCache[i] && (ndb = networkCache[i]->GetNetDB()) &&
......@@ -3217,7 +3217,7 @@ NetworkManager::SetWindowAttributes(EngineVisWinInfo &viswinInfo,
viswin->SetDisplayListMode(1); // never
// handle stereo rendering settings
int stereo = renderAtts.GetStereoRendering();
bool stereo = renderAtts.GetStereoRendering();
int stereoType = renderAtts.GetStereoType();
if ((viswin->GetStereo() != stereo) || (viswin->GetStereoType() != stereoType))
viswin->SetStereoRendering(stereo, stereoType);
......@@ -4771,6 +4771,7 @@ NetworkManager::ExportSingleDatabase(int id, const ExportDBAttributes &atts)
}
CATCH2(VisItException, e)
{
(void)e;
delete wrtr;
RETHROW;
}
......@@ -6614,14 +6615,14 @@ NetworkManager::CreateNullDataWriter() const
//
// ****************************************************************************
size_t
int
NetworkManager::RenderingStages()
{
const std::vector<avtPlot_p>& imageBasedPlots
= renderState.windowInfo->imageBasedPlots;
// There is always one stage for rendering and two for composition.
size_t stages = 3;
int stages = 3;
stages += (renderState.shadowMap ? 2 : 0);
stages += (renderState.depthCues ? 1 : 0);
......
......@@ -598,7 +598,7 @@ class ENGINE_MAIN_API NetworkManager : public EngineBase
void RenderCleanup();
size_t RenderingStages();
int RenderingStages();
virtual void StartTimer();
virtual void StopTimer();
......
......@@ -48,7 +48,10 @@
#include <cstdlib>
#include <avtImage.h>
#ifndef _MSC_VER
#ifdef _MSC_VER
#define __restrict__ __restrict
#pragma warning(disable : 4351)
#else
#define THREADED_COMPOSITER
#endif
#ifdef THREADED_COMPOSITER
......@@ -115,7 +118,7 @@ class CompositerThreadManager;
// ****************************************************************************
template <typename T>
class AVTFILTERS_API ProgrammableCompositer
class ProgrammableCompositer
{
public:
ProgrammableCompositer();
......@@ -151,7 +154,7 @@ public:
void ApplyBackgroundImage(const unsigned char *argba);
void SetBlockSize(int s){ blocking = s; }
void SetBlockSize(size_t s){ blocking = s; }
void SetBroadcastColor(bool abcast)
{ bcastrgba = abcast; }
......@@ -183,7 +186,7 @@ private:
T bgrgba[4]; // background color
int w; // input,output,bg image size
int h;
int blocking; // communication is made in chunks of this size
size_t blocking; // communication is made in chunks of this size
bool ownin; // if set free input image
bool ownout; // if set free output image
bool ownbg; // if set free background image
......@@ -237,9 +240,9 @@ typedef std::pair<int,int> RankPair;
typedef std::vector<RankPair> Iteration;
typedef std::vector<Iteration> Program;
AVTFILTERS_API void printProgram(Program &prog);
AVTFILTERS_API Program makeProgram(const RankOrdering &o);
AVTFILTERS_API std::ostream &operator<<(std::ostream &os, const RankPair &p);
void printProgram(Program &prog);
Program makeProgram(const RankOrdering &o);
std::ostream &operator<<(std::ostream &os, const RankPair &p);
// --------------------------------------------------------------------------
template <typename T>
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment