"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "pariso/commun.h" between
mathmod-10.1-source.zip and mathmod-11.0-source.zip

About: MathMod is a mathematical modeling software that visualize and animate implicit and parametric surfaces.

commun.h  (mathmod-10.1-source):commun.h  (mathmod-11.0-source)
/*************************************************************************** /***************************************************************************
* Copyright (C) 2020 by Abderrahman Taha * * Copyright (C) 2021 by Abderrahman Taha *
* * * *
* * * *
* This program is free software; you can redistribute it and/or modify * * This program is free software; you can redistribute it and/or modify *
* it under the terms of the GNU General Public License as published by * * it under the terms of the GNU General Public License as published by *
* the Free Software Foundation; either version 2 of the License, or * * the Free Software Foundation; either version 2 of the License, or *
* (at your option) any later version. * * (at your option) any later version. *
* * * *
* This program is distributed in the hope that it will be useful, * * This program is distributed in the hope that it will be useful, *
* but WITHOUT ANY WARRANTY; without even the implied warranty of * * but WITHOUT ANY WARRANTY; without even the implied warranty of *
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
skipping to change at line 138 skipping to change at line 138
DEFINED_PARAM_GRID_TRIANGLE_TAB_OVERFLOW, DEFINED_PARAM_GRID_TRIANGLE_TAB_OVERFLOW,
GRID_SUPERIOR_TO_GRIDMAX, GRID_SUPERIOR_TO_GRIDMAX,
VECT_DIMENSION_ERROR, VECT_DIMENSION_ERROR,
MEM_OVERFLOW, MEM_OVERFLOW,
EMPTY_MANDATORY_FIELD EMPTY_MANDATORY_FIELD
}; };
struct ComponentInfos struct ComponentInfos
{ {
std::vector<uint> ParisoTriangle; std::vector<uint> ParisoTriangle;
std::vector<uint> ParisoVertex; std::vector<uint> ParisoVertex;
std::vector<uint> NbComponents; std::vector<uint> NbComponentsType;
std::vector<bool> ThereisCND; std::vector<bool> ThereisCND;
std::vector<bool> ThereisRGBA; std::vector<bool> ThereisRGBA;
std::vector<bool> ParisoCondition; std::vector<bool> ParisoCondition;
std::vector<bool> ShowParIsoCmp;
uint ParisoNbComponents = 1; uint ParisoNbComponents = 1;
uint ParisoCurrentComponentIndex = 0; uint ParisoCurrentComponentIndex = 0;
std::vector<uint> NbTrianglesVerifyCND; std::vector<uint> NbTrianglesVerifyCND;
std::vector<uint> NbTrianglesNoCND; std::vector<uint> NbTrianglesNoCND;
std::vector<uint> NbTrianglesNotVerifyCND; std::vector<uint> NbTrianglesNotVerifyCND;
std::vector<uint> NbTrianglesBorderCND; std::vector<uint> NbTrianglesBorderCND;
NoiseParemeters NoiseParam[2]; NoiseParemeters NoiseParam[2];
bool Interleave = false; bool Interleave = false;
skipping to change at line 164 skipping to change at line 165
bool updateviewer = false; bool updateviewer = false;
}; };
struct ObjectProperties struct ObjectProperties
{ {
float *ArrayNorVer_localPt; float *ArrayNorVer_localPt;
uint *PolyIndices_localPt; uint *PolyIndices_localPt;
uint *PolyIndices_localPtMin; uint *PolyIndices_localPtMin;
int *TypeSurfaceTriangleListeCND; int *TypeSurfaceTriangleListeCND;
uint NbPolygnNbVertexPtMin = 0; uint NbPolygnNbVertexPtMin = 0;
uint NbPolygnNbVertexPtMinSize = 0;
uint PolyNumber = 0; uint PolyNumber = 0;
uint VertxNumber = 0; uint VertxNumber = 0;
uint NbBorderpoints; uint NbBorderpoints;
struct ComponentInfos componentsinfos; struct ComponentInfos componentsinfos;
int IndexCurrentFormula = -1; int IndexCurrentFormula = -1;
bool ShininessValUpdated=true;
bool AmbientValUpdated=true;
bool DiffuseValUpdated=true;
int border = 1; int border = 1;
int anim = -1; int anim = -1;
int animxyz = 1; int animxyz = 1;
int animx = -1; int animx = -1;
int animy = -1; int animy = -1;
int animz = -1; int animz = -1;
float animxValue = 0.0; float animxValue = 0.0;
float animyValue = 0.0; float animyValue = 0.0;
float animzValue = 0.0; float animzValue = 0.0;
float animxValueStep = 0.0; float animxValueStep = 0.0;
float animyValueStep = 0.0; float animyValueStep = 0.0;
float animzValueStep = 0.0; float animzValueStep = 0.0;
int slider = -1; int slider = -1;
int morph = -1; int morph = -1;
int morphstep = -1; int morphstep = -1;
int typedrawing = 1; int typedrawing = 1;
int mesh = 1; int mesh = 1;
int fill = 1; int fill = 1;
int smoothline = -1;
int transparency = -1; int transparency = -1;
int boundingbox = -1; int boundingbox = -1;
bool activarecnd = true; bool activarecnd = true;
bool updategl = true; bool updategl = true;
int triangles = -1; int triangles = -1;
int infos = 1; int infos = -1;
int frame = -1; int frame = -1;
int infosdetails[3]={1, 1, 1}; int infosdetails[3]={1, 1, 1};
int line = 1; int line = 1;
int norm = -1; int norm = -1;
int plan = 1; int plan = 1;
int axe = 1;
int attachwininfos = 1;
int png_ok = 1; int png_ok = 1;
int jpg_ok = -1; int jpg_ok = -1;
int bmp_ok = -1; int bmp_ok = -1;
int quality_image = 50; int quality_image = 50;
int colortype = 0; int colortype = 0;
int colortypeParam = 0; int colortypeParam = 0;
uint gridplanliste = 1; float specReflection[4]={0.2f, 0.2f, 0.2f, 1.0f};
float specReflection[4]={0.3f, 0.3f, 0.3f, 1.0f};
int threads[3]; int threads[3];
int shininess = 110; int shininess = 110;
float frontcol[4]={0.9f, 0.6f, 0.1f, 1.0f}; float frontcol[4]={0.9f, 0.5f, 0.1f, 1.0f};
float backcol[4] ={0.2f, 0.8f, 0.1f, 1.0f}; float backcol[4] ={0.2f, 0.8f, 0.1f, 1.0f};
float frontcols[40]={0.9f, 0.6f, 0.1f, 1.0f, 0.3f, 0.8f, 0.5f, 1.0f, 0.2f, 0 .5f, 0.6f, 1.0f, 0.1f, 0.3f, 0.9f, 1.0f, 0.96f, 0.71f, 0.3f, 1.0f, float frontcols[40]={0.72f, 0.5f, 0.1f, 1.0f, 0.3f, 0.8f, 0.5f, 1.0f, 0.2f, 0.5f, 0.6f, 1.0f, 0.1f, 0.3f, 0.9f, 1.0f, 0.96f, 0.71f, 0.3f, 1.0f,
0.4f, 0.4f, 0.9f, 1.0f, 0.99f, 0.1f, 0.843f, 1.0f, 0.1 6f, 0.91f, 0.73f, 1.0f, 0.8f, 0.9f, 0.0f, 1.0f, 0.9f, 0.91f, 0.3f, 1.0f}; 0.4f, 0.4f, 0.9f, 1.0f, 0.99f, 0.1f, 0.843f, 1.0f, 0.1 6f, 0.91f, 0.73f, 1.0f, 0.8f, 0.9f, 0.0f, 1.0f, 0.9f, 0.91f, 0.3f, 1.0f};
float backcols[40]={0.4f, 0.6f, 0.1f, 1.0f, 0.6f, 0.6f, 0.9f, 1.0f, 0.8f, 0. 6f, 0.3f, 1.0f, 0.9f, 0.8f, 0.6f, 1.0f, 0.93f, 0.2f, 0.1f, 1.0f, float backcols[40]={0.4f, 0.6f, 0.1f, 1.0f, 0.6f, 0.6f, 0.9f, 1.0f, 0.8f, 0. 6f, 0.3f, 1.0f, 0.9f, 0.8f, 0.6f, 1.0f, 0.93f, 0.2f, 0.1f, 1.0f,
0.3f, 0.72f, 0.63f, 1.0f, 0.1f, 0.5f, 0.73f, 1.0f, 0.9f, 0.5f, 0.3f, 1.0f, 0.8f, 0.8f, 0.6f, 1.0f, 0.7f, 0.9f, 0.93f, 1.0f}; 0.3f, 0.72f, 0.63f, 1.0f, 0.1f, 0.5f, 0.73f, 1.0f, 0.9f, 0.5f, 0.3f, 1.0f, 0.8f, 0.8f, 0.6f, 1.0f, 0.7f, 0.9f, 0.93f, 1.0f};
float gridcol[4] ={0.1f, 0.3f, 0.1f, 0.2f}; float gridcol[4] ={0.25f, 0.2f, 0.0f, 0.08f};
float groundcol[4]={0.0f, 0.0f, 0.0f, 1.0f}; float groundcol[4]={0.0f, 0.0f, 0.0f, 1.0f};
float polyfactor= 1.0; float polyfactor= 1.0;
float polyunits= 1.0; float polyunits= 1.0;
float RotStrength=0; float RotStrength=0;
float oldRotx, oldRoty; float oldRotx, oldRoty;
float zminim= -350.0f; float zminim= -350.0f;
float BoxLimits[3][6]; float BoxLimits[3][6];
int viewport[4]; int viewport[4];
double matrix[16]; double matrix[16];
double matrixInverse[16]; double matrixInverse[16];
double ScalCoeff = 1.0; double ScalCoeff = 1.0;
double axe_x, axe_y, axe_z; double axe_x, axe_y, axe_z;
double view_rotx = 90.0, view_roty = 90.0, view_rotz = 1.0; double view_rotx = 90.0, view_roty = 90.0, view_rotz = 1.0;
bool cndoptions[5] = {true, true, true, false, false}; bool cndoptions[5] = {true, true, true, false, false};
uint vboId_ArrayNorVer_localPt;
uint vboId_PolyIndices_localPt;
}; };
class CellNoise class CellNoise
{ {
public: public:
float rd[3], featurePoint[4]; float rd[3], featurePoint[4];
const static uint OFFSET_BASIS = 2166136261U; const static uint OFFSET_BASIS = 2166136261U;
const static uint FNV_PRIME = 16777619U; const static uint FNV_PRIME = 16777619U;
float CellNoiseFunc(float, float, float, int, int type = 2, int Dist = 0); float CellNoiseFunc(float, float, float, int, int type = 2, int Dist = 0);
skipping to change at line 266 skipping to change at line 273
float fade(float); float fade(float);
float lerp(float, float, float); float lerp(float, float, float);
float grad(int, float, float, float); float grad(int, float, float, float);
float FractalNoise3D(float, float, float, int, float, float); float FractalNoise3D(float, float, float, int, float, float);
float Marble(float, float, float, int); float Marble(float, float, float, int);
float lookup(float, float, float); float lookup(float, float, float);
}; };
extern std::vector<float> NormVertexTabVector; extern std::vector<float> NormVertexTabVector;
extern std::vector<uint> IndexPolyTabMinVector; extern std::vector<uint> IndexPolyTabMinVector;
extern std::vector<uint> IndexPolyTabMinVector2;
extern std::vector<uint> IndexPolyTabVector; extern std::vector<uint> IndexPolyTabVector;
static struct ComponentInfos *components = new (struct ComponentInfos); static struct ComponentInfos *components = new (struct ComponentInfos);
 End of changes. 14 change blocks. 
9 lines changed or deleted 17 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)