Commit 7d7433bd authored by Siqi Ling's avatar Siqi Ling

follow last submit message

parent da186244
......@@ -44,7 +44,6 @@
#include "detail/ReaderWriter.h"
#include "boost/filesystem.hpp"
namespace AMDiS
{
......@@ -62,9 +61,8 @@ namespace AMDiS
void readFile(std::string filename,
Container &container)
{
using boost::filesystem::path;
std::string ext = filename.substr(filename.find_last_of("."));
std::string ext = path(filename).extension().string();
Mesh* mesh = detail::getMesh(container);
if (ext == ".1d" || ext == ".2d" || ext == ".3d")
{
......@@ -132,9 +130,8 @@ namespace AMDiS
void readFile(std::string filename,
Mesh *mesh)
{
using boost::filesystem::path;
std::string ext = path(filename).extension().string();
std::string ext = filename.substr(filename.find_last_of("."));
if (ext == ".1d" || ext == ".2d" || ext == ".3d")
{
std::string periodicFilename = "";
......
......@@ -44,7 +44,6 @@
#include "detail/ReaderWriter.h"
#include "boost/filesystem.hpp"
namespace AMDiS
{
......@@ -64,10 +63,9 @@ namespace AMDiS
template<typename Container>
void writeFile(Container &container,
std::string filename)
{
using boost::filesystem::path;
std::string ext = path(filename).extension().string();
{
std::string ext = filename.substr(filename.find_last_of("."));
if (ext == ".1d" || ext == ".2d" || ext == ".3d")
{
DataCollector<double> dc(detail::getFeSpace(container, 0),
......
......@@ -121,7 +121,7 @@ namespace AMDiS
if(zlib) {
#ifdef HAVE_COMPRESSION
string s = input.substr(0, 6);
string s = input.substr(0, 8);
s = detail::base64ToStr(s);
tmp = const_cast<char*>(s.c_str());
ptr = reinterpret_cast<int*>(tmp);
......
......@@ -139,9 +139,13 @@ namespace AMDiS { namespace io {
path pvd_path = animationFilename;
path::iterator it_vtu, it_pvd;
#if (BOOST_VERSION < 104800)
path vtu_path0 = complete(vtu_path); vtu_path0.remove_filename();
path pvd_path0 = complete(pvd_path); pvd_path0.remove_filename();
#else
path vtu_path0 = absolute(vtu_path); vtu_path0.remove_filename();
path pvd_path0 = absolute(pvd_path); pvd_path0.remove_filename();
#endif
// find matching root directories
for (it_vtu = vtu_path0.begin(), it_pvd = pvd_path0.begin();
it_vtu != vtu_path0.end() && it_pvd != pvd_path0.end() && *it_vtu == *it_pvd;
......
......@@ -158,8 +158,8 @@ namespace AMDiS { namespace io {
dataBase64Vec[valueSize + 1] = getStreamData();
//DataArray
uint32_t tmp32 = 0;
for (int i = 0; i < nElements; i++) {
tmp32 = (i + 1) * vertices;
for (int i = 1; i <= nElements; i++) {
tmp32 = i * vertices;
bstream << tmp32;
}
dataBase64Vec[valueSize + 2] = getStreamData();
......
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