1/*
2 * Copyright 2018 Google Inc.
3 *
4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file.
6 */
7
8#include "src/core/SkOpts.h"
9
10#define SK_OPTS_NS hsw
11#include "src/core/SkCubicSolver.h"
12#include "src/opts/SkBitmapProcState_opts.h"
13#include "src/opts/SkBlitRow_opts.h"
14#include "src/opts/SkRasterPipeline_opts.h"
15#include "src/opts/SkSwizzler_opts.h"
16#include "src/opts/SkUtils_opts.h"
17#include "src/opts/SkVM_opts.h"
18
19namespace SkOpts {
20 void Init_hsw() {
21 blit_row_color32 = hsw::blit_row_color32;
22 blit_row_s32a_opaque = hsw::blit_row_s32a_opaque;
23
24 S32_alpha_D32_filter_DX = hsw::S32_alpha_D32_filter_DX;
25
26 cubic_solver = SK_OPTS_NS::cubic_solver;
27
28 RGBA_to_BGRA = SK_OPTS_NS::RGBA_to_BGRA;
29 RGBA_to_rgbA = SK_OPTS_NS::RGBA_to_rgbA;
30 RGBA_to_bgrA = SK_OPTS_NS::RGBA_to_bgrA;
31 gray_to_RGB1 = SK_OPTS_NS::gray_to_RGB1;
32 grayA_to_RGBA = SK_OPTS_NS::grayA_to_RGBA;
33 grayA_to_rgbA = SK_OPTS_NS::grayA_to_rgbA;
34 inverted_CMYK_to_RGB1 = SK_OPTS_NS::inverted_CMYK_to_RGB1;
35 inverted_CMYK_to_BGR1 = SK_OPTS_NS::inverted_CMYK_to_BGR1;
36
37 #define M(st) stages_highp[SkRasterPipeline::st] = (StageFn)SK_OPTS_NS::st;
38 SK_RASTER_PIPELINE_STAGES(M)
39 just_return_highp = (StageFn)SK_OPTS_NS::just_return;
40 start_pipeline_highp = SK_OPTS_NS::start_pipeline;
41 #undef M
42
43 #define M(st) stages_lowp[SkRasterPipeline::st] = (StageFn)SK_OPTS_NS::lowp::st;
44 SK_RASTER_PIPELINE_STAGES(M)
45 just_return_lowp = (StageFn)SK_OPTS_NS::lowp::just_return;
46 start_pipeline_lowp = SK_OPTS_NS::lowp::start_pipeline;
47 #undef M
48
49 interpret_skvm = SK_OPTS_NS::interpret_skvm;
50 }
51} // namespace SkOpts
52