Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Fix cpu bubblechart & surface data consistent in all computes #222

Merged
merged 2 commits into from
Jan 27, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/unix_build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ jobs:
if: matrix.os == 'macos-latest'
run: |
brew install boost fontconfig freeimage
brew cask install xquartz
brew install --cask xquartz
echo "CMAKE_PROGRAM=cmake" >> $GITHUB_ENV

- name: Install Common Dependencies for Ubuntu
Expand Down
3 changes: 2 additions & 1 deletion examples/cpu/bubblechart.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,8 @@ int main(void) {
std::vector<float> radii(tanData.size());

std::generate(colors.begin(), colors.end(), clr);
std::generate(radii.begin(), radii.end(), rnd);
std::generate(radii.begin(), radii.end(),
[&] { return 20.0f + 60.0f * rnd(); });
std::generate(alphas.begin(), alphas.end(), alp);

/*
Expand Down
10 changes: 5 additions & 5 deletions examples/cpu/surface.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,12 @@

using namespace std;

static const float XMIN = -32.0f;
static const float XMAX = 32.0f;
static const float YMIN = -32.0f;
static const float YMAX = 32.0f;
static const float XMIN = -8.0f;
static const float XMAX = 8.0f;
static const float YMIN = -8.0f;
static const float YMAX = 8.0f;

const float DX = 0.25;
const float DX = 0.5;
const size_t XSIZE = (size_t)((XMAX - XMIN) / DX);
const size_t YSIZE = (size_t)((YMAX - YMIN) / DX);

Expand Down