From 652f17b39058c3c21e6c5ba12ff0aa04fe704f7a Mon Sep 17 00:00:00 2001 From: Mira Grudzinska Date: Sat, 7 Jan 2023 00:53:23 +0100 Subject: [PATCH 01/16] svg_loader: fixing name _parserColor -> _parseColor Change-Id: I6d68fe18ff6a8029627bd42b409be1048ef3516a --- src/loaders/svg/tvgSvgLoader.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/loaders/svg/tvgSvgLoader.cpp b/src/loaders/svg/tvgSvgLoader.cpp index 9b82ebd..31c1450 100644 --- a/src/loaders/svg/tvgSvgLoader.cpp +++ b/src/loaders/svg/tvgSvgLoader.cpp @@ -374,7 +374,7 @@ static char* _idFromUrl(const char* url) } -static unsigned char _parserColor(const char* value, char** end) +static unsigned char _parseColor(const char* value, char** end) { float r; @@ -584,11 +584,11 @@ static void _toColor(const char* str, uint8_t* r, uint8_t* g, uint8_t* b, char** *b = strtol(tmp, nullptr, 16); } } else if (len >= 10 && (str[0] == 'r' || str[0] == 'R') && (str[1] == 'g' || str[1] == 'G') && (str[2] == 'b' || str[2] == 'B') && str[3] == '(' && str[len - 1] == ')') { - tr = _parserColor(str + 4, &red); + tr = _parseColor(str + 4, &red); if (red && *red == ',') { - tg = _parserColor(red + 1, &green); + tg = _parseColor(red + 1, &green); if (green && *green == ',') { - tb = _parserColor(green + 1, &blue); + tb = _parseColor(green + 1, &blue); if (blue && blue[0] == ')' && blue[1] == '\0') { *r = tr; *g = tg; -- 2.7.4 From c55a861c390f9a002b2d2b82fa53c445742d7ebd Mon Sep 17 00:00:00 2001 From: jykeon Date: Tue, 14 Mar 2023 18:21:59 +0900 Subject: [PATCH 02/16] Bump up 0.8.7 Change-Id: I97bb1f3bdb6978d3e8ccc56e734177657c55ec48 Signed-off-by: jykeon --- packaging/thorvg.spec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packaging/thorvg.spec b/packaging/thorvg.spec index e66b103..aecaafa 100644 --- a/packaging/thorvg.spec +++ b/packaging/thorvg.spec @@ -1,6 +1,6 @@ Name: thorvg Summary: Thor Vector Graphics Library -Version: 0.8.6 +Version: 0.8.7 Release: 1 Group: Graphics System/Rendering Engine License: MIT -- 2.7.4 From 7963f1b72f0e0995e504809872a8dc0c835030d9 Mon Sep 17 00:00:00 2001 From: Mira Grudzinska Date: Sat, 7 Jan 2023 00:47:59 +0100 Subject: [PATCH 03/16] all: Trailing spaces removed Change-Id: I09f10f1b342b352c39cce734a2fce5d93091a9d0 --- CONTRIBUTING.md | 32 +++++++-------- inc/thorvg.h | 30 +++++++------- src/bin/svg2tvg/svg2tvg.cpp | 2 +- src/examples/all.sh | 22 ++++++++++ src/lib/gl_engine/tvgGlGeometry.h | 2 +- src/lib/sw_engine/tvgSwImage.cpp | 4 +- src/lib/sw_engine/tvgSwRasterNeon.h | 2 +- src/lib/sw_engine/tvgSwRasterTexmap.h | 4 +- src/lib/tvgBezier.cpp | 2 +- src/lib/tvgBinaryDesc.h | 2 +- src/lib/tvgLzw.cpp | 4 +- src/lib/tvgMath.h | 2 +- src/lib/tvgPictureImpl.h | 1 - src/loaders/jpg/tvgJpgd.cpp | 32 +++++++-------- src/loaders/png/tvgLodePng.cpp | 4 +- test/capi/capiFill.cpp | 8 ++-- test/testAccessor.cpp | 77 +++++++++++++++++++++++++++++++++++ 17 files changed, 164 insertions(+), 66 deletions(-) create mode 100755 src/examples/all.sh create mode 100644 test/testAccessor.cpp diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 8205ff5..b06e3cb 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -42,7 +42,7 @@ If your change don't belonged to any sub modules, you can replace with proper na The name must be written in all lower alphabet characters. - ex) build / doc / infra / common / sw_engine / gl_engine / svg_loader / examples / wasm / svg2png ... -- [Feature] is what major function/feature you changed. Normally this indicates a representive file name. +- [Feature] is what major function/feature you changed. Normally this indicates a representive file name. You can keep the file name, but don't please contain any prefix(tvg) nor suffix(Impl) here. - ex) Canvas / TaskScehduler / SvgLoader / SvgBuilder / SwRle / GlRenderer / ... @@ -51,51 +51,51 @@ You can keep the file name, but don't please contain any prefix(tvg) nor suffix( - ex) "Fixed compile warnings" - ex) "Code refactoring" - ex) "Fixed a rendering bug that overlapped shapes inproper way." - + - [Description] There is no any strict formats, but it must describe what you did in this patch as far as possible you can describe in detail. If you fixed any bugs, it must contain below: - - what type of bug + - what type of bug - conditions to reproduce it - root cause - - solution - + - solution + Or if you add a new feature or function, it must contain below: - what sort of features - api full specification (if any api additions) - any necessity - - condition / restriction + - condition / restriction - reference or sample - + Lastly, please append any issue ticket numbers in this section if any. - - + + - Here is a overall commit message what we expect to review: - + - common composite: newly added path clipping feature We introduced new method Paint::composite() to support composite behaviors.
This allows paints to composite with other paints instances.
Composite behaviors depend on its composite method type.
- Here we firstly introduced "ClipPath" method to support clipping by path unit of paint.
- + Here we firstly introduced "ClipPath" method to support clipping by path unit of paint.
+ tagetPaint->composite(srcPaint, CompositeMethod::ClipPath);
- + Beaware if the source paint doesn't contain any path info, clipping won't be applied as you expected. - + @API Additions:
enum CompositeMethod {None = 0, ClipPath};
Result Paint::composite(std::unique_ptr target, CompositeMethod method) const noexcept;
@Examples: added ClipPath
- + @References: any links to the references such as screenshot images. @Issues: 49
## Pull Request - + Once you submitted a pull request(PR), please make it sure below check list. - Reviewers: Check Reviewers List - Assignees: You diff --git a/inc/thorvg.h b/inc/thorvg.h index 1429839..594fe9b 100644 --- a/inc/thorvg.h +++ b/inc/thorvg.h @@ -186,10 +186,10 @@ struct Matrix /** * @brief A data structure representing a texture mesh vertex - * + * * @param pt The vertex coordinate * @param uv The normalized texture coordinate in the range (0.0..1.0, 0.0..1.0) - * + * * @BETA_API */ struct Vertex @@ -201,9 +201,9 @@ struct Vertex /** * @brief A data structure representing a triange in a texture mesh - * + * * @param vertex The three vertices that make up the polygon - * + * * @BETA_API */ struct Polygon @@ -1197,38 +1197,38 @@ public: /** * @brief Sets or removes the triangle mesh to deform the image. - * + * * If a mesh is provided, the transform property of the Picture will apply to the triangle mesh, and the * image data will be used as the texture. - * + * * If @p triangles is @c nullptr, or @p triangleCnt is 0, the mesh will be removed. - * + * * Only raster image types are supported at this time (png, jpg). Vector types like svg and tvg do not support. * mesh deformation. However, if required you should be able to render a vector image to a raster image and then apply a mesh. - * + * * @param[in] triangles An array of Polygons(triangles) that make up the mesh, or null to remove the mesh. * @param[in] triangleCnt The number of Polygons(triangles) provided, or 0 to remove the mesh. - * + * * @retval Result::Success When succeed. * @retval Result::Unknown If fails - * + * * @note The Polygons are copied internally, so modifying them after calling Mesh::mesh has no affect. * @warning Please do not use it, this API is not official one. It could be modified in the next version. - * + * * @BETA_API */ Result mesh(const Polygon* triangles, const uint32_t triangleCnt) noexcept; /** * @brief Return the number of triangles in the mesh, and optionally get a pointer to the array of triangles in the mesh. - * + * * @param[out] triangles Optional. A pointer to the array of Polygons used by this mesh. - * + * * @return uint32_t The number of polygons in the array. - * + * * @note Modifying the triangles returned by this method will modify them directly within the mesh. * @warning Please do not use it, this API is not official one. It could be modified in the next version. - * + * * @BETA_API */ uint32_t mesh(const Polygon** triangles) const noexcept; diff --git a/src/bin/svg2tvg/svg2tvg.cpp b/src/bin/svg2tvg/svg2tvg.cpp index c2788f3..fad70a4 100644 --- a/src/bin/svg2tvg/svg2tvg.cpp +++ b/src/bin/svg2tvg/svg2tvg.cpp @@ -38,7 +38,7 @@ void helpMsg() bool convert(string& in, string& out) { if (Initializer::init(CanvasEngine::Sw, 0) != Result::Success) return false; - + auto picture = Picture::gen(); if (picture->load(in) != Result::Success) return false; diff --git a/src/examples/all.sh b/src/examples/all.sh new file mode 100755 index 0000000..992752b --- /dev/null +++ b/src/examples/all.sh @@ -0,0 +1,22 @@ +#!/bin/bash +RED='\033[31m' +GREEN='\033[32m' +NC='\033[0m' + +INTERVAL=${1:-1} +EXAMPLES=`find . -executable -type f | sort | uniq` +for EXAMPLE in $EXAMPLES +do + if [[ $EXAMPLE == *.sh ]]; then + continue + fi + + echo -e "Execute: "${GREEN}$EXAMPLE${NC}" for "$INTERVAL" second(s)" + $EXAMPLE & + EXAMPLE_PID=$! + sleep $INTERVAL + kill -s SIGTERM $EXAMPLE_PID + if [ $? -ne 0 ]; then + echo -e "Something wrong with: "${RED}$EXAMPLE${NC} + fi +done diff --git a/src/lib/gl_engine/tvgGlGeometry.h b/src/lib/gl_engine/tvgGlGeometry.h index 7c9dbe4..79ffeb9 100644 --- a/src/lib/gl_engine/tvgGlGeometry.h +++ b/src/lib/gl_engine/tvgGlGeometry.h @@ -96,7 +96,7 @@ public: bool operator== (const GlPoint& rhs) { - if (&rhs == this) return true; + if (&rhs == this) return true; if (rhs.x == this->x && rhs.y == this->y) return true; return false; } diff --git a/src/lib/sw_engine/tvgSwImage.cpp b/src/lib/sw_engine/tvgSwImage.cpp index a1b8960..2b139a7 100644 --- a/src/lib/sw_engine/tvgSwImage.cpp +++ b/src/lib/sw_engine/tvgSwImage.cpp @@ -53,9 +53,9 @@ static bool _genOutline(SwImage* image, Polygon* triangles, uint32_t triangleCou Point to[4]; if (triangleCount > 0) { - // TODO: Optimise me. We appear to calculate this exact min/max bounding area in multiple + // TODO: Optimise me. We appear to calculate this exact min/max bounding area in multiple // places. We should be able to re-use one we have already done? Also see: - // tvgPictureImpl.h --> bounds + // tvgPictureImpl.h --> bounds // tvgSwRasterTexmap.h --> _rasterTexmapPolygonMesh // // TODO: Should we calculate the exact path(s) of the triangle mesh instead? diff --git a/src/lib/sw_engine/tvgSwRasterNeon.h b/src/lib/sw_engine/tvgSwRasterNeon.h index a4b3cda..4ce60c5 100644 --- a/src/lib/sw_engine/tvgSwRasterNeon.h +++ b/src/lib/sw_engine/tvgSwRasterNeon.h @@ -116,7 +116,7 @@ static bool neonRasterTranslucentRect(SwSurface* surface, const SwBBox& region, for (uint32_t x = 0; x < (w - align) / 2; ++x) vDst[x] = vadd_u8((uint8x8_t)vColor, ALPHA_BLEND(vDst[x], vIalpha)); - + auto leftovers = (w - align) % 2; if (leftovers > 0) dst[w - 1] = color + ALPHA_BLEND(dst[w - 1], ialpha); } diff --git a/src/lib/sw_engine/tvgSwRasterTexmap.h b/src/lib/sw_engine/tvgSwRasterTexmap.h index 32a772e..9aebaaf 100644 --- a/src/lib/sw_engine/tvgSwRasterTexmap.h +++ b/src/lib/sw_engine/tvgSwRasterTexmap.h @@ -517,7 +517,7 @@ static bool _apply(SwSurface* surface, AASpans* aaSpans) dst = surface->buffer + (offset + line->x[1] - 1); if (line->x[1] < (int32_t)(surface->w - 1)) pixel = *(dst + 1); else pixel = *dst; - + pos = width; while ((int32_t)(width - line->length[1]) < pos) { *dst = INTERPOLATE(255 - (line->coverage[1] * (line->length[1] - (width - pos))), *dst, pixel); @@ -543,7 +543,7 @@ static bool _apply(SwSurface* surface, AASpans* aaSpans) 0 -- 1 | / | | / | - 3 -- 2 + 3 -- 2 */ static bool _rasterTexmapPolygon(SwSurface* surface, const SwImage* image, const Matrix* transform, const SwBBox* region, uint32_t opacity, uint32_t (*blendMethod)(uint32_t)) { diff --git a/src/lib/tvgBezier.cpp b/src/lib/tvgBezier.cpp index 95e2055..f26f74f 100644 --- a/src/lib/tvgBezier.cpp +++ b/src/lib/tvgBezier.cpp @@ -114,7 +114,7 @@ float bezAt(const Bezier& bz, float at) auto t = 0.5f; //just in case to prevent an infinite loop - if (at <= 0) return 0.0f; + if (at <= 0) return 0.0f; if (at >= len) return 1.0f; diff --git a/src/lib/tvgBinaryDesc.h b/src/lib/tvgBinaryDesc.h index bab6b79..a6a70a4 100644 --- a/src/lib/tvgBinaryDesc.h +++ b/src/lib/tvgBinaryDesc.h @@ -42,7 +42,7 @@ using TvgBinFlag = TvgBinByte; #define TVG_HEADER_VERSION_LENGTH 6 #define TVG_HEADER_RESERVED_LENGTH 1 //Storing flags for extensions #define TVG_HEADER_COMPRESS_SIZE 12 //TVG_HEADER_UNCOMPRESSED_SIZE + TVG_HEADER_COMPRESSED_SIZE + TVG_HEADER_COMPRESSED_SIZE_BITS -//Compress Size +//Compress Size #define TVG_HEADER_UNCOMPRESSED_SIZE 4 //SIZE (TvgBinCounter) #define TVG_HEADER_COMPRESSED_SIZE 4 //SIZE (TvgBinCounter) #define TVG_HEADER_COMPRESSED_SIZE_BITS 4 //SIZE (TvgBinCounter) diff --git a/src/lib/tvgLzw.cpp b/src/lib/tvgLzw.cpp index 1aaf378..964af08 100644 --- a/src/lib/tvgLzw.cpp +++ b/src/lib/tvgLzw.cpp @@ -258,8 +258,8 @@ struct Dictionary Dictionary() { - /* First 256 dictionary entries are reserved to the byte/ASCII range. - Additional entries follow for the character sequences found in the input. + /* First 256 dictionary entries are reserved to the byte/ASCII range. + Additional entries follow for the character sequences found in the input. Up to 4096 - 256 (MaxDictEntries - FirstCode). */ size = FirstCode; diff --git a/src/lib/tvgMath.h b/src/lib/tvgMath.h index 74f34fb..2cce318 100644 --- a/src/lib/tvgMath.h +++ b/src/lib/tvgMath.h @@ -118,7 +118,7 @@ static inline void mathScale(Matrix* m, float scale) static inline void mathTranslate(Matrix* m, float x, float y) { m->e13 = x; - m->e23 = y; + m->e23 = y; } diff --git a/src/lib/tvgPictureImpl.h b/src/lib/tvgPictureImpl.h index 8bbb745..172c6f6 100644 --- a/src/lib/tvgPictureImpl.h +++ b/src/lib/tvgPictureImpl.h @@ -173,7 +173,6 @@ struct Picture::Impl bool bounds(float* x, float* y, float* w, float* h) { if (triangleCnt > 0) { - Point min = { triangles[0].vertex[0].pt.x, triangles[0].vertex[0].pt.y }; Point max = { triangles[0].vertex[0].pt.x, triangles[0].vertex[0].pt.y }; diff --git a/src/loaders/jpg/tvgJpgd.cpp b/src/loaders/jpg/tvgJpgd.cpp index 56b40ac..f4b1d13 100644 --- a/src/loaders/jpg/tvgJpgd.cpp +++ b/src/loaders/jpg/tvgJpgd.cpp @@ -80,7 +80,7 @@ enum jpgd_status enum { JPGD_IN_BUF_SIZE = 8192, JPGD_MAX_BLOCKS_PER_MCU = 10, JPGD_MAX_HUFF_TABLES = 8, JPGD_MAX_QUANT_TABLES = 4, - JPGD_MAX_COMPONENTS = 4, JPGD_MAX_COMPS_IN_SCAN = 4, JPGD_MAX_BLOCKS_PER_ROW = 8192, JPGD_MAX_HEIGHT = 16384, JPGD_MAX_WIDTH = 16384 + JPGD_MAX_COMPONENTS = 4, JPGD_MAX_COMPS_IN_SCAN = 4, JPGD_MAX_BLOCKS_PER_ROW = 8192, JPGD_MAX_HEIGHT = 16384, JPGD_MAX_WIDTH = 16384 }; // Input stream interface. @@ -151,7 +151,7 @@ public: // If JPGD_SUCCESS is returned you may then call decode() on each scanline. int begin_decoding(); // Returns the next scan line. - // For grayscale images, pScan_line will point to a buffer containing 8-bit pixels (get_bytes_per_pixel() will return 1). + // For grayscale images, pScan_line will point to a buffer containing 8-bit pixels (get_bytes_per_pixel() will return 1). // Otherwise, it will always point to a buffer containing 32-bit RGBA pixels (A will always be 255, and get_bytes_per_pixel() will return 4). // Returns JPGD_SUCCESS if a scan line has been returned. // Returns JPGD_DONE if all scan lines have been returned. @@ -1246,7 +1246,7 @@ void jpeg_decoder::read_sof_marker() uint32_t num_left = get_bits(16); if (get_bits(8) != 8) stop_decoding(JPGD_BAD_PRECISION); /* precision: sorry, only 8-bit precision is supported right now */ - + m_image_y_size = get_bits(16); if ((m_image_y_size < 1) || (m_image_y_size > JPGD_MAX_HEIGHT)) stop_decoding(JPGD_BAD_HEIGHT); @@ -1326,7 +1326,7 @@ void jpeg_decoder::read_sos_marker() } num_left -= 3; - while (num_left) { /* read past whatever is num_left */ + while (num_left) { /* read past whatever is num_left */ get_bits(8); num_left--; } @@ -1411,7 +1411,7 @@ int jpeg_decoder::process_markers() stop_decoding(JPGD_UNEXPECTED_MARKER); break; } - default: { /* must be DNL, DHP, EXP, APPn, JPGn, COM, or RESn or APP0 */ + default: { /* must be DNL, DHP, EXP, APPn, JPGn, COM, or RESn or APP0 */ skip_variable_marker(); break; } @@ -1441,7 +1441,7 @@ void jpeg_decoder::locate_soi_marker() if (lastchar == 0xFF) { if (thischar == M_SOI) break; - else if (thischar == M_EOI) stop_decoding(JPGD_NOT_JPEG); // get_bits will keep returning M_EOI if we read past the end + else if (thischar == M_EOI) stop_decoding(JPGD_NOT_JPEG); // get_bits will keep returning M_EOI if we read past the end } } @@ -1460,7 +1460,7 @@ void jpeg_decoder::locate_sof_marker() switch (c) { case M_SOF2: m_progressive_flag = true; case M_SOF0: /* baseline DCT */ - case M_SOF1: { /* extended sequential DCT */ + case M_SOF1: { /* extended sequential DCT */ read_sof_marker(); break; } @@ -1671,7 +1671,7 @@ void jpeg_decoder::transform_mcu_expand(int mcu_row) JPGD_ASSERT(m_mcu_block_max_zag[mcu_block] >= 1); JPGD_ASSERT(m_mcu_block_max_zag[mcu_block] <= 64); - int max_zag = m_mcu_block_max_zag[mcu_block++] - 1; + int max_zag = m_mcu_block_max_zag[mcu_block++] - 1; if (max_zag <= 0) max_zag = 0; // should never happen, only here to shut up static analysis switch (s_max_rc[max_zag]) { @@ -1789,7 +1789,7 @@ void jpeg_decoder::load_next_row() p[0] = pDC[0]; memcpy(&p[1], &pAC[1], 63 * sizeof(jpgd_block_t)); - for (i = 63; i > 0; i--) { + for (i = 63; i > 0; i--) { if (p[g_ZAG[i]]) break; } @@ -1809,7 +1809,7 @@ void jpeg_decoder::load_next_row() if (++block_y_mcu_ofs == m_comp_v_samp[component_id]) { block_y_mcu_ofs = 0; block_x_mcu[component_id] += m_comp_h_samp[component_id]; - } + } } } if (m_freq_domain_chroma_upsample) transform_mcu_expand(mcu_row); @@ -1865,7 +1865,7 @@ void jpeg_decoder::process_restart() static inline int dequantize_ac(int c, int q) -{ +{ c *= q; return c; } @@ -1910,7 +1910,7 @@ void jpeg_decoder::decode_next_row() while (n--) p[g_ZAG[kt++]] = 0; } k += r; - } + } s = JPGD_HUFF_EXTEND(extra_bits, s); JPGD_ASSERT(k < 64); p[g_ZAG[k]] = static_cast(dequantize_ac(s, q[k])); //s * q[k]; @@ -2204,7 +2204,7 @@ int jpeg_decoder::decode(const void** pScan_line, uint32_t* pScan_line_len) } else *pScan_line = m_pScan_line_1; break; - } + } case JPGD_YH2V1: { H2V1Convert(); *pScan_line = m_pScan_line_0; @@ -2609,11 +2609,11 @@ void jpeg_decoder::decode_block_ac_refine(jpeg_decoder *pD, int component_id, in int p1 = 1 << pD->m_successive_low; int m1 = static_cast(-1) << pD->m_successive_low; jpgd_block_t *p = pD->coeff_buf_getp(pD->m_ac_coeffs[component_id], block_x, block_y); - + JPGD_ASSERT(pD->m_spectral_end <= 63); - + k = pD->m_spectral_start; - + if (pD->m_eob_run == 0) { for ( ; k <= pD->m_spectral_end; k++) { s = pD->huff_decode(pD->m_pHuff_tabs[pD->m_comp_ac_tab[component_id]]); diff --git a/src/loaders/png/tvgLodePng.cpp b/src/loaders/png/tvgLodePng.cpp index eaed025..509ccd1 100644 --- a/src/loaders/png/tvgLodePng.cpp +++ b/src/loaders/png/tvgLodePng.cpp @@ -1167,7 +1167,7 @@ static unsigned lodepng_crc32_table[256] = { }; -/* Calculate CRC32 of buffer +/* Calculate CRC32 of buffer Return the CRC of the bytes buf[0..len-1]. */ static unsigned lodepng_crc32(const unsigned char* data, size_t length) { @@ -1571,7 +1571,7 @@ static unsigned color_tree_add(ColorTree* tree, unsigned char r, unsigned char g /* put a pixel, given its RGBA color, into image of any color type */ static unsigned rgba8ToPixel(unsigned char* out, size_t i, const LodePNGColorMode* mode, ColorTree* tree /*for palette*/, unsigned char r, unsigned char g, unsigned char b, unsigned char a) -{ +{ if (mode->colortype == LCT_GREY) { unsigned char gray = r; /*((unsigned short)r + g + b) / 3u;*/ if (mode->bitdepth == 8) out[i] = gray; diff --git a/test/capi/capiFill.cpp b/test/capi/capiFill.cpp index a023c96..2439857 100644 --- a/test/capi/capiFill.cpp +++ b/test/capi/capiFill.cpp @@ -25,7 +25,7 @@ TEST_CASE("Set/Get fill color", "[capiShapeFill]") -{ +{ Tvg_Paint *paint = tvg_shape_new(); REQUIRE(paint); @@ -43,7 +43,7 @@ TEST_CASE("Set/Get fill color", "[capiShapeFill]") } TEST_CASE("Set/Get fill color on invalid shape", "[capiShapeFill]") -{ +{ REQUIRE(tvg_shape_set_fill_color(NULL, 120, 154, 180, 100) == TVG_RESULT_INVALID_ARGUMENT); uint8_t r, g, b, a; @@ -51,7 +51,7 @@ TEST_CASE("Set/Get fill color on invalid shape", "[capiShapeFill]") } TEST_CASE("Set/Get shape fill rule", "[capiShapeFill]") -{ +{ Tvg_Paint *paint = tvg_shape_new(); REQUIRE(paint); @@ -65,7 +65,7 @@ TEST_CASE("Set/Get shape fill rule", "[capiShapeFill]") } TEST_CASE("Set/Get shape fill rule on invalid object", "[capiShapeFill]") -{ +{ REQUIRE(tvg_shape_set_fill_rule(NULL, TVG_FILL_RULE_EVEN_ODD) == TVG_RESULT_INVALID_ARGUMENT); Tvg_Fill_Rule rule; diff --git a/test/testAccessor.cpp b/test/testAccessor.cpp new file mode 100644 index 0000000..f5bf052 --- /dev/null +++ b/test/testAccessor.cpp @@ -0,0 +1,77 @@ +/* + * Copyright (c) 2022 ThorVG Project. All rights reserved. + + * Permission is hereby granted, free of charge, to any person obtaining a copy + * of this software and associated documentation files (the "Software"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + + * The above copyright notice and this permission notice shall be included in all + * copies or substantial portions of the Software. + + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE + * SOFTWARE. + */ + +#include +#include "catch.hpp" + +using namespace tvg; +#include + +TEST_CASE("Accessor Creation", "[tvgAccessor]") +{ + auto accessor = tvg::Accessor::gen(); + REQUIRE(accessor); + + auto accessor2 = tvg::Accessor::gen(); + REQUIRE(accessor2); +} + + +TEST_CASE("Set", "[tvgAccessor]") +{ + REQUIRE(Initializer::init(CanvasEngine::Sw, 0) == Result::Success); + + auto canvas = SwCanvas::gen(); + REQUIRE(canvas); + + uint32_t buffer[100*100]; + REQUIRE(canvas->target(buffer, 100, 100, 100, SwCanvas::Colorspace::ABGR8888) == Result::Success); + + auto picture = Picture::gen(); + REQUIRE(picture); + REQUIRE(picture->load(TEST_DIR"/logo.svg") == Result::Success); + + auto accessor = tvg::Accessor::gen(); + REQUIRE(accessor); + + //Case 1 + picture = accessor->set(move(picture), nullptr); + REQUIRE(picture); + + //Case 2 + auto f = [](const tvg::Paint* paint) -> bool + { + if (paint->identifier() == tvg::Shape::identifier()) { + auto shape = (tvg::Shape*) paint; + uint8_t r, g, b, a; + shape->fillColor(&r, &g, &b, &a); + if (r == 37 && g == 47 && b == 53) + shape->fill(0, 0, 255, a); + } + return true; + }; + + picture = accessor->set(move(picture), f); + REQUIRE(picture); + + REQUIRE(Initializer::term(CanvasEngine::Sw) == Result::Success); +} -- 2.7.4 From af5e394cdda8ba4f6ec3f7b1c93c3ebe13d235e1 Mon Sep 17 00:00:00 2001 From: Mira Grudzinska Date: Sat, 7 Jan 2023 00:04:31 +0100 Subject: [PATCH 04/16] svg_loader: fixing crash for to big buffer Crash observed on macOS for the image-embeded-*.svg files. Since the alloca function was used the stack allocation failure could not be handled. Change-Id: Ibc38ef8f8f407145e7490c221a24786b99ed2d04 --- src/loaders/svg/tvgXmlParser.cpp | 21 ++++++++++++++------- 1 file changed, 14 insertions(+), 7 deletions(-) diff --git a/src/loaders/svg/tvgXmlParser.cpp b/src/loaders/svg/tvgXmlParser.cpp index 231badd..0e2c3fa 100644 --- a/src/loaders/svg/tvgXmlParser.cpp +++ b/src/loaders/svg/tvgXmlParser.cpp @@ -304,38 +304,38 @@ bool isIgnoreUnsupportedLogElements(TVG_UNUSED const char* tagName) bool simpleXmlParseAttributes(const char* buf, unsigned bufLength, simpleXMLAttributeCb func, const void* data) { const char *itr = buf, *itrEnd = buf + bufLength; - char* tmpBuf = (char*)alloca(bufLength + 1); + char* tmpBuf = (char*)malloc(bufLength + 1); - if (!buf || !func) return false; + if (!buf || !func || !tmpBuf) goto error; while (itr < itrEnd) { const char* p = _skipWhiteSpacesAndXmlEntities(itr, itrEnd); const char *key, *keyEnd, *value, *valueEnd; char* tval; - if (p == itrEnd) return true; + if (p == itrEnd) goto success; key = p; for (keyEnd = key; keyEnd < itrEnd; keyEnd++) { if ((*keyEnd == '=') || (isspace((unsigned char)*keyEnd))) break; } - if (keyEnd == itrEnd) return false; + if (keyEnd == itrEnd) goto error; if (keyEnd == key) continue; if (*keyEnd == '=') value = keyEnd + 1; else { value = (const char*)memchr(keyEnd, '=', itrEnd - keyEnd); - if (!value) return false; + if (!value) goto error; value++; } keyEnd = _simpleXmlUnskipXmlEntities(keyEnd, key); value = _skipWhiteSpacesAndXmlEntities(value, itrEnd); - if (value == itrEnd) return false; + if (value == itrEnd) goto error; if ((*value == '"') || (*value == '\'')) { valueEnd = (const char*)memchr(value + 1, *value, itrEnd - value); - if (!valueEnd) return false; + if (!valueEnd) goto error; value++; } else { valueEnd = _simpleXmlFindWhiteSpace(value, itrEnd); @@ -364,7 +364,14 @@ bool simpleXmlParseAttributes(const char* buf, unsigned bufLength, simpleXMLAttr } } } + +success: + free(tmpBuf); return true; + +error: + free(tmpBuf); + return false; } -- 2.7.4 From 39e43bc49699e4be1a41f38baf99f7c7b1523f4c Mon Sep 17 00:00:00 2001 From: Hermet Park Date: Sat, 14 Jan 2023 13:27:22 +0900 Subject: [PATCH 05/16] updated copyright. Change-Id: I3072e2bc6c6be08d97a94492e29929c60e667086 --- AUTHORS | 3 +++ LICENSE | 2 +- src/bin/svg2png/svg2png.cpp | 2 +- src/bin/svg2tvg/svg2tvg.cpp | 2 +- src/bindings/capi/tvgCapi.cpp | 2 +- src/examples/Accessor.cpp | 2 +- src/examples/AnimateMasking.cpp | 2 +- src/examples/Arc.cpp | 2 +- src/examples/Async.cpp | 2 +- src/examples/Blending.cpp | 2 +- src/examples/Capi.cpp | 2 +- src/examples/ClipPath.cpp | 2 +- src/examples/Common.h | 2 +- src/examples/CustomTransform.cpp | 2 +- src/examples/DirectUpdate.cpp | 2 +- src/examples/Duplicate.cpp | 2 +- src/examples/FillRule.cpp | 2 +- src/examples/GradientMasking.cpp | 2 +- src/examples/GradientStroke.cpp | 2 +- src/examples/GradientTransform.cpp | 2 +- src/examples/ImageScaleDown.cpp | 2 +- src/examples/ImageScaleUp.cpp | 2 +- src/examples/InvMasking.cpp | 2 +- src/examples/LinearGradient.cpp | 2 +- src/examples/LumaMasking.cpp | 2 +- src/examples/Masking.cpp | 2 +- src/examples/MultiCanvas.cpp | 2 +- src/examples/MultiShapes.cpp | 2 +- src/examples/Opacity.cpp | 2 +- src/examples/Path.cpp | 2 +- src/examples/PathCopy.cpp | 2 +- src/examples/Performance.cpp | 2 +- src/examples/PictureJpg.cpp | 2 +- src/examples/PicturePng.cpp | 2 +- src/examples/PictureRaw.cpp | 2 +- src/examples/PictureTvg.cpp | 2 +- src/examples/RadialGradient.cpp | 2 +- src/examples/Scene.cpp | 2 +- src/examples/SceneTransform.cpp | 2 +- src/examples/Shape.cpp | 2 +- src/examples/Stacking.cpp | 2 +- src/examples/Stress.cpp | 2 +- src/examples/Stroke.cpp | 2 +- src/examples/StrokeLine.cpp | 2 +- src/examples/Svg.cpp | 2 +- src/examples/Svg2.cpp | 2 +- src/examples/Transform.cpp | 2 +- src/examples/Tvg.cpp | 2 +- src/examples/TvgSaver.cpp | 2 +- src/examples/Update.cpp | 2 +- src/lib/gl_engine/tvgGlCommon.h | 2 +- src/lib/gl_engine/tvgGlGeometry.cpp | 2 +- src/lib/gl_engine/tvgGlGeometry.h | 2 +- src/lib/gl_engine/tvgGlGpuBuffer.cpp | 2 +- src/lib/gl_engine/tvgGlGpuBuffer.h | 2 +- src/lib/gl_engine/tvgGlProgram.cpp | 2 +- src/lib/gl_engine/tvgGlProgram.h | 2 +- src/lib/gl_engine/tvgGlPropertyInterface.cpp | 2 +- src/lib/gl_engine/tvgGlPropertyInterface.h | 2 +- src/lib/gl_engine/tvgGlRenderTask.cpp | 2 +- src/lib/gl_engine/tvgGlRenderTask.h | 2 +- src/lib/gl_engine/tvgGlRenderer.cpp | 2 +- src/lib/gl_engine/tvgGlRenderer.h | 2 +- src/lib/gl_engine/tvgGlRendererProperties.h | 2 +- src/lib/gl_engine/tvgGlShader.cpp | 2 +- src/lib/gl_engine/tvgGlShader.h | 2 +- src/lib/gl_engine/tvgGlShaderSrc.cpp | 2 +- src/lib/gl_engine/tvgGlShaderSrc.h | 2 +- src/lib/sw_engine/tvgSwCommon.h | 3 ++- src/lib/sw_engine/tvgSwFill.cpp | 3 ++- src/lib/sw_engine/tvgSwImage.cpp | 3 ++- src/lib/sw_engine/tvgSwMath.cpp | 3 ++- src/lib/sw_engine/tvgSwMemPool.cpp | 3 ++- src/lib/sw_engine/tvgSwRaster.cpp | 2 +- src/lib/sw_engine/tvgSwRasterAvx.h | 2 +- src/lib/sw_engine/tvgSwRasterC.h | 3 +-- src/lib/sw_engine/tvgSwRasterNeon.h | 2 +- src/lib/sw_engine/tvgSwRasterTexmap.h | 2 +- src/lib/sw_engine/tvgSwRasterTexmapInternal.h | 3 ++- src/lib/sw_engine/tvgSwRenderer.cpp | 3 ++- src/lib/sw_engine/tvgSwRenderer.h | 3 ++- src/lib/sw_engine/tvgSwRle.cpp | 2 +- src/lib/sw_engine/tvgSwShape.cpp | 3 ++- src/lib/sw_engine/tvgSwStroke.cpp | 3 ++- src/lib/tvgAccessor.cpp | 5 ++++- src/lib/tvgArray.h | 3 ++- src/lib/tvgBezier.cpp | 3 ++- src/lib/tvgBezier.h | 3 ++- src/lib/tvgBinaryDesc.h | 3 ++- src/lib/tvgCanvas.cpp | 3 ++- src/lib/tvgCanvasImpl.h | 3 ++- src/lib/tvgCommon.h | 3 ++- src/lib/tvgFill.cpp | 3 ++- src/lib/tvgFill.h | 3 ++- src/lib/tvgGlCanvas.cpp | 3 ++- src/lib/tvgInitializer.cpp | 3 ++- src/lib/tvgIteratorAccessor.h | 3 ++- src/lib/tvgLinearGradient.cpp | 3 ++- src/lib/tvgLoadModule.h | 3 ++- src/lib/tvgLoader.cpp | 3 ++- src/lib/tvgLoader.h | 3 ++- src/lib/tvgLzw.cpp | 2 +- src/lib/tvgLzw.h | 3 ++- src/lib/tvgMath.h | 3 ++- src/lib/tvgPaint.cpp | 3 ++- src/lib/tvgPaint.h | 3 ++- src/lib/tvgPicture.cpp | 2 +- src/lib/tvgPictureImpl.h | 3 ++- src/lib/tvgRadialGradient.cpp | 3 ++- src/lib/tvgRender.cpp | 3 ++- src/lib/tvgRender.h | 3 ++- src/lib/tvgSaveModule.h | 3 ++- src/lib/tvgSaver.cpp | 3 ++- src/lib/tvgScene.cpp | 3 ++- src/lib/tvgSceneImpl.h | 3 ++- src/lib/tvgShape.cpp | 2 +- src/lib/tvgShapeImpl.h | 3 ++- src/lib/tvgSwCanvas.cpp | 3 ++- src/lib/tvgTaskScheduler.cpp | 3 ++- src/lib/tvgTaskScheduler.h | 3 ++- src/loaders/external_jpg/tvgJpgLoader.cpp | 2 +- src/loaders/external_jpg/tvgJpgLoader.h | 3 ++- src/loaders/external_png/tvgPngLoader.cpp | 2 +- src/loaders/external_png/tvgPngLoader.h | 3 ++- src/loaders/jpg/tvgJpgLoader.cpp | 2 +- src/loaders/jpg/tvgJpgLoader.h | 3 ++- src/loaders/jpg/tvgJpgd.cpp | 2 +- src/loaders/jpg/tvgJpgd.h | 2 +- src/loaders/png/tvgLodePng.cpp | 2 +- src/loaders/png/tvgLodePng.h | 2 +- src/loaders/png/tvgPngLoader.cpp | 3 ++- src/loaders/png/tvgPngLoader.h | 3 ++- src/loaders/raw/tvgRawLoader.cpp | 3 ++- src/loaders/raw/tvgRawLoader.h | 3 ++- src/loaders/svg/tvgSvgCssStyle.cpp | 2 +- src/loaders/svg/tvgSvgCssStyle.h | 2 +- src/loaders/svg/tvgSvgLoader.cpp | 2 +- src/loaders/svg/tvgSvgLoader.h | 3 ++- src/loaders/svg/tvgSvgLoaderCommon.h | 3 ++- src/loaders/svg/tvgSvgPath.cpp | 2 +- src/loaders/svg/tvgSvgPath.h | 2 +- src/loaders/svg/tvgSvgSceneBuilder.cpp | 2 +- src/loaders/svg/tvgSvgSceneBuilder.h | 2 +- src/loaders/svg/tvgSvgUtil.cpp | 2 +- src/loaders/svg/tvgSvgUtil.h | 2 +- src/loaders/svg/tvgXmlParser.cpp | 2 +- src/loaders/svg/tvgXmlParser.h | 2 +- src/loaders/tvg/tvgTvgBinInterpreter.cpp | 3 ++- src/loaders/tvg/tvgTvgCommon.h | 2 +- src/loaders/tvg/tvgTvgLoader.cpp | 3 ++- src/loaders/tvg/tvgTvgLoader.h | 2 +- src/savers/tvg/tvgTvgSaver.cpp | 3 ++- src/savers/tvg/tvgTvgSaver.h | 3 ++- src/wasm/thorvgwasm.cpp | 2 +- test/capi/capiFill.cpp | 2 +- test/capi/capiInitializer.cpp | 2 +- test/capi/capiLinearGradient.cpp | 2 +- test/capi/capiPaint.cpp | 2 +- test/capi/capiPicture.cpp | 2 +- test/capi/capiRadialGradient.cpp | 2 +- test/capi/capiSavers.cpp | 2 +- test/capi/capiScene.cpp | 2 +- test/capi/capiShape.cpp | 2 +- test/capi/capiSwCanvas.cpp | 2 +- test/testAccessor.cpp | 2 +- test/testFill.cpp | 2 +- test/testInitializer.cpp | 2 +- test/testPaint.cpp | 2 +- test/testPicture.cpp | 2 +- test/testSavers.cpp | 2 +- test/testScene.cpp | 2 +- test/testShape.cpp | 2 +- test/testSwCanvas.cpp | 2 +- test/testSwCanvasBase.cpp | 2 +- test/testSwEngine.cpp | 2 +- 175 files changed, 235 insertions(+), 175 deletions(-) diff --git a/AUTHORS b/AUTHORS index 5258dfd..21b7064 100644 --- a/AUTHORS +++ b/AUTHORS @@ -16,3 +16,6 @@ Peter Vullings K. S. Ernest (iFire) Lee Rémi Verschelde Martin Liska +Vincenzo Pupillo +EunSik Jeong +Samsung Electronics Co., Ltd diff --git a/LICENSE b/LICENSE index 2f0361a..d056ff6 100644 --- a/LICENSE +++ b/LICENSE @@ -1,4 +1,4 @@ -Copyright (c) 2020 - 2022 notice for the ThorVG Project (see AUTHORS) +Copyright (c) 2020 - 2023 notice for the ThorVG Project (see AUTHORS) Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: diff --git a/src/bin/svg2png/svg2png.cpp b/src/bin/svg2png/svg2png.cpp index 89b3583..c399c28 100644 --- a/src/bin/svg2png/svg2png.cpp +++ b/src/bin/svg2png/svg2png.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/bin/svg2tvg/svg2tvg.cpp b/src/bin/svg2tvg/svg2tvg.cpp index fad70a4..1c00561 100644 --- a/src/bin/svg2tvg/svg2tvg.cpp +++ b/src/bin/svg2tvg/svg2tvg.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2021 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/bindings/capi/tvgCapi.cpp b/src/bindings/capi/tvgCapi.cpp index 14475c7..9ba0348 100644 --- a/src/bindings/capi/tvgCapi.cpp +++ b/src/bindings/capi/tvgCapi.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/examples/Accessor.cpp b/src/examples/Accessor.cpp index 433b3f9..2eabe80 100644 --- a/src/examples/Accessor.cpp +++ b/src/examples/Accessor.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2021 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/examples/AnimateMasking.cpp b/src/examples/AnimateMasking.cpp index bada7eb..19bee67 100644 --- a/src/examples/AnimateMasking.cpp +++ b/src/examples/AnimateMasking.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020-2021 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/examples/Arc.cpp b/src/examples/Arc.cpp index 2033dfa..63adc2d 100644 --- a/src/examples/Arc.cpp +++ b/src/examples/Arc.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/examples/Async.cpp b/src/examples/Async.cpp index 1ecdde4..a06e0e3 100644 --- a/src/examples/Async.cpp +++ b/src/examples/Async.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/examples/Blending.cpp b/src/examples/Blending.cpp index b8c2ce2..041f325 100644 --- a/src/examples/Blending.cpp +++ b/src/examples/Blending.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/examples/Capi.cpp b/src/examples/Capi.cpp index db77095..7dc8f31 100644 --- a/src/examples/Capi.cpp +++ b/src/examples/Capi.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/examples/ClipPath.cpp b/src/examples/ClipPath.cpp index c748a6c..067e713 100644 --- a/src/examples/ClipPath.cpp +++ b/src/examples/ClipPath.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/examples/Common.h b/src/examples/Common.h index c7e0200..6ce91fe 100644 --- a/src/examples/Common.h +++ b/src/examples/Common.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/examples/CustomTransform.cpp b/src/examples/CustomTransform.cpp index 678816a..bb3135e 100644 --- a/src/examples/CustomTransform.cpp +++ b/src/examples/CustomTransform.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/examples/DirectUpdate.cpp b/src/examples/DirectUpdate.cpp index 5be660c..b3189d9 100644 --- a/src/examples/DirectUpdate.cpp +++ b/src/examples/DirectUpdate.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/examples/Duplicate.cpp b/src/examples/Duplicate.cpp index 080e74b..8da1885 100644 --- a/src/examples/Duplicate.cpp +++ b/src/examples/Duplicate.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/examples/FillRule.cpp b/src/examples/FillRule.cpp index b2e0730..2d31627 100644 --- a/src/examples/FillRule.cpp +++ b/src/examples/FillRule.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/examples/GradientMasking.cpp b/src/examples/GradientMasking.cpp index b8b88ea..7254ee2 100644 --- a/src/examples/GradientMasking.cpp +++ b/src/examples/GradientMasking.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/examples/GradientStroke.cpp b/src/examples/GradientStroke.cpp index 6e2b97e..a0f516e 100644 --- a/src/examples/GradientStroke.cpp +++ b/src/examples/GradientStroke.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/examples/GradientTransform.cpp b/src/examples/GradientTransform.cpp index e908a4c..9d55aa1 100644 --- a/src/examples/GradientTransform.cpp +++ b/src/examples/GradientTransform.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/examples/ImageScaleDown.cpp b/src/examples/ImageScaleDown.cpp index 5589ea8..81928d0 100644 --- a/src/examples/ImageScaleDown.cpp +++ b/src/examples/ImageScaleDown.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2021 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/examples/ImageScaleUp.cpp b/src/examples/ImageScaleUp.cpp index 675d2ed..f45b96c 100644 --- a/src/examples/ImageScaleUp.cpp +++ b/src/examples/ImageScaleUp.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2021 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/examples/InvMasking.cpp b/src/examples/InvMasking.cpp index 4b6eb31..87e81fd 100644 --- a/src/examples/InvMasking.cpp +++ b/src/examples/InvMasking.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/examples/LinearGradient.cpp b/src/examples/LinearGradient.cpp index 4fd40f5..1984186 100644 --- a/src/examples/LinearGradient.cpp +++ b/src/examples/LinearGradient.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/examples/LumaMasking.cpp b/src/examples/LumaMasking.cpp index cb32d1b..13c4627 100644 --- a/src/examples/LumaMasking.cpp +++ b/src/examples/LumaMasking.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/examples/Masking.cpp b/src/examples/Masking.cpp index 88be49a..bce6270 100644 --- a/src/examples/Masking.cpp +++ b/src/examples/Masking.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/examples/MultiCanvas.cpp b/src/examples/MultiCanvas.cpp index 14a3d67..99cdd13 100644 --- a/src/examples/MultiCanvas.cpp +++ b/src/examples/MultiCanvas.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/examples/MultiShapes.cpp b/src/examples/MultiShapes.cpp index ebe3381..47db09c 100644 --- a/src/examples/MultiShapes.cpp +++ b/src/examples/MultiShapes.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/examples/Opacity.cpp b/src/examples/Opacity.cpp index 3a19784..158b910 100644 --- a/src/examples/Opacity.cpp +++ b/src/examples/Opacity.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/examples/Path.cpp b/src/examples/Path.cpp index 622c889..27477a8 100644 --- a/src/examples/Path.cpp +++ b/src/examples/Path.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/examples/PathCopy.cpp b/src/examples/PathCopy.cpp index a86e9b6..3f68c96 100644 --- a/src/examples/PathCopy.cpp +++ b/src/examples/PathCopy.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/examples/Performance.cpp b/src/examples/Performance.cpp index ddc5d78..48cb67b 100644 --- a/src/examples/Performance.cpp +++ b/src/examples/Performance.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2021 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/examples/PictureJpg.cpp b/src/examples/PictureJpg.cpp index c04b34b..52f43b8 100644 --- a/src/examples/PictureJpg.cpp +++ b/src/examples/PictureJpg.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/examples/PicturePng.cpp b/src/examples/PicturePng.cpp index b43926a..c5e7119 100644 --- a/src/examples/PicturePng.cpp +++ b/src/examples/PicturePng.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/examples/PictureRaw.cpp b/src/examples/PictureRaw.cpp index ea6de16..94261c4 100644 --- a/src/examples/PictureRaw.cpp +++ b/src/examples/PictureRaw.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/examples/PictureTvg.cpp b/src/examples/PictureTvg.cpp index 8144e6a..7bfd05e 100644 --- a/src/examples/PictureTvg.cpp +++ b/src/examples/PictureTvg.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2021 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/examples/RadialGradient.cpp b/src/examples/RadialGradient.cpp index f15889d..ba38810 100644 --- a/src/examples/RadialGradient.cpp +++ b/src/examples/RadialGradient.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/examples/Scene.cpp b/src/examples/Scene.cpp index 924aeba..218b641 100644 --- a/src/examples/Scene.cpp +++ b/src/examples/Scene.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/examples/SceneTransform.cpp b/src/examples/SceneTransform.cpp index d320a9b..2e694f9 100644 --- a/src/examples/SceneTransform.cpp +++ b/src/examples/SceneTransform.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/examples/Shape.cpp b/src/examples/Shape.cpp index 57b69d4..4c33022 100644 --- a/src/examples/Shape.cpp +++ b/src/examples/Shape.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/examples/Stacking.cpp b/src/examples/Stacking.cpp index 5afc0ec..bbf1129 100644 --- a/src/examples/Stacking.cpp +++ b/src/examples/Stacking.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/examples/Stress.cpp b/src/examples/Stress.cpp index 58294bf..447bfb3 100644 --- a/src/examples/Stress.cpp +++ b/src/examples/Stress.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/examples/Stroke.cpp b/src/examples/Stroke.cpp index ea903b3..54c37b2 100644 --- a/src/examples/Stroke.cpp +++ b/src/examples/Stroke.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/examples/StrokeLine.cpp b/src/examples/StrokeLine.cpp index 7e73c4a..00a83f2 100644 --- a/src/examples/StrokeLine.cpp +++ b/src/examples/StrokeLine.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/examples/Svg.cpp b/src/examples/Svg.cpp index 53e9502..d8472e6 100644 --- a/src/examples/Svg.cpp +++ b/src/examples/Svg.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/examples/Svg2.cpp b/src/examples/Svg2.cpp index 011816e..b0a0a68 100644 --- a/src/examples/Svg2.cpp +++ b/src/examples/Svg2.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/examples/Transform.cpp b/src/examples/Transform.cpp index b6b6ddd..3c89ba6 100644 --- a/src/examples/Transform.cpp +++ b/src/examples/Transform.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/examples/Tvg.cpp b/src/examples/Tvg.cpp index 5512f43..7eef4eb 100644 --- a/src/examples/Tvg.cpp +++ b/src/examples/Tvg.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2021 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/examples/TvgSaver.cpp b/src/examples/TvgSaver.cpp index 3b22e48..8c8be46 100644 --- a/src/examples/TvgSaver.cpp +++ b/src/examples/TvgSaver.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2021 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/examples/Update.cpp b/src/examples/Update.cpp index 70d5d72..f3940a9 100644 --- a/src/examples/Update.cpp +++ b/src/examples/Update.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/lib/gl_engine/tvgGlCommon.h b/src/lib/gl_engine/tvgGlCommon.h index 165103d..90d6b14 100644 --- a/src/lib/gl_engine/tvgGlCommon.h +++ b/src/lib/gl_engine/tvgGlCommon.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/lib/gl_engine/tvgGlGeometry.cpp b/src/lib/gl_engine/tvgGlGeometry.cpp index 56613c1..c3d3297 100644 --- a/src/lib/gl_engine/tvgGlGeometry.cpp +++ b/src/lib/gl_engine/tvgGlGeometry.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/lib/gl_engine/tvgGlGeometry.h b/src/lib/gl_engine/tvgGlGeometry.h index 79ffeb9..ec1b7e8 100644 --- a/src/lib/gl_engine/tvgGlGeometry.h +++ b/src/lib/gl_engine/tvgGlGeometry.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/lib/gl_engine/tvgGlGpuBuffer.cpp b/src/lib/gl_engine/tvgGlGpuBuffer.cpp index 6f5b2e8..a151d2b 100644 --- a/src/lib/gl_engine/tvgGlGpuBuffer.cpp +++ b/src/lib/gl_engine/tvgGlGpuBuffer.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/lib/gl_engine/tvgGlGpuBuffer.h b/src/lib/gl_engine/tvgGlGpuBuffer.h index 15b0fe2..3e9f10f 100644 --- a/src/lib/gl_engine/tvgGlGpuBuffer.h +++ b/src/lib/gl_engine/tvgGlGpuBuffer.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/lib/gl_engine/tvgGlProgram.cpp b/src/lib/gl_engine/tvgGlProgram.cpp index eda041b..6a48b60 100644 --- a/src/lib/gl_engine/tvgGlProgram.cpp +++ b/src/lib/gl_engine/tvgGlProgram.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/lib/gl_engine/tvgGlProgram.h b/src/lib/gl_engine/tvgGlProgram.h index 024cad3..807b985 100644 --- a/src/lib/gl_engine/tvgGlProgram.h +++ b/src/lib/gl_engine/tvgGlProgram.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/lib/gl_engine/tvgGlPropertyInterface.cpp b/src/lib/gl_engine/tvgGlPropertyInterface.cpp index 2d5d7a6..ef0f9c5 100644 --- a/src/lib/gl_engine/tvgGlPropertyInterface.cpp +++ b/src/lib/gl_engine/tvgGlPropertyInterface.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/lib/gl_engine/tvgGlPropertyInterface.h b/src/lib/gl_engine/tvgGlPropertyInterface.h index 2f9cde2..823571a 100644 --- a/src/lib/gl_engine/tvgGlPropertyInterface.h +++ b/src/lib/gl_engine/tvgGlPropertyInterface.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/lib/gl_engine/tvgGlRenderTask.cpp b/src/lib/gl_engine/tvgGlRenderTask.cpp index 3e86c5b..b7367f7 100644 --- a/src/lib/gl_engine/tvgGlRenderTask.cpp +++ b/src/lib/gl_engine/tvgGlRenderTask.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/lib/gl_engine/tvgGlRenderTask.h b/src/lib/gl_engine/tvgGlRenderTask.h index 1a72d8c..74277b3 100644 --- a/src/lib/gl_engine/tvgGlRenderTask.h +++ b/src/lib/gl_engine/tvgGlRenderTask.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/lib/gl_engine/tvgGlRenderer.cpp b/src/lib/gl_engine/tvgGlRenderer.cpp index 8fbcd39..ce82368 100644 --- a/src/lib/gl_engine/tvgGlRenderer.cpp +++ b/src/lib/gl_engine/tvgGlRenderer.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/lib/gl_engine/tvgGlRenderer.h b/src/lib/gl_engine/tvgGlRenderer.h index 7767a62..790ea31 100644 --- a/src/lib/gl_engine/tvgGlRenderer.h +++ b/src/lib/gl_engine/tvgGlRenderer.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/lib/gl_engine/tvgGlRendererProperties.h b/src/lib/gl_engine/tvgGlRendererProperties.h index 53416b6..3bd97e3 100644 --- a/src/lib/gl_engine/tvgGlRendererProperties.h +++ b/src/lib/gl_engine/tvgGlRendererProperties.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/lib/gl_engine/tvgGlShader.cpp b/src/lib/gl_engine/tvgGlShader.cpp index 57f574e..5d2b1d5 100644 --- a/src/lib/gl_engine/tvgGlShader.cpp +++ b/src/lib/gl_engine/tvgGlShader.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/lib/gl_engine/tvgGlShader.h b/src/lib/gl_engine/tvgGlShader.h index f566fef..85db829 100644 --- a/src/lib/gl_engine/tvgGlShader.h +++ b/src/lib/gl_engine/tvgGlShader.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/lib/gl_engine/tvgGlShaderSrc.cpp b/src/lib/gl_engine/tvgGlShaderSrc.cpp index bba73dc..330eaa3 100644 --- a/src/lib/gl_engine/tvgGlShaderSrc.cpp +++ b/src/lib/gl_engine/tvgGlShaderSrc.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/lib/gl_engine/tvgGlShaderSrc.h b/src/lib/gl_engine/tvgGlShaderSrc.h index c8afab1..053f1c9 100644 --- a/src/lib/gl_engine/tvgGlShaderSrc.h +++ b/src/lib/gl_engine/tvgGlShaderSrc.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/lib/sw_engine/tvgSwCommon.h b/src/lib/sw_engine/tvgSwCommon.h index 888f4fd..1f920eb 100644 --- a/src/lib/sw_engine/tvgSwCommon.h +++ b/src/lib/sw_engine/tvgSwCommon.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #ifndef _TVG_SW_COMMON_H_ #define _TVG_SW_COMMON_H_ diff --git a/src/lib/sw_engine/tvgSwFill.cpp b/src/lib/sw_engine/tvgSwFill.cpp index bba6f26..694bc35 100644 --- a/src/lib/sw_engine/tvgSwFill.cpp +++ b/src/lib/sw_engine/tvgSwFill.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #include "tvgMath.h" #include "tvgSwCommon.h" diff --git a/src/lib/sw_engine/tvgSwImage.cpp b/src/lib/sw_engine/tvgSwImage.cpp index 2b139a7..fdb78f0 100644 --- a/src/lib/sw_engine/tvgSwImage.cpp +++ b/src/lib/sw_engine/tvgSwImage.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #include "tvgMath.h" #include "tvgSwCommon.h" diff --git a/src/lib/sw_engine/tvgSwMath.cpp b/src/lib/sw_engine/tvgSwMath.cpp index ced66ae..5a4f58d 100644 --- a/src/lib/sw_engine/tvgSwMath.cpp +++ b/src/lib/sw_engine/tvgSwMath.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #include #include "tvgSwCommon.h" diff --git a/src/lib/sw_engine/tvgSwMemPool.cpp b/src/lib/sw_engine/tvgSwMemPool.cpp index d2962e6..a87b3fd 100644 --- a/src/lib/sw_engine/tvgSwMemPool.cpp +++ b/src/lib/sw_engine/tvgSwMemPool.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #include "tvgSwCommon.h" diff --git a/src/lib/sw_engine/tvgSwRaster.cpp b/src/lib/sw_engine/tvgSwRaster.cpp index 7512efc..68f20d1 100644 --- a/src/lib/sw_engine/tvgSwRaster.cpp +++ b/src/lib/sw_engine/tvgSwRaster.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/lib/sw_engine/tvgSwRasterAvx.h b/src/lib/sw_engine/tvgSwRasterAvx.h index 7a129a3..b5a2a3c 100644 --- a/src/lib/sw_engine/tvgSwRasterAvx.h +++ b/src/lib/sw_engine/tvgSwRasterAvx.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2021 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/lib/sw_engine/tvgSwRasterC.h b/src/lib/sw_engine/tvgSwRasterC.h index de6b35f..18118aa 100644 --- a/src/lib/sw_engine/tvgSwRasterC.h +++ b/src/lib/sw_engine/tvgSwRasterC.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2021 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -20,7 +20,6 @@ * SOFTWARE. */ - static void inline cRasterRGBA32(uint32_t *dst, uint32_t val, uint32_t offset, int32_t len) { dst += offset; diff --git a/src/lib/sw_engine/tvgSwRasterNeon.h b/src/lib/sw_engine/tvgSwRasterNeon.h index 4ce60c5..d7c71fb 100644 --- a/src/lib/sw_engine/tvgSwRasterNeon.h +++ b/src/lib/sw_engine/tvgSwRasterNeon.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2021 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/lib/sw_engine/tvgSwRasterTexmap.h b/src/lib/sw_engine/tvgSwRasterTexmap.h index 9aebaaf..58906b6 100644 --- a/src/lib/sw_engine/tvgSwRasterTexmap.h +++ b/src/lib/sw_engine/tvgSwRasterTexmap.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2021 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/lib/sw_engine/tvgSwRasterTexmapInternal.h b/src/lib/sw_engine/tvgSwRasterTexmapInternal.h index b578f87..8fc0f5b 100644 --- a/src/lib/sw_engine/tvgSwRasterTexmapInternal.h +++ b/src/lib/sw_engine/tvgSwRasterTexmapInternal.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2021 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + { float _dudx = dudx, _dvdx = dvdx; float _dxdya = dxdya, _dxdyb = dxdyb, _dudya = dudya, _dvdya = dvdya; diff --git a/src/lib/sw_engine/tvgSwRenderer.cpp b/src/lib/sw_engine/tvgSwRenderer.cpp index 03bc695..6e7b738 100644 --- a/src/lib/sw_engine/tvgSwRenderer.cpp +++ b/src/lib/sw_engine/tvgSwRenderer.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #include "tvgMath.h" #include "tvgSwCommon.h" #include "tvgTaskScheduler.h" diff --git a/src/lib/sw_engine/tvgSwRenderer.h b/src/lib/sw_engine/tvgSwRenderer.h index 9bc1c83..460659c 100644 --- a/src/lib/sw_engine/tvgSwRenderer.h +++ b/src/lib/sw_engine/tvgSwRenderer.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #ifndef _TVG_SW_RENDERER_H_ #define _TVG_SW_RENDERER_H_ diff --git a/src/lib/sw_engine/tvgSwRle.cpp b/src/lib/sw_engine/tvgSwRle.cpp index 63e7fc9..6651e4e 100644 --- a/src/lib/sw_engine/tvgSwRle.cpp +++ b/src/lib/sw_engine/tvgSwRle.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/lib/sw_engine/tvgSwShape.cpp b/src/lib/sw_engine/tvgSwShape.cpp index e5b540b..82d812e 100644 --- a/src/lib/sw_engine/tvgSwShape.cpp +++ b/src/lib/sw_engine/tvgSwShape.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #include "tvgSwCommon.h" #include "tvgBezier.h" #include diff --git a/src/lib/sw_engine/tvgSwStroke.cpp b/src/lib/sw_engine/tvgSwStroke.cpp index be43927..d1803bd 100644 --- a/src/lib/sw_engine/tvgSwStroke.cpp +++ b/src/lib/sw_engine/tvgSwStroke.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #include #include #include "tvgSwCommon.h" diff --git a/src/lib/tvgAccessor.cpp b/src/lib/tvgAccessor.cpp index b69c766..0add721 100644 --- a/src/lib/tvgAccessor.cpp +++ b/src/lib/tvgAccessor.cpp @@ -1,13 +1,16 @@ /* - * Copyright (c) 2021 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2021 - 2023 the ThorVG project. All rights reserved. + * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal * in the Software without restriction, including without limitation the rights * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell * copies of the Software, and to permit persons to whom the Software is * furnished to do so, subject to the following conditions: + * The above copyright notice and this permission notice shall be included in all * copies or substantial portions of the Software. + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE diff --git a/src/lib/tvgArray.h b/src/lib/tvgArray.h index 04ddbae..8d67753 100644 --- a/src/lib/tvgArray.h +++ b/src/lib/tvgArray.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #ifndef _TVG_ARRAY_H_ #define _TVG_ARRAY_H_ diff --git a/src/lib/tvgBezier.cpp b/src/lib/tvgBezier.cpp index f26f74f..6162252 100644 --- a/src/lib/tvgBezier.cpp +++ b/src/lib/tvgBezier.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #include #include #include "tvgBezier.h" diff --git a/src/lib/tvgBezier.h b/src/lib/tvgBezier.h index 7d7c84e..aa309b0 100644 --- a/src/lib/tvgBezier.h +++ b/src/lib/tvgBezier.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #ifndef _TVG_BEZIER_H_ #define _TVG_BEZIER_H_ diff --git a/src/lib/tvgBinaryDesc.h b/src/lib/tvgBinaryDesc.h index a6a70a4..3b44db2 100644 --- a/src/lib/tvgBinaryDesc.h +++ b/src/lib/tvgBinaryDesc.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2021 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #ifndef _TVG_BINARY_DESC_H_ #define _TVG_BINARY_DESC_H_ diff --git a/src/lib/tvgCanvas.cpp b/src/lib/tvgCanvas.cpp index e8529e4..8430735 100644 --- a/src/lib/tvgCanvas.cpp +++ b/src/lib/tvgCanvas.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #include "tvgCanvasImpl.h" /************************************************************************/ diff --git a/src/lib/tvgCanvasImpl.h b/src/lib/tvgCanvasImpl.h index 0adec8f..6f5760f 100644 --- a/src/lib/tvgCanvasImpl.h +++ b/src/lib/tvgCanvasImpl.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #ifndef _TVG_CANVAS_IMPL_H_ #define _TVG_CANVAS_IMPL_H_ diff --git a/src/lib/tvgCommon.h b/src/lib/tvgCommon.h index b9919b0..9d36c67 100644 --- a/src/lib/tvgCommon.h +++ b/src/lib/tvgCommon.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #ifndef _TVG_COMMON_H_ #define _TVG_COMMON_H_ diff --git a/src/lib/tvgFill.cpp b/src/lib/tvgFill.cpp index eecf239..cc7e1cc 100644 --- a/src/lib/tvgFill.cpp +++ b/src/lib/tvgFill.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #include "tvgFill.h" /************************************************************************/ diff --git a/src/lib/tvgFill.h b/src/lib/tvgFill.h index fff2475..e90991c 100644 --- a/src/lib/tvgFill.h +++ b/src/lib/tvgFill.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #ifndef _TVG_FILL_H_ #define _TVG_FILL_H_ diff --git a/src/lib/tvgGlCanvas.cpp b/src/lib/tvgGlCanvas.cpp index 56feb69..dbbab51 100644 --- a/src/lib/tvgGlCanvas.cpp +++ b/src/lib/tvgGlCanvas.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #include "tvgCanvasImpl.h" #ifdef THORVG_GL_RASTER_SUPPORT diff --git a/src/lib/tvgInitializer.cpp b/src/lib/tvgInitializer.cpp index 42997c3..a1e9307 100644 --- a/src/lib/tvgInitializer.cpp +++ b/src/lib/tvgInitializer.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #include "tvgCommon.h" #include "tvgTaskScheduler.h" #include "tvgLoader.h" diff --git a/src/lib/tvgIteratorAccessor.h b/src/lib/tvgIteratorAccessor.h index 8e566ac..6674a7f 100644 --- a/src/lib/tvgIteratorAccessor.h +++ b/src/lib/tvgIteratorAccessor.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2021 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #ifndef _TVG_ITERATOR_ACCESSOR_H_ #define _TVG_ITERATOR_ACCESSOR_H_ diff --git a/src/lib/tvgLinearGradient.cpp b/src/lib/tvgLinearGradient.cpp index df34af3..3e040c0 100644 --- a/src/lib/tvgLinearGradient.cpp +++ b/src/lib/tvgLinearGradient.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #include #include #include "tvgFill.h" diff --git a/src/lib/tvgLoadModule.h b/src/lib/tvgLoadModule.h index 0049831..2c2ffda 100644 --- a/src/lib/tvgLoadModule.h +++ b/src/lib/tvgLoadModule.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #ifndef _TVG_LOAD_MODULE_H_ #define _TVG_LOAD_MODULE_H_ diff --git a/src/lib/tvgLoader.cpp b/src/lib/tvgLoader.cpp index 991c260..2bbe177 100644 --- a/src/lib/tvgLoader.cpp +++ b/src/lib/tvgLoader.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #include "tvgLoader.h" #ifdef THORVG_SVG_LOADER_SUPPORT diff --git a/src/lib/tvgLoader.h b/src/lib/tvgLoader.h index ab32f89..17ff9e2 100644 --- a/src/lib/tvgLoader.h +++ b/src/lib/tvgLoader.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #ifndef _TVG_LOADER_H_ #define _TVG_LOADER_H_ diff --git a/src/lib/tvgLzw.cpp b/src/lib/tvgLzw.cpp index 964af08..52f4ed6 100644 --- a/src/lib/tvgLzw.cpp +++ b/src/lib/tvgLzw.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/lib/tvgLzw.h b/src/lib/tvgLzw.h index 8e165bd..bd4e783 100644 --- a/src/lib/tvgLzw.h +++ b/src/lib/tvgLzw.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #ifndef _TVG_LZW_H_ #define _TVG_LZW_H_ diff --git a/src/lib/tvgMath.h b/src/lib/tvgMath.h index 2cce318..9ab8291 100644 --- a/src/lib/tvgMath.h +++ b/src/lib/tvgMath.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2021 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #ifndef _TVG_MATH_H_ #define _TVG_MATH_H_ diff --git a/src/lib/tvgPaint.cpp b/src/lib/tvgPaint.cpp index 984f24e..05b7078 100644 --- a/src/lib/tvgPaint.cpp +++ b/src/lib/tvgPaint.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #include "tvgMath.h" #include "tvgPaint.h" diff --git a/src/lib/tvgPaint.h b/src/lib/tvgPaint.h index c170559..c54b97a 100644 --- a/src/lib/tvgPaint.h +++ b/src/lib/tvgPaint.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #ifndef _TVG_PAINT_H_ #define _TVG_PAINT_H_ diff --git a/src/lib/tvgPicture.cpp b/src/lib/tvgPicture.cpp index b6f4787..2b1d0f5 100644 --- a/src/lib/tvgPicture.cpp +++ b/src/lib/tvgPicture.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/lib/tvgPictureImpl.h b/src/lib/tvgPictureImpl.h index 172c6f6..e039532 100644 --- a/src/lib/tvgPictureImpl.h +++ b/src/lib/tvgPictureImpl.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #ifndef _TVG_PICTURE_IMPL_H_ #define _TVG_PICTURE_IMPL_H_ diff --git a/src/lib/tvgRadialGradient.cpp b/src/lib/tvgRadialGradient.cpp index 7f4e1d7..a85f60e 100644 --- a/src/lib/tvgRadialGradient.cpp +++ b/src/lib/tvgRadialGradient.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #include #include "tvgFill.h" diff --git a/src/lib/tvgRender.cpp b/src/lib/tvgRender.cpp index 90f0917..fb9270a 100644 --- a/src/lib/tvgRender.cpp +++ b/src/lib/tvgRender.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #include "tvgMath.h" #include "tvgRender.h" diff --git a/src/lib/tvgRender.h b/src/lib/tvgRender.h index 54ca524..34e3101 100644 --- a/src/lib/tvgRender.h +++ b/src/lib/tvgRender.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #ifndef _TVG_RENDER_H_ #define _TVG_RENDER_H_ diff --git a/src/lib/tvgSaveModule.h b/src/lib/tvgSaveModule.h index 3531662..545252b 100644 --- a/src/lib/tvgSaveModule.h +++ b/src/lib/tvgSaveModule.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2021 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #ifndef _TVG_SAVE_MODULE_H_ #define _TVG_SAVE_MODULE_H_ diff --git a/src/lib/tvgSaver.cpp b/src/lib/tvgSaver.cpp index e719537..85b5a37 100644 --- a/src/lib/tvgSaver.cpp +++ b/src/lib/tvgSaver.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2021 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #include "tvgCommon.h" #include "tvgSaveModule.h" diff --git a/src/lib/tvgScene.cpp b/src/lib/tvgScene.cpp index 0beec47..54cbe52 100644 --- a/src/lib/tvgScene.cpp +++ b/src/lib/tvgScene.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #include "tvgSceneImpl.h" /************************************************************************/ diff --git a/src/lib/tvgSceneImpl.h b/src/lib/tvgSceneImpl.h index 6a7614c..2338b60 100644 --- a/src/lib/tvgSceneImpl.h +++ b/src/lib/tvgSceneImpl.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #ifndef _TVG_SCENE_IMPL_H_ #define _TVG_SCENE_IMPL_H_ diff --git a/src/lib/tvgShape.cpp b/src/lib/tvgShape.cpp index e57f2ea..23291eb 100644 --- a/src/lib/tvgShape.cpp +++ b/src/lib/tvgShape.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/lib/tvgShapeImpl.h b/src/lib/tvgShapeImpl.h index 738b21e..8e1fe08 100644 --- a/src/lib/tvgShapeImpl.h +++ b/src/lib/tvgShapeImpl.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #ifndef _TVG_SHAPE_IMPL_H_ #define _TVG_SHAPE_IMPL_H_ diff --git a/src/lib/tvgSwCanvas.cpp b/src/lib/tvgSwCanvas.cpp index b5cae42..325fb33 100644 --- a/src/lib/tvgSwCanvas.cpp +++ b/src/lib/tvgSwCanvas.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #include "tvgCanvasImpl.h" #ifdef THORVG_SW_RASTER_SUPPORT diff --git a/src/lib/tvgTaskScheduler.cpp b/src/lib/tvgTaskScheduler.cpp index 0638f7b..819c8c4 100644 --- a/src/lib/tvgTaskScheduler.cpp +++ b/src/lib/tvgTaskScheduler.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #include #include #include diff --git a/src/lib/tvgTaskScheduler.h b/src/lib/tvgTaskScheduler.h index 163e387..7dd1dce 100644 --- a/src/lib/tvgTaskScheduler.h +++ b/src/lib/tvgTaskScheduler.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #ifndef _TVG_TASK_SCHEDULER_H_ #define _TVG_TASK_SCHEDULER_H_ diff --git a/src/loaders/external_jpg/tvgJpgLoader.cpp b/src/loaders/external_jpg/tvgJpgLoader.cpp index 522c3c7..5920f7c 100644 --- a/src/loaders/external_jpg/tvgJpgLoader.cpp +++ b/src/loaders/external_jpg/tvgJpgLoader.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2021 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/loaders/external_jpg/tvgJpgLoader.h b/src/loaders/external_jpg/tvgJpgLoader.h index 3f82af8..c8c9345 100644 --- a/src/loaders/external_jpg/tvgJpgLoader.h +++ b/src/loaders/external_jpg/tvgJpgLoader.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2021 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #ifndef _TVG_JPG_LOADER_H_ #define _TVG_JPG_LOADER_H_ diff --git a/src/loaders/external_png/tvgPngLoader.cpp b/src/loaders/external_png/tvgPngLoader.cpp index 05db65c..4061a49 100644 --- a/src/loaders/external_png/tvgPngLoader.cpp +++ b/src/loaders/external_png/tvgPngLoader.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/loaders/external_png/tvgPngLoader.h b/src/loaders/external_png/tvgPngLoader.h index 8beff0a..39d5fdb 100644 --- a/src/loaders/external_png/tvgPngLoader.h +++ b/src/loaders/external_png/tvgPngLoader.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #ifndef _TVG_PNG_LOADER_H_ #define _TVG_PNG_LOADER_H_ diff --git a/src/loaders/jpg/tvgJpgLoader.cpp b/src/loaders/jpg/tvgJpgLoader.cpp index d11dfc1..dc50848 100644 --- a/src/loaders/jpg/tvgJpgLoader.cpp +++ b/src/loaders/jpg/tvgJpgLoader.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2021 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/loaders/jpg/tvgJpgLoader.h b/src/loaders/jpg/tvgJpgLoader.h index d6b886c..6d2febe 100644 --- a/src/loaders/jpg/tvgJpgLoader.h +++ b/src/loaders/jpg/tvgJpgLoader.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2021 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #ifndef _TVG_JPG_LOADER_H_ #define _TVG_JPG_LOADER_H_ diff --git a/src/loaders/jpg/tvgJpgd.cpp b/src/loaders/jpg/tvgJpgd.cpp index f4b1d13..6ea2efb 100644 --- a/src/loaders/jpg/tvgJpgd.cpp +++ b/src/loaders/jpg/tvgJpgd.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2021 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/loaders/jpg/tvgJpgd.h b/src/loaders/jpg/tvgJpgd.h index ca9cb35..030fdc2 100644 --- a/src/loaders/jpg/tvgJpgd.h +++ b/src/loaders/jpg/tvgJpgd.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2021 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/loaders/png/tvgLodePng.cpp b/src/loaders/png/tvgLodePng.cpp index 509ccd1..c0ad66d 100644 --- a/src/loaders/png/tvgLodePng.cpp +++ b/src/loaders/png/tvgLodePng.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/loaders/png/tvgLodePng.h b/src/loaders/png/tvgLodePng.h index 0cdac7c..7254a55 100644 --- a/src/loaders/png/tvgLodePng.h +++ b/src/loaders/png/tvgLodePng.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/loaders/png/tvgPngLoader.cpp b/src/loaders/png/tvgPngLoader.cpp index 8f2362c..cc44b0d 100644 --- a/src/loaders/png/tvgPngLoader.cpp +++ b/src/loaders/png/tvgPngLoader.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2021 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #include #include "tvgLoader.h" #include "tvgPngLoader.h" diff --git a/src/loaders/png/tvgPngLoader.h b/src/loaders/png/tvgPngLoader.h index 8f07f64..579d197 100644 --- a/src/loaders/png/tvgPngLoader.h +++ b/src/loaders/png/tvgPngLoader.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2021 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #ifndef _TVG_PNG_LOADER_H_ #define _TVG_PNG_LOADER_H_ diff --git a/src/loaders/raw/tvgRawLoader.cpp b/src/loaders/raw/tvgRawLoader.cpp index 889f130..d8c0559 100644 --- a/src/loaders/raw/tvgRawLoader.cpp +++ b/src/loaders/raw/tvgRawLoader.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #include #include #include "tvgLoader.h" diff --git a/src/loaders/raw/tvgRawLoader.h b/src/loaders/raw/tvgRawLoader.h index e4f3423..d381010 100644 --- a/src/loaders/raw/tvgRawLoader.h +++ b/src/loaders/raw/tvgRawLoader.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #ifndef _TVG_RAW_LOADER_H_ #define _TVG_RAW_LOADER_H_ diff --git a/src/loaders/svg/tvgSvgCssStyle.cpp b/src/loaders/svg/tvgSvgCssStyle.cpp index 478ba5d..6c1679c 100644 --- a/src/loaders/svg/tvgSvgCssStyle.cpp +++ b/src/loaders/svg/tvgSvgCssStyle.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2022 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/loaders/svg/tvgSvgCssStyle.h b/src/loaders/svg/tvgSvgCssStyle.h index 66477c1..228c599 100644 --- a/src/loaders/svg/tvgSvgCssStyle.h +++ b/src/loaders/svg/tvgSvgCssStyle.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2022 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/loaders/svg/tvgSvgLoader.cpp b/src/loaders/svg/tvgSvgLoader.cpp index 31c1450..073f0cf 100644 --- a/src/loaders/svg/tvgSvgLoader.cpp +++ b/src/loaders/svg/tvgSvgLoader.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/loaders/svg/tvgSvgLoader.h b/src/loaders/svg/tvgSvgLoader.h index f224d1a..fc42e5b 100644 --- a/src/loaders/svg/tvgSvgLoader.h +++ b/src/loaders/svg/tvgSvgLoader.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #ifndef _TVG_SVG_LOADER_H_ #define _TVG_SVG_LOADER_H_ diff --git a/src/loaders/svg/tvgSvgLoaderCommon.h b/src/loaders/svg/tvgSvgLoaderCommon.h index 3588cab..9cb78de 100644 --- a/src/loaders/svg/tvgSvgLoaderCommon.h +++ b/src/loaders/svg/tvgSvgLoaderCommon.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #ifndef _TVG_SVG_LOADER_COMMON_H_ #define _TVG_SVG_LOADER_COMMON_H_ diff --git a/src/loaders/svg/tvgSvgPath.cpp b/src/loaders/svg/tvgSvgPath.cpp index a09a279..6195807 100644 --- a/src/loaders/svg/tvgSvgPath.cpp +++ b/src/loaders/svg/tvgSvgPath.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/loaders/svg/tvgSvgPath.h b/src/loaders/svg/tvgSvgPath.h index 8f5f903..4199088 100644 --- a/src/loaders/svg/tvgSvgPath.h +++ b/src/loaders/svg/tvgSvgPath.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/loaders/svg/tvgSvgSceneBuilder.cpp b/src/loaders/svg/tvgSvgSceneBuilder.cpp index 4cb4ffd..6894fa4 100644 --- a/src/loaders/svg/tvgSvgSceneBuilder.cpp +++ b/src/loaders/svg/tvgSvgSceneBuilder.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/loaders/svg/tvgSvgSceneBuilder.h b/src/loaders/svg/tvgSvgSceneBuilder.h index 311f3c8..b4fbcf1 100644 --- a/src/loaders/svg/tvgSvgSceneBuilder.h +++ b/src/loaders/svg/tvgSvgSceneBuilder.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/loaders/svg/tvgSvgUtil.cpp b/src/loaders/svg/tvgSvgUtil.cpp index 7fb108b..af42e82 100644 --- a/src/loaders/svg/tvgSvgUtil.cpp +++ b/src/loaders/svg/tvgSvgUtil.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/loaders/svg/tvgSvgUtil.h b/src/loaders/svg/tvgSvgUtil.h index b5e6e1b..6f94367 100644 --- a/src/loaders/svg/tvgSvgUtil.h +++ b/src/loaders/svg/tvgSvgUtil.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/loaders/svg/tvgXmlParser.cpp b/src/loaders/svg/tvgXmlParser.cpp index 0e2c3fa..77467e0 100644 --- a/src/loaders/svg/tvgXmlParser.cpp +++ b/src/loaders/svg/tvgXmlParser.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/loaders/svg/tvgXmlParser.h b/src/loaders/svg/tvgXmlParser.h index e2761ca..7333bb0 100644 --- a/src/loaders/svg/tvgXmlParser.h +++ b/src/loaders/svg/tvgXmlParser.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/loaders/tvg/tvgTvgBinInterpreter.cpp b/src/loaders/tvg/tvgTvgBinInterpreter.cpp index ffea9d2..2b89d6b 100644 --- a/src/loaders/tvg/tvgTvgBinInterpreter.cpp +++ b/src/loaders/tvg/tvgTvgBinInterpreter.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2021 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #include #ifdef _WIN32 diff --git a/src/loaders/tvg/tvgTvgCommon.h b/src/loaders/tvg/tvgTvgCommon.h index a0762d0..29fa102 100644 --- a/src/loaders/tvg/tvgTvgCommon.h +++ b/src/loaders/tvg/tvgTvgCommon.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2021 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/loaders/tvg/tvgTvgLoader.cpp b/src/loaders/tvg/tvgTvgLoader.cpp index 95d629d..82c578e 100644 --- a/src/loaders/tvg/tvgTvgLoader.cpp +++ b/src/loaders/tvg/tvgTvgLoader.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2021 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #include #include #include "tvgLoader.h" diff --git a/src/loaders/tvg/tvgTvgLoader.h b/src/loaders/tvg/tvgTvgLoader.h index 3ae841a..b98dff8 100644 --- a/src/loaders/tvg/tvgTvgLoader.h +++ b/src/loaders/tvg/tvgTvgLoader.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2021 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/src/savers/tvg/tvgTvgSaver.cpp b/src/savers/tvg/tvgTvgSaver.cpp index e86c377..fe42d39 100644 --- a/src/savers/tvg/tvgTvgSaver.cpp +++ b/src/savers/tvg/tvgTvgSaver.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2021 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #include "tvgMath.h" #include "tvgSaveModule.h" #include "tvgTvgSaver.h" diff --git a/src/savers/tvg/tvgTvgSaver.h b/src/savers/tvg/tvgTvgSaver.h index 4acb35e..0824475 100644 --- a/src/savers/tvg/tvgTvgSaver.h +++ b/src/savers/tvg/tvgTvgSaver.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2021 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -19,6 +19,7 @@ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. */ + #ifndef _TVG_TVGSAVER_H_ #define _TVG_TVGSAVER_H_ diff --git a/src/wasm/thorvgwasm.cpp b/src/wasm/thorvgwasm.cpp index 2fb7431..e84b639 100644 --- a/src/wasm/thorvgwasm.cpp +++ b/src/wasm/thorvgwasm.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2020 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2020 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/test/capi/capiFill.cpp b/test/capi/capiFill.cpp index 2439857..8efd79a 100644 --- a/test/capi/capiFill.cpp +++ b/test/capi/capiFill.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2021 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/test/capi/capiInitializer.cpp b/test/capi/capiInitializer.cpp index cafff1c..1c11185 100644 --- a/test/capi/capiInitializer.cpp +++ b/test/capi/capiInitializer.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2021 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/test/capi/capiLinearGradient.cpp b/test/capi/capiLinearGradient.cpp index 91caa4d..3dd0729 100644 --- a/test/capi/capiLinearGradient.cpp +++ b/test/capi/capiLinearGradient.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2021 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/test/capi/capiPaint.cpp b/test/capi/capiPaint.cpp index 22702bb..e1743c3 100644 --- a/test/capi/capiPaint.cpp +++ b/test/capi/capiPaint.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2021 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/test/capi/capiPicture.cpp b/test/capi/capiPicture.cpp index 62d3925..073c58d 100644 --- a/test/capi/capiPicture.cpp +++ b/test/capi/capiPicture.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2021 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/test/capi/capiRadialGradient.cpp b/test/capi/capiRadialGradient.cpp index 6b977b6..8d5f6fe 100644 --- a/test/capi/capiRadialGradient.cpp +++ b/test/capi/capiRadialGradient.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2021 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/test/capi/capiSavers.cpp b/test/capi/capiSavers.cpp index 52b2ce7..48f223c 100644 --- a/test/capi/capiSavers.cpp +++ b/test/capi/capiSavers.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2021 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/test/capi/capiScene.cpp b/test/capi/capiScene.cpp index 38235d4..fb51630 100644 --- a/test/capi/capiScene.cpp +++ b/test/capi/capiScene.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2021 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/test/capi/capiShape.cpp b/test/capi/capiShape.cpp index b97caa3..b20a515 100644 --- a/test/capi/capiShape.cpp +++ b/test/capi/capiShape.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2021 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/test/capi/capiSwCanvas.cpp b/test/capi/capiSwCanvas.cpp index 4e22443..c3c1863 100644 --- a/test/capi/capiSwCanvas.cpp +++ b/test/capi/capiSwCanvas.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2021 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/test/testAccessor.cpp b/test/testAccessor.cpp index f5bf052..dd22ce7 100644 --- a/test/testAccessor.cpp +++ b/test/testAccessor.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2022 ThorVG Project. All rights reserved. + * Copyright (c) 2022 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/test/testFill.cpp b/test/testFill.cpp index 50a0cab..7dd0ded 100644 --- a/test/testFill.cpp +++ b/test/testFill.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2021 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/test/testInitializer.cpp b/test/testInitializer.cpp index 826229c..027a2c6 100644 --- a/test/testInitializer.cpp +++ b/test/testInitializer.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2021 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/test/testPaint.cpp b/test/testPaint.cpp index 1ef05f1..e96ed8a 100644 --- a/test/testPaint.cpp +++ b/test/testPaint.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2021 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/test/testPicture.cpp b/test/testPicture.cpp index 09e5f99..7d19d5a 100644 --- a/test/testPicture.cpp +++ b/test/testPicture.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2021 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/test/testSavers.cpp b/test/testSavers.cpp index bdb2062..949f460 100644 --- a/test/testSavers.cpp +++ b/test/testSavers.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2021 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/test/testScene.cpp b/test/testScene.cpp index a80d37e..9d5d062 100644 --- a/test/testScene.cpp +++ b/test/testScene.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2021 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/test/testShape.cpp b/test/testShape.cpp index 0e4bfc3..a4a82c4 100644 --- a/test/testShape.cpp +++ b/test/testShape.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2021 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/test/testSwCanvas.cpp b/test/testSwCanvas.cpp index 111d34c..735f14f 100644 --- a/test/testSwCanvas.cpp +++ b/test/testSwCanvas.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2021 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/test/testSwCanvasBase.cpp b/test/testSwCanvasBase.cpp index 32e5f51..97dd197 100644 --- a/test/testSwCanvasBase.cpp +++ b/test/testSwCanvasBase.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2021 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal diff --git a/test/testSwEngine.cpp b/test/testSwEngine.cpp index 4cb2250..405098d 100644 --- a/test/testSwEngine.cpp +++ b/test/testSwEngine.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 - 2022 Samsung Electronics Co., Ltd. All rights reserved. + * Copyright (c) 2021 - 2023 the ThorVG project. All rights reserved. * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal -- 2.7.4 From ec09c94d621e1f12bb5460764fa666c530c86eb6 Mon Sep 17 00:00:00 2001 From: Mira Grudzinska Date: Tue, 17 Jan 2023 13:11:43 +0100 Subject: [PATCH 06/16] svg_loader: overwrite the clip's opacity/alpha According to the svg standard the clips opacity doesn't affect the final rendering. In order to avoid any confusion the opacity values are overwritten by the max possible value. Change-Id: Ife206ab742023bd3e4d2f0952f0a51ce2b53e75a --- src/loaders/svg/tvgSvgSceneBuilder.cpp | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/loaders/svg/tvgSvgSceneBuilder.cpp b/src/loaders/svg/tvgSvgSceneBuilder.cpp index 6894fa4..f60c0f6 100644 --- a/src/loaders/svg/tvgSvgSceneBuilder.cpp +++ b/src/loaders/svg/tvgSvgSceneBuilder.cpp @@ -255,7 +255,6 @@ static void _applyComposition(Paint* paint, const SvgNode* node, const Box& vBox node->style->clipPath.applying = true; auto comp = Shape::gen(); - comp->fill(255, 255, 255, 255); if (node->transform) comp->transform(*node->transform); auto child = compNode->child.data; @@ -265,8 +264,11 @@ static void _applyComposition(Paint* paint, const SvgNode* node, const Box& vBox if (_appendChildShape(*child, comp.get(), vBox, svgPath)) valid = true; } - if (valid) paint->composite(move(comp), CompositeMethod::ClipPath); - + if (valid) { + comp->fill(255, 255, 255, 255); + comp->opacity(255); + paint->composite(move(comp), CompositeMethod::ClipPath); + } node->style->clipPath.applying = false; } } -- 2.7.4 From 691cfa2d2446c2a343ea5d245522a93e7a1a6512 Mon Sep 17 00:00:00 2001 From: Mira Grudzinska Date: Tue, 27 Dec 2022 16:21:42 +0100 Subject: [PATCH 07/16] common: ignoring color/alpha/opacity of a clip object According to the svg specs clip's fill and opacity should be ignored. Till now setting the alpha/opacity value to zero resulted in the shape's rendering abort. @Issue: https://github.com/Samsung/thorvg/issues/1192 Change-Id: I03369fe91f811e7d6950dab1b594824cbfb7f9fe --- inc/thorvg.h | 14 ++++++++++++++ src/lib/sw_engine/tvgSwRenderer.cpp | 8 +++++--- src/lib/tvgPaint.cpp | 13 +++++++++++++ src/lib/tvgPaint.h | 2 ++ 4 files changed, 34 insertions(+), 3 deletions(-) diff --git a/inc/thorvg.h b/inc/thorvg.h index 594fe9b..45eeb5b 100644 --- a/inc/thorvg.h +++ b/inc/thorvg.h @@ -364,6 +364,20 @@ public: CompositeMethod composite(const Paint** target) const noexcept; /** + * @brief Gets the composition source object and the composition method. + * + * @param[out] source The paint of the composition source object. + * @param[out] method The method used to composite the source object with the target. + * + * @return Result::Success when the paint object used as a composition target, Result::InsufficientCondition otherwise. + * + * @warning Please do not use it, this API is not official one. It could be modified in the next version. + * + * @BETA_API + */ + Result composite(const Paint** source, CompositeMethod* method) const noexcept; + + /** * @brief Return the unique id value of the paint instance. * * This method can be called for checking the current concrete instance type. diff --git a/src/lib/sw_engine/tvgSwRenderer.cpp b/src/lib/sw_engine/tvgSwRenderer.cpp index 6e7b738..a303d2d 100644 --- a/src/lib/sw_engine/tvgSwRenderer.cpp +++ b/src/lib/sw_engine/tvgSwRenderer.cpp @@ -77,7 +77,9 @@ struct SwShapeTask : SwTask void run(unsigned tid) override { - if (opacity == 0) return; //Invisible + auto compMethod = CompositeMethod::None; + auto usedAsClip = (sdata->composite(nullptr, &compMethod) == Result::Success) && (compMethod == CompositeMethod::ClipPath); + if (opacity == 0 && !usedAsClip) return; //Invisible uint8_t strokeAlpha = 0; auto visibleStroke = false; @@ -99,7 +101,7 @@ struct SwShapeTask : SwTask sdata->fillColor(nullptr, nullptr, nullptr, &alpha); alpha = static_cast(static_cast(alpha) * opacity / 255); visibleFill = (alpha > 0 || sdata->fill()); - if (visibleFill || visibleStroke) { + if (visibleFill || visibleStroke || usedAsClip) { shapeReset(&shape); if (!shapePrepare(&shape, sdata, transform, clipRegion, bbox, mpool, tid, clips.count > 0 ? true : false)) goto err; } @@ -111,7 +113,7 @@ struct SwShapeTask : SwTask //Fill if (flags & (RenderUpdateFlag::Gradient | RenderUpdateFlag::Transform | RenderUpdateFlag::Color)) { - if (visibleFill) { + if (visibleFill || usedAsClip) { /* We assume that if stroke width is bigger than 2, shape outline below stroke could be full covered by stroke drawing. Thus it turns off antialising in that condition. diff --git a/src/lib/tvgPaint.cpp b/src/lib/tvgPaint.cpp index 05b7078..ba5b050 100644 --- a/src/lib/tvgPaint.cpp +++ b/src/lib/tvgPaint.cpp @@ -385,6 +385,19 @@ CompositeMethod Paint::composite(const Paint** target) const noexcept } +Result Paint::composite(const Paint** source, CompositeMethod* method) const noexcept +{ + if (source) *source = pImpl->compSource; + auto met = (pImpl->compSource && pImpl->compSource->pImpl->compData ? + pImpl->compSource->pImpl->compData->method : CompositeMethod::None); + if (method) *method = met; + + if (pImpl->compSource != nullptr && met != CompositeMethod::None) + return Result::Success; + return Result::InsufficientCondition; +} + + Result Paint::opacity(uint8_t o) noexcept { if (pImpl->opacity == o) return Result::Success; diff --git a/src/lib/tvgPaint.h b/src/lib/tvgPaint.h index c54b97a..a0bd3c9 100644 --- a/src/lib/tvgPaint.h +++ b/src/lib/tvgPaint.h @@ -63,6 +63,7 @@ namespace tvg StrategyMethod* smethod = nullptr; RenderTransform* rTransform = nullptr; Composite* compData = nullptr; + Paint* compSource = nullptr; uint32_t renderFlag = RenderUpdateFlag::None; uint32_t ctxFlag = ContextFlag::Invalid; uint32_t id; @@ -137,6 +138,7 @@ namespace tvg if (!target && method == CompositeMethod::None) return true; compData = static_cast(calloc(1, sizeof(Composite))); } + target->pImpl->compSource = source; compData->target = target; compData->source = source; compData->method = method; -- 2.7.4 From 6b524ab9c8418de2b85b2c13b89c9c770136d982 Mon Sep 17 00:00:00 2001 From: Mira Grudzinska Date: Sun, 15 Jan 2023 16:39:25 +0100 Subject: [PATCH 08/16] examples: ClipPath's modified The opacity/alpha value doesn't need to be set for clips any more. Change-Id: Ia2ea6f99f1d9c666348e3ef1cfb57629972296c9 --- src/examples/ClipPath.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/examples/ClipPath.cpp b/src/examples/ClipPath.cpp index 067e713..ca84356 100644 --- a/src/examples/ClipPath.cpp +++ b/src/examples/ClipPath.cpp @@ -63,9 +63,9 @@ void tvgDrawCmds(tvg::Canvas* canvas) //Move Star1 star1->translate(-10, -10); + // color/alpha/opacity are ignored for a clip object - no need to set them auto clipStar = tvg::Shape::gen(); clipStar->appendCircle(200, 230, 110, 110); - clipStar->fill(255, 255, 255, 255); // clip object must have alpha. clipStar->translate(10, 10); star1->composite(move(clipStar), tvg::CompositeMethod::ClipPath); @@ -80,9 +80,9 @@ void tvgDrawCmds(tvg::Canvas* canvas) //Move Star2 star2->translate(10, 40); + // color/alpha/opacity are ignored for a clip object - no need to set them auto clip = tvg::Shape::gen(); clip->appendCircle(200, 230, 130, 130); - clip->fill(255, 255, 255, 255); // clip object must have alpha. clip->translate(10, 10); scene->push(move(star1)); @@ -110,9 +110,9 @@ void tvgDrawCmds(tvg::Canvas* canvas) star3->stroke(10); star3->translate(400, 0); + // color/alpha/opacity are ignored for a clip object - no need to set them auto clipRect = tvg::Shape::gen(); clipRect->appendRect(500, 120, 200, 200, 0, 0); //x, y, w, h, rx, ry - clipRect->fill(255, 255, 255, 255); // clip object must have alpha. clipRect->translate(20, 20); //Clipping scene to rect(shape) @@ -127,10 +127,10 @@ void tvgDrawCmds(tvg::Canvas* canvas) picture->scale(3); picture->translate(50, 400); + // color/alpha/opacity are ignored for a clip object - no need to set them auto clipPath = tvg::Shape::gen(); clipPath->appendCircle(200, 510, 50, 50); //x, y, w, h, rx, ry clipPath->appendCircle(200, 650, 50, 50); //x, y, w, h, rx, ry - clipPath->fill(255, 255, 255, 255); // clip object must have alpha. clipPath->translate(20, 20); //Clipping picture to path @@ -143,9 +143,9 @@ void tvgDrawCmds(tvg::Canvas* canvas) shape1->appendRect(500, 420, 100, 100, 20, 20); shape1->fill(255, 0, 255, 160); + // color/alpha/opacity are ignored for a clip object - no need to set them auto clipShape = tvg::Shape::gen(); clipShape->appendRect(600, 420, 100, 100, 0, 0); - clipShape->fill(255, 0, 255, 150); //Clipping shape1 to clipShape shape1->composite(move(clipShape), tvg::CompositeMethod::ClipPath); -- 2.7.4 From 8d9968954d01022937181b1a5bb35757348ac4a3 Mon Sep 17 00:00:00 2001 From: Hermet Park Date: Sun, 22 Jan 2023 09:55:10 +0900 Subject: [PATCH 09/16] example: correct clipper usage. it has been changed by 0de3872be33793d2c8db03d5b85da38670410626 Change-Id: I4e07b5bf178f13387dad526772d2ab6c68c57f14 --- src/examples/PictureRaw.cpp | 1 - 1 file changed, 1 deletion(-) diff --git a/src/examples/PictureRaw.cpp b/src/examples/PictureRaw.cpp index 94261c4..bdae972 100644 --- a/src/examples/PictureRaw.cpp +++ b/src/examples/PictureRaw.cpp @@ -61,7 +61,6 @@ void tvgDrawCmds(tvg::Canvas* canvas) auto circle = tvg::Shape::gen(); circle->appendCircle(350, 350, 200,200); - circle->fill(255, 255, 255, 255); picture2->composite(move(circle), tvg::CompositeMethod::ClipPath); -- 2.7.4 From 4dcb2246359bd9d85a3ecc60a6bc70144d9bb0b7 Mon Sep 17 00:00:00 2001 From: Hermet Park Date: Sun, 22 Jan 2023 09:53:27 +0900 Subject: [PATCH 10/16] svg loader: correct clipper usage. that has been changed by 0de3872be33793d2c8db03d5b85da38670410626 Change-Id: Id77eb8df0063ef4ddd42ed7cf94a05a076486ed8 --- src/loaders/svg/tvgSvgSceneBuilder.cpp | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/src/loaders/svg/tvgSvgSceneBuilder.cpp b/src/loaders/svg/tvgSvgSceneBuilder.cpp index f60c0f6..5e97b74 100644 --- a/src/loaders/svg/tvgSvgSceneBuilder.cpp +++ b/src/loaders/svg/tvgSvgSceneBuilder.cpp @@ -264,11 +264,8 @@ static void _applyComposition(Paint* paint, const SvgNode* node, const Box& vBox if (_appendChildShape(*child, comp.get(), vBox, svgPath)) valid = true; } - if (valid) { - comp->fill(255, 255, 255, 255); - comp->opacity(255); - paint->composite(move(comp), CompositeMethod::ClipPath); - } + if (valid) paint->composite(move(comp), CompositeMethod::ClipPath); + node->style->clipPath.applying = false; } } -- 2.7.4 From 5eb9b5207205d6a53dd087eb65340661b13d1ac0 Mon Sep 17 00:00:00 2001 From: Hermet Park Date: Sun, 22 Jan 2023 10:15:03 +0900 Subject: [PATCH 11/16] doc: updated the header description. Change-Id: Ib5fc0343dce8adef2ffdeefca583219aeafe1d90 --- inc/thorvg.h | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/inc/thorvg.h b/inc/thorvg.h index 45eeb5b..c5a140f 100644 --- a/inc/thorvg.h +++ b/inc/thorvg.h @@ -2,11 +2,12 @@ * @file thorvg.h * * The main APIs enabling the TVG initialization, preparation of the canvas and provisioning of its content: - * - drawing shapes such as line, curve, arc, rectangle, circle or user-defined - * - drawing pictures - SVG, PNG, JPG, RAW - * - solid or gradient filling - * - continuous and dashed stroking - * - clipping and masking + * - drawing shapes: line, arc, curve, path, polygon... + * - drawing pictures: tvg, svg, png, jpg, bitmap... + * - drawing fillings: solid, linear and radial gradient... + * - drawing stroking: continuous stroking with arbitrary width, join, cap, dash styles. + * - drawing composition: blending, masking, path clipping... + * - drawing scene graph & affine transformation (translation, rotation, scale, ...) * and finally drawing the canvas and TVG termination. */ @@ -291,6 +292,7 @@ public: * @return Result::Success when succeed. * * @note Setting the opacity with this API may require multiple render pass for composition. It is recommended to avoid changing the opacity if possible. + * @note ClipPath won't use the opacity value. (see: enum class CompositeMethod::ClipPath) */ Result opacity(uint8_t o) noexcept; @@ -963,6 +965,7 @@ public: * @return Result::Success when succeed. * * @note Either a solid color or a gradient fill is applied, depending on what was set as last. + * @note ClipPath won't use the fill values. (see: enum class CompositeMethod::ClipPath) */ Result fill(uint8_t r, uint8_t g, uint8_t b, uint8_t a) noexcept; -- 2.7.4 From c3f1a937d7126450c15c895823404256c44bac13 Mon Sep 17 00:00:00 2001 From: Hermet Park Date: Sat, 28 Jan 2023 11:36:54 +0900 Subject: [PATCH 12/16] updated copyright. Change-Id: I6b3ff60849bdb849ce09555624593145e07af7d3 --- src/lib/gl_engine/tvgGlRenderer.cpp | 2 +- src/lib/gl_engine/tvgGlRenderer.h | 4 ++-- src/lib/sw_engine/tvgSwRenderer.cpp | 14 +++++++------- src/lib/sw_engine/tvgSwRenderer.h | 2 +- src/lib/tvgPaint.cpp | 9 +++++---- src/lib/tvgPaint.h | 8 ++++---- src/lib/tvgPictureImpl.h | 4 ++-- src/lib/tvgRender.h | 2 +- src/lib/tvgSceneImpl.h | 4 ++-- src/lib/tvgShapeImpl.h | 4 ++-- 10 files changed, 27 insertions(+), 26 deletions(-) diff --git a/src/lib/gl_engine/tvgGlRenderer.cpp b/src/lib/gl_engine/tvgGlRenderer.cpp index ce82368..95582fb 100644 --- a/src/lib/gl_engine/tvgGlRenderer.cpp +++ b/src/lib/gl_engine/tvgGlRenderer.cpp @@ -197,7 +197,7 @@ RenderData GlRenderer::prepare(TVG_UNUSED Surface* image, TVG_UNUSED RenderData } -RenderData GlRenderer::prepare(const Shape& shape, RenderData data, const RenderTransform* transform, TVG_UNUSED uint32_t opacity, Array& clips, RenderUpdateFlag flags) +RenderData GlRenderer::prepare(const Shape& shape, RenderData data, const RenderTransform* transform, TVG_UNUSED uint32_t opacity, Array& clips, RenderUpdateFlag flags, TVG_UNUSED bool clipper) { //prepare shape data GlShape* sdata = static_cast(data); diff --git a/src/lib/gl_engine/tvgGlRenderer.h b/src/lib/gl_engine/tvgGlRenderer.h index 790ea31..2688566 100644 --- a/src/lib/gl_engine/tvgGlRenderer.h +++ b/src/lib/gl_engine/tvgGlRenderer.h @@ -30,8 +30,8 @@ class GlRenderer : public RenderMethod public: Surface surface = {nullptr, 0, 0, 0}; - RenderData prepare(const Shape& shape, RenderData data, const RenderTransform* transform, uint32_t opacity, Array& clips, RenderUpdateFlag flags) override; - RenderData prepare(Surface* image, RenderData data, const RenderTransform* transform, uint32_t opacity, Array& clips, RenderUpdateFlag flags) override; + RenderData prepare(const Shape& shape, RenderData data, const RenderTransform* transform, uint32_t opacity, Array& clips, RenderUpdateFlag flags, bool clipper) override; + RenderData prepare(Surface* image, Polygon* triangles, uint32_t triangleCnt, RenderData data, const RenderTransform* transform, uint32_t opacity, Array& clips, RenderUpdateFlag flags) override; bool preRender() override; bool renderShape(RenderData data) override; bool renderImage(RenderData data) override; diff --git a/src/lib/sw_engine/tvgSwRenderer.cpp b/src/lib/sw_engine/tvgSwRenderer.cpp index a303d2d..93d0d5d 100644 --- a/src/lib/sw_engine/tvgSwRenderer.cpp +++ b/src/lib/sw_engine/tvgSwRenderer.cpp @@ -74,12 +74,11 @@ struct SwShapeTask : SwTask SwShape shape; const Shape* sdata = nullptr; bool cmpStroking = false; + bool clipper = false; void run(unsigned tid) override - { - auto compMethod = CompositeMethod::None; - auto usedAsClip = (sdata->composite(nullptr, &compMethod) == Result::Success) && (compMethod == CompositeMethod::ClipPath); - if (opacity == 0 && !usedAsClip) return; //Invisible + { + if (opacity == 0 && !clipper) return; //Invisible uint8_t strokeAlpha = 0; auto visibleStroke = false; @@ -101,7 +100,7 @@ struct SwShapeTask : SwTask sdata->fillColor(nullptr, nullptr, nullptr, &alpha); alpha = static_cast(static_cast(alpha) * opacity / 255); visibleFill = (alpha > 0 || sdata->fill()); - if (visibleFill || visibleStroke || usedAsClip) { + if (visibleFill || visibleStroke || clipper) { shapeReset(&shape); if (!shapePrepare(&shape, sdata, transform, clipRegion, bbox, mpool, tid, clips.count > 0 ? true : false)) goto err; } @@ -113,7 +112,7 @@ struct SwShapeTask : SwTask //Fill if (flags & (RenderUpdateFlag::Gradient | RenderUpdateFlag::Transform | RenderUpdateFlag::Color)) { - if (visibleFill || usedAsClip) { + if (visibleFill || clipper) { /* We assume that if stroke width is bigger than 2, shape outline below stroke could be full covered by stroke drawing. Thus it turns off antialising in that condition. @@ -644,13 +643,14 @@ RenderData SwRenderer::prepare(Surface* image, Polygon* triangles, uint32_t tria } -RenderData SwRenderer::prepare(const Shape& sdata, RenderData data, const RenderTransform* transform, uint32_t opacity, Array& clips, RenderUpdateFlag flags) +RenderData SwRenderer::prepare(const Shape& sdata, RenderData data, const RenderTransform* transform, uint32_t opacity, Array& clips, RenderUpdateFlag flags, bool clipper) { //prepare task auto task = static_cast(data); if (!task) { task = new SwShapeTask; task->sdata = &sdata; + task->clipper = clipper; } return prepareCommon(task, transform, opacity, clips, flags); } diff --git a/src/lib/sw_engine/tvgSwRenderer.h b/src/lib/sw_engine/tvgSwRenderer.h index 460659c..819141f 100644 --- a/src/lib/sw_engine/tvgSwRenderer.h +++ b/src/lib/sw_engine/tvgSwRenderer.h @@ -36,7 +36,7 @@ namespace tvg class SwRenderer : public RenderMethod { public: - RenderData prepare(const Shape& shape, RenderData data, const RenderTransform* transform, uint32_t opacity, Array& clips, RenderUpdateFlag flags) override; + RenderData prepare(const Shape& shape, RenderData data, const RenderTransform* transform, uint32_t opacity, Array& clips, RenderUpdateFlag flags, bool clipper) override; RenderData prepare(Surface* image, Polygon* triangles, uint32_t triangleCnt, RenderData data, const RenderTransform* transform, uint32_t opacity, Array& clips, RenderUpdateFlag flags) override; bool preRender() override; bool renderShape(RenderData data) override; diff --git a/src/lib/tvgPaint.cpp b/src/lib/tvgPaint.cpp index ba5b050..0b49122 100644 --- a/src/lib/tvgPaint.cpp +++ b/src/lib/tvgPaint.cpp @@ -184,7 +184,7 @@ bool Paint::Impl::render(RenderMethod& renderer) } -void* Paint::Impl::update(RenderMethod& renderer, const RenderTransform* pTransform, uint32_t opacity, Array& clips, uint32_t pFlag) +void* Paint::Impl::update(RenderMethod& renderer, const RenderTransform* pTransform, uint32_t opacity, Array& clips, uint32_t pFlag, bool clipper) { if (renderFlag & RenderUpdateFlag::Transform) { if (!rTransform) return nullptr; @@ -224,7 +224,8 @@ void* Paint::Impl::update(RenderMethod& renderer, const RenderTransform* pTransf } } if (!compFastTrack) { - tdata = target->pImpl->update(renderer, pTransform, 255, clips, pFlag); + auto clipper = compData->method == CompositeMethod::ClipPath ? true : false; + tdata = target->pImpl->update(renderer, pTransform, 255, clips, pFlag, clipper); if (method == CompositeMethod::ClipPath) clips.push(tdata); } } @@ -237,10 +238,10 @@ void* Paint::Impl::update(RenderMethod& renderer, const RenderTransform* pTransf if (rTransform && pTransform) { RenderTransform outTransform(pTransform, rTransform); - edata = smethod->update(renderer, &outTransform, opacity, clips, newFlag); + edata = smethod->update(renderer, &outTransform, opacity, clips, newFlag, clipper); } else { auto outTransform = pTransform ? pTransform : rTransform; - edata = smethod->update(renderer, outTransform, opacity, clips, newFlag); + edata = smethod->update(renderer, outTransform, opacity, clips, newFlag, clipper); } /* 3. Composition Post Processing */ diff --git a/src/lib/tvgPaint.h b/src/lib/tvgPaint.h index a0bd3c9..45c679d 100644 --- a/src/lib/tvgPaint.h +++ b/src/lib/tvgPaint.h @@ -43,7 +43,7 @@ namespace tvg virtual ~StrategyMethod() {} virtual bool dispose(RenderMethod& renderer) = 0; - virtual void* update(RenderMethod& renderer, const RenderTransform* transform, uint32_t opacity, Array& clips, RenderUpdateFlag pFlag) = 0; //Return engine data if it has. + virtual void* update(RenderMethod& renderer, const RenderTransform* transform, uint32_t opacity, Array& clips, RenderUpdateFlag pFlag, bool clipper) = 0; //Return engine data if it has. virtual bool render(RenderMethod& renderer) = 0; virtual bool bounds(float* x, float* y, float* w, float* h) = 0; virtual RenderRegion bounds(RenderMethod& renderer) const = 0; @@ -149,7 +149,7 @@ namespace tvg bool scale(float factor); bool translate(float x, float y); bool bounds(float* x, float* y, float* w, float* h, bool transformed); - void* update(RenderMethod& renderer, const RenderTransform* pTransform, uint32_t opacity, Array& clips, uint32_t pFlag); + void* update(RenderMethod& renderer, const RenderTransform* pTransform, uint32_t opacity, Array& clips, uint32_t pFlag, bool clipper = false); bool render(RenderMethod& renderer); Paint* duplicate(); }; @@ -178,9 +178,9 @@ namespace tvg return inst->dispose(renderer); } - void* update(RenderMethod& renderer, const RenderTransform* transform, uint32_t opacity, Array& clips, RenderUpdateFlag renderFlag) override + void* update(RenderMethod& renderer, const RenderTransform* transform, uint32_t opacity, Array& clips, RenderUpdateFlag renderFlag, bool clipper) override { - return inst->update(renderer, transform, opacity, clips, renderFlag); + return inst->update(renderer, transform, opacity, clips, renderFlag, clipper); } bool render(RenderMethod& renderer) override diff --git a/src/lib/tvgPictureImpl.h b/src/lib/tvgPictureImpl.h index e039532..b7e2ba0 100644 --- a/src/lib/tvgPictureImpl.h +++ b/src/lib/tvgPictureImpl.h @@ -126,7 +126,7 @@ struct Picture::Impl else return RenderTransform(pTransform, &tmp); } - void* update(RenderMethod &renderer, const RenderTransform* pTransform, uint32_t opacity, Array& clips, RenderUpdateFlag pFlag) + void* update(RenderMethod &renderer, const RenderTransform* pTransform, uint32_t opacity, Array& clips, RenderUpdateFlag pFlag, bool clipper) { auto flag = reload(); @@ -138,7 +138,7 @@ struct Picture::Impl loader->resize(paint, w, h); resizing = false; } - rdata = paint->pImpl->update(renderer, pTransform, opacity, clips, static_cast(pFlag | flag)); + rdata = paint->pImpl->update(renderer, pTransform, opacity, clips, static_cast(pFlag | flag), clipper); } return rdata; } diff --git a/src/lib/tvgRender.h b/src/lib/tvgRender.h index 34e3101..88fe502 100644 --- a/src/lib/tvgRender.h +++ b/src/lib/tvgRender.h @@ -90,7 +90,7 @@ class RenderMethod { public: virtual ~RenderMethod() {} - virtual RenderData prepare(const Shape& shape, RenderData data, const RenderTransform* transform, uint32_t opacity, Array& clips, RenderUpdateFlag flags) = 0; + virtual RenderData prepare(const Shape& shape, RenderData data, const RenderTransform* transform, uint32_t opacity, Array& clips, RenderUpdateFlag flags, bool clipper) = 0; virtual RenderData prepare(Surface* image, Polygon* triangles, uint32_t triangleCnt, RenderData data, const RenderTransform* transform, uint32_t opacity, Array& clips, RenderUpdateFlag flags) = 0; virtual bool preRender() = 0; virtual bool renderShape(RenderData data) = 0; diff --git a/src/lib/tvgSceneImpl.h b/src/lib/tvgSceneImpl.h index 2338b60..5c07cb5 100644 --- a/src/lib/tvgSceneImpl.h +++ b/src/lib/tvgSceneImpl.h @@ -91,7 +91,7 @@ struct Scene::Impl return false; } - void* update(RenderMethod &renderer, const RenderTransform* transform, uint32_t opacity, Array& clips, RenderUpdateFlag flag) + void* update(RenderMethod &renderer, const RenderTransform* transform, uint32_t opacity, Array& clips, RenderUpdateFlag flag, bool clipper) { /* Overriding opacity value. If this scene is half-translucent, It must do intermeidate composition with that opacity value. */ @@ -99,7 +99,7 @@ struct Scene::Impl if (needComposition(opacity)) opacity = 255; for (auto paint = paints.data; paint < (paints.data + paints.count); ++paint) { - (*paint)->pImpl->update(renderer, transform, opacity, clips, static_cast(flag)); + (*paint)->pImpl->update(renderer, transform, opacity, clips, static_cast(flag), clipper); } /* FXIME: it requires to return list of children engine data diff --git a/src/lib/tvgShapeImpl.h b/src/lib/tvgShapeImpl.h index 8e1fe08..fa2786f 100644 --- a/src/lib/tvgShapeImpl.h +++ b/src/lib/tvgShapeImpl.h @@ -235,9 +235,9 @@ struct Shape::Impl return renderer.renderShape(rdata); } - void* update(RenderMethod& renderer, const RenderTransform* transform, uint32_t opacity, Array& clips, RenderUpdateFlag pFlag) + void* update(RenderMethod& renderer, const RenderTransform* transform, uint32_t opacity, Array& clips, RenderUpdateFlag pFlag, bool clipper) { - this->rdata = renderer.prepare(*shape, this->rdata, transform, opacity, clips, static_cast(pFlag | flag)); + this->rdata = renderer.prepare(*shape, this->rdata, transform, opacity, clips, static_cast(pFlag | flag), clipper); flag = RenderUpdateFlag::None; return this->rdata; } -- 2.7.4 From f84959c2a420462fe621a6650c0baca3150131a9 Mon Sep 17 00:00:00 2001 From: jykeon Date: Wed, 15 Mar 2023 12:35:26 +0900 Subject: [PATCH 13/16] Bump up 0.8.8 Change-Id: Ia2288194406d03caa4149af22e5d1ce495a41f64 Signed-off-by: jykeon --- packaging/thorvg.spec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packaging/thorvg.spec b/packaging/thorvg.spec index aecaafa..f39d1fd 100644 --- a/packaging/thorvg.spec +++ b/packaging/thorvg.spec @@ -1,6 +1,6 @@ Name: thorvg Summary: Thor Vector Graphics Library -Version: 0.8.7 +Version: 0.8.8 Release: 1 Group: Graphics System/Rendering Engine License: MIT -- 2.7.4 From 11b14411c5336432f65b1cbbc97bf3e8e64099fc Mon Sep 17 00:00:00 2001 From: Mira Grudzinska Date: Tue, 17 Jan 2023 13:11:43 +0100 Subject: [PATCH 14/16] svg_loader: overwrite the clip's opacity/alpha According to the svg standard the clips opacity doesn't affect the final rendering. In order to avoid any confusion the opacity values are overwritten by the max possible value. Change-Id: I96699a2f74e97fae0a940e18d834f258a8c4cd86 --- src/loaders/svg/tvgSvgSceneBuilder.cpp | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/loaders/svg/tvgSvgSceneBuilder.cpp b/src/loaders/svg/tvgSvgSceneBuilder.cpp index 5e97b74..f60c0f6 100644 --- a/src/loaders/svg/tvgSvgSceneBuilder.cpp +++ b/src/loaders/svg/tvgSvgSceneBuilder.cpp @@ -264,8 +264,11 @@ static void _applyComposition(Paint* paint, const SvgNode* node, const Box& vBox if (_appendChildShape(*child, comp.get(), vBox, svgPath)) valid = true; } - if (valid) paint->composite(move(comp), CompositeMethod::ClipPath); - + if (valid) { + comp->fill(255, 255, 255, 255); + comp->opacity(255); + paint->composite(move(comp), CompositeMethod::ClipPath); + } node->style->clipPath.applying = false; } } -- 2.7.4 From fc64dddb8a786a90eff11d71c7f3ec0d1f0ec869 Mon Sep 17 00:00:00 2001 From: Mira Grudzinska Date: Tue, 27 Dec 2022 16:21:42 +0100 Subject: [PATCH 15/16] common: ignoring color/alpha/opacity of a clip object According to the svg specs clip's fill and opacity should be ignored. Till now setting the alpha/opacity value to zero resulted in the shape's rendering abort. @Issue: https://github.com/Samsung/thorvg/issues/1192 Change-Id: I76c10068d6d35dc171be3c936c5429ea1a3becf1 --- src/lib/sw_engine/tvgSwRenderer.cpp | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/src/lib/sw_engine/tvgSwRenderer.cpp b/src/lib/sw_engine/tvgSwRenderer.cpp index 93d0d5d..48787a3 100644 --- a/src/lib/sw_engine/tvgSwRenderer.cpp +++ b/src/lib/sw_engine/tvgSwRenderer.cpp @@ -77,8 +77,10 @@ struct SwShapeTask : SwTask bool clipper = false; void run(unsigned tid) override - { - if (opacity == 0 && !clipper) return; //Invisible + { + auto compMethod = CompositeMethod::None; + auto usedAsClip = (sdata->composite(nullptr, &compMethod) == Result::Success) && (compMethod == CompositeMethod::ClipPath); + if (opacity == 0 && !usedAsClip) return; //Invisible uint8_t strokeAlpha = 0; auto visibleStroke = false; @@ -100,7 +102,7 @@ struct SwShapeTask : SwTask sdata->fillColor(nullptr, nullptr, nullptr, &alpha); alpha = static_cast(static_cast(alpha) * opacity / 255); visibleFill = (alpha > 0 || sdata->fill()); - if (visibleFill || visibleStroke || clipper) { + if (visibleFill || visibleStroke || usedAsClip) { shapeReset(&shape); if (!shapePrepare(&shape, sdata, transform, clipRegion, bbox, mpool, tid, clips.count > 0 ? true : false)) goto err; } @@ -112,7 +114,7 @@ struct SwShapeTask : SwTask //Fill if (flags & (RenderUpdateFlag::Gradient | RenderUpdateFlag::Transform | RenderUpdateFlag::Color)) { - if (visibleFill || clipper) { + if (visibleFill || usedAsClip) { /* We assume that if stroke width is bigger than 2, shape outline below stroke could be full covered by stroke drawing. Thus it turns off antialising in that condition. -- 2.7.4 From a335a9458c61e4165ac5d3cdadf04a6a504b2512 Mon Sep 17 00:00:00 2001 From: Hermet Park Date: Sun, 22 Jan 2023 09:53:27 +0900 Subject: [PATCH 16/16] svg loader: correct clipper usage. that has been changed by 0de3872be33793d2c8db03d5b85da38670410626 Change-Id: If0b014910235253416ca8585b6fd5fe336538f4c --- src/loaders/svg/tvgSvgSceneBuilder.cpp | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/src/loaders/svg/tvgSvgSceneBuilder.cpp b/src/loaders/svg/tvgSvgSceneBuilder.cpp index f60c0f6..5e97b74 100644 --- a/src/loaders/svg/tvgSvgSceneBuilder.cpp +++ b/src/loaders/svg/tvgSvgSceneBuilder.cpp @@ -264,11 +264,8 @@ static void _applyComposition(Paint* paint, const SvgNode* node, const Box& vBox if (_appendChildShape(*child, comp.get(), vBox, svgPath)) valid = true; } - if (valid) { - comp->fill(255, 255, 255, 255); - comp->opacity(255); - paint->composite(move(comp), CompositeMethod::ClipPath); - } + if (valid) paint->composite(move(comp), CompositeMethod::ClipPath); + node->style->clipPath.applying = false; } } -- 2.7.4