Skip to content

Commit 4402301

Browse files
committed
Merge branch 'master' into linux_release
2 parents 754b609 + 83e6ed9 commit 4402301

File tree

3 files changed

+14
-50
lines changed

3 files changed

+14
-50
lines changed

Diff for: .readthedocs.yml

+7-4
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,12 @@ version: 2
1313
formats:
1414
- pdf
1515
- htmlzip
16+
17+
build:
18+
os: "ubuntu-22.04"
19+
tools:
20+
python: "3.11"
1621

17-
# Optionally set the version of Python and requirements required to build your docs
18-
python:
19-
version: 3.7
22+
python:
2023
install:
21-
- requirements: Docs/requirements.txt
24+
- requirements: Docs/requirements.txt

Diff for: Docs/conf.py

+1-40
Original file line numberDiff line numberDiff line change
@@ -127,46 +127,7 @@
127127
# The theme to use for HTML and HTML Help pages. See the documentation for
128128
# a list of builtin themes.
129129
#
130-
#html_theme = 'alabaster'
131-
132-
# on_rtd is whether we are on readthedocs.org, this line of code grabbed from docs.readthedocs.org
133-
on_rtd = os.environ.get('READTHEDOCS', None) == 'True'
134-
135-
if not on_rtd: # only import and set the theme if we're building docs locally
136-
import sphinx_rtd_theme
137-
html_theme = 'sphinx_rtd_theme'
138-
html_theme_path = [sphinx_rtd_theme.get_html_theme_path()]
139-
140-
# otherwise, readthedocs.org uses their theme by default, so no need to specify it
141-
142-
# Theme options are theme-specific and customize the look and feel of a theme
143-
# further. For a list of options available for each theme, see the
144-
# documentation.
145-
#
146-
# html_theme_options = {}
147-
148-
# Add any paths that contain custom themes here, relative to this directory.
149-
# html_theme_path = []
150-
151-
# The name for this set of Sphinx documents.
152-
# "<project> v<release> documentation" by default.
153-
#
154-
# html_title = u'I-Simpa v1.3'
155-
156-
# A shorter title for the navigation bar. Default is the same as html_title.
157-
#
158-
# html_short_title = None
159-
160-
# The name of an image file (relative to this directory) to place at the top
161-
# of the sidebar.
162-
#
163-
# html_logo = None
164-
165-
# The name of an image file (relative to this directory) to use as a favicon of
166-
# the docs. This file should be a Windows icon file (.ico) being 16x16 or 32x32
167-
# pixels large.
168-
#
169-
# html_favicon = None
130+
html_theme = 'sphinx_rtd_theme'
170131

171132
# Add any paths that contain custom static files (such as style sheets) here,
172133
# relative to this directory. They are copied after the builtin static files,

Diff for: src/spps/input_output/reportmanager.cpp

+6-6
Original file line numberDiff line numberDiff line change
@@ -184,10 +184,10 @@ void ReportManager::ParticuleFreeTranslation(CONF_PARTICULE& particleInfos, cons
184184
vec3 normal=(*itrs)->planeNormal;
185185
if(particleInfos.direction.dot(normal)<0) //si la face du recepteur est orient�e dans l'autre direction on inverse la normal
186186
normal*=-1;
187-
if(*(this->paramReport.configManager->FastGetConfigValue(Core_Configuration::I_PROP_SURFACE_RECEIVER_MODE))==0)
188-
(*itrs)->data[particleInfos.frequenceIndex][CellRow][CellCol][particleInfos.pasCourant]+=particleInfos.energie*cosf(normal.angle(particleInfos.direction));
187+
if (*(this->paramReport.configManager->FastGetConfigValue(Core_Configuration::I_PROP_SURFACE_RECEIVER_MODE)) == 0)
188+
(*itrs)->data[particleInfos.frequenceIndex][CellRow][CellCol][particleInfos.pasCourant] += particleInfos.energie;
189189
else
190-
(*itrs)->data[particleInfos.frequenceIndex][CellRow][CellCol][particleInfos.pasCourant]+=particleInfos.energie;
190+
(*itrs)->data[particleInfos.frequenceIndex][CellRow][CellCol][particleInfos.pasCourant]+=particleInfos.energie / max(cosf(normal.angle(particleInfos.direction)), 0.000000001f);
191191
}
192192
}
193193
}
@@ -278,10 +278,10 @@ void ReportManager::ParticuleCollideWithSceneMesh(CONF_PARTICULE& particleInfos)
278278
if(particleInfos.direction.dot(normal)<0) //If the receiver surface is on the other side then revert the normal
279279
normal*=-1;
280280
//Add particle energy to receiver
281-
if(*(this->paramReport.configManager->FastGetConfigValue(Core_Configuration::I_PROP_SURFACE_RECEIVER_MODE))==0)
282-
face->recepteurS->energieRecu[particleInfos.frequenceIndex][particleInfos.pasCourant]+=particleInfos.energie*cosf(normal.angle(particleInfos.direction));
281+
if (*(this->paramReport.configManager->FastGetConfigValue(Core_Configuration::I_PROP_SURFACE_RECEIVER_MODE)) == 0)
282+
face->recepteurS->energieRecu[particleInfos.frequenceIndex][particleInfos.pasCourant] += particleInfos.energie;
283283
else
284-
face->recepteurS->energieRecu[particleInfos.frequenceIndex][particleInfos.pasCourant]+=particleInfos.energie;
284+
face->recepteurS->energieRecu[particleInfos.frequenceIndex][particleInfos.pasCourant] += particleInfos.energie / max(cosf(normal.angle(particleInfos.direction)), 0.000000001f);
285285
}
286286
}
287287

0 commit comments

Comments
 (0)