Skip to content

Commit 648d927

Browse files
authored
Merge branch 'master' into ci-no-vksdk
2 parents 6371ff0 + 96a5c46 commit 648d927

2 files changed

Lines changed: 9 additions & 8 deletions

File tree

.github/workflows/scripts/common-utils.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ function set-git-caching-proxy {
1414
# git config --global --add url.http://oauth2:$GITHUB_TOKEN@git-cdn-github.botmaster.tgr/.insteadOf https://github.com/
1515
# git config --global --add url.http://oauth2:$GITHUB_TOKEN@git-cdn-github.botmaster.tgr/.insteadOf git@github.com:
1616
git config --global https.proxy http://proxy.tgr:18000 || true
17+
1718
}
1819

1920
if [ ! -z "$TI_USE_GIT_CACHE" ]; then

taichi/util/image_buffer.cpp

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
namespace taichi {
1919

2020
template <typename T>
21-
void Array2D<T>::load_image(const std::string &filename, bool linearize) {
21+
void ArrayND<2, T>::load_image(const std::string &filename, bool linearize) {
2222
int channels;
2323
FILE *f = fopen(filename.c_str(), "rb");
2424
TI_ASSERT_INFO(f != nullptr, "Image file not found: " + filename);
@@ -57,7 +57,7 @@ void Array2D<T>::load_image(const std::string &filename, bool linearize) {
5757
}
5858

5959
template <typename T>
60-
void Array2D<T>::write_as_image(const std::string &filename) {
60+
void ArrayND<2, T>::write_as_image(const std::string &filename) {
6161
int comp = 3;
6262
std::vector<unsigned char> data(this->res[0] * this->res[1] * comp);
6363
for (int i = 0; i < this->res[0]; i++) {
@@ -97,12 +97,12 @@ std::map<std::string, stbtt_fontinfo> fonts;
9797
std::map<std::string, std::vector<uint8>> font_buffers;
9898

9999
template <typename T>
100-
void Array2D<T>::write_text(const std::string &font_fn,
101-
const std::string &content_,
102-
real size,
103-
int dx,
104-
int dy,
105-
T color) {
100+
void ArrayND<2, T>::write_text(const std::string &font_fn,
101+
const std::string &content_,
102+
real size,
103+
int dx,
104+
int dy,
105+
T color) {
106106
std::vector<unsigned char> screen_buffer(
107107
(size_t)(this->res[0] * this->res[1]), (unsigned char)0);
108108

0 commit comments

Comments
 (0)