BigW Consortium Gitlab
Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
L
lvgl
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Forest Godfrey
lvgl
Commits
c9b28c76
Commit
c9b28c76
authored
Nov 27, 2017
by
Gabor Kiss-Vamosi
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
lv_hal: use less general structur elements
parent
c890dc8d
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
10 additions
and
10 deletions
+10
-10
lv_hal_disp.c
lv_hal/lv_hal_disp.c
+4
-4
lv_hal_disp.h
lv_hal/lv_hal_disp.h
+3
-3
lv_hal_indev.c
lv_hal/lv_hal_indev.c
+2
-2
lv_hal_indev.h
lv_hal/lv_hal_indev.h
+1
-1
No files found.
lv_hal/lv_hal_disp.c
View file @
c9b28c76
...
@@ -112,7 +112,7 @@ lv_disp_t * lv_disp_next(lv_disp_t * disp)
...
@@ -112,7 +112,7 @@ lv_disp_t * lv_disp_next(lv_disp_t * disp)
void
lv_disp_fill
(
int32_t
x1
,
int32_t
y1
,
int32_t
x2
,
int32_t
y2
,
lv_color_t
color
)
void
lv_disp_fill
(
int32_t
x1
,
int32_t
y1
,
int32_t
x2
,
int32_t
y2
,
lv_color_t
color
)
{
{
if
(
active
==
NULL
)
return
;
if
(
active
==
NULL
)
return
;
if
(
active
->
driver
.
fill
!=
NULL
)
active
->
driver
.
fill
(
x1
,
y1
,
x2
,
y2
,
color
);
if
(
active
->
driver
.
fill
_fp
!=
NULL
)
active
->
driver
.
fill_fp
(
x1
,
y1
,
x2
,
y2
,
color
);
}
}
/**
/**
...
@@ -126,7 +126,7 @@ void lv_disp_fill(int32_t x1, int32_t y1, int32_t x2, int32_t y2, lv_color_t col
...
@@ -126,7 +126,7 @@ void lv_disp_fill(int32_t x1, int32_t y1, int32_t x2, int32_t y2, lv_color_t col
void
lv_disp_map
(
int32_t
x1
,
int32_t
y1
,
int32_t
x2
,
int32_t
y2
,
const
lv_color_t
*
color_map
)
void
lv_disp_map
(
int32_t
x1
,
int32_t
y1
,
int32_t
x2
,
int32_t
y2
,
const
lv_color_t
*
color_map
)
{
{
if
(
active
==
NULL
)
return
;
if
(
active
==
NULL
)
return
;
if
(
active
->
driver
.
map
!=
NULL
)
active
->
driver
.
ma
p
(
x1
,
y1
,
x2
,
y2
,
color_map
);
if
(
active
->
driver
.
map
_fp
!=
NULL
)
active
->
driver
.
map_f
p
(
x1
,
y1
,
x2
,
y2
,
color_map
);
}
}
...
@@ -141,7 +141,7 @@ void lv_disp_map(int32_t x1, int32_t y1, int32_t x2, int32_t y2, const lv_color_
...
@@ -141,7 +141,7 @@ void lv_disp_map(int32_t x1, int32_t y1, int32_t x2, int32_t y2, const lv_color_
void
lv_disp_copy
(
lv_color_t
*
dest
,
const
lv_color_t
*
src
,
uint32_t
length
,
lv_opa_t
opa
)
void
lv_disp_copy
(
lv_color_t
*
dest
,
const
lv_color_t
*
src
,
uint32_t
length
,
lv_opa_t
opa
)
{
{
if
(
active
==
NULL
)
return
;
if
(
active
==
NULL
)
return
;
if
(
active
->
driver
.
copy
!=
NULL
)
active
->
driver
.
copy
(
dest
,
src
,
length
,
opa
);
if
(
active
->
driver
.
blend_fp
!=
NULL
)
active
->
driver
.
blend_fp
(
dest
,
src
,
length
,
opa
);
}
}
/**
/**
...
@@ -150,7 +150,7 @@ void lv_disp_copy(lv_color_t * dest, const lv_color_t * src, uint32_t length, lv
...
@@ -150,7 +150,7 @@ void lv_disp_copy(lv_color_t * dest, const lv_color_t * src, uint32_t length, lv
*/
*/
bool
lv_disp_is_copy_supported
(
void
)
bool
lv_disp_is_copy_supported
(
void
)
{
{
if
(
active
->
driver
.
copy
)
return
true
;
if
(
active
->
driver
.
blend_fp
)
return
true
;
else
return
false
;
else
return
false
;
}
}
...
...
lv_hal/lv_hal_disp.h
View file @
c9b28c76
...
@@ -32,9 +32,9 @@ extern "C" {
...
@@ -32,9 +32,9 @@ extern "C" {
* Display Driver structure to be registered by HAL
* Display Driver structure to be registered by HAL
*/
*/
typedef
struct
_disp_drv_t
{
typedef
struct
_disp_drv_t
{
void
(
*
fill
)(
int32_t
x1
,
int32_t
y1
,
int32_t
x2
,
int32_t
y2
,
lv_color_t
color
);
void
(
*
fill
_fp
)(
int32_t
x1
,
int32_t
y1
,
int32_t
x2
,
int32_t
y2
,
lv_color_t
color
);
void
(
*
map
)(
int32_t
x1
,
int32_t
y1
,
int32_t
x2
,
int32_t
y2
,
const
lv_color_t
*
color_p
);
void
(
*
map
_fp
)(
int32_t
x1
,
int32_t
y1
,
int32_t
x2
,
int32_t
y2
,
const
lv_color_t
*
color_p
);
void
(
*
copy
)(
lv_color_t
*
dest
,
const
lv_color_t
*
src
,
uint32_t
length
,
lv_opa_t
opa
);
void
(
*
blend_fp
)(
lv_color_t
*
dest
,
const
lv_color_t
*
src
,
uint32_t
length
,
lv_opa_t
opa
);
}
lv_disp_drv_t
;
}
lv_disp_drv_t
;
typedef
struct
_disp_t
{
typedef
struct
_disp_t
{
...
...
lv_hal/lv_hal_indev.c
View file @
c9b28c76
...
@@ -91,8 +91,8 @@ bool lv_indev_read(lv_indev_t * indev, lv_indev_data_t *data)
...
@@ -91,8 +91,8 @@ bool lv_indev_read(lv_indev_t * indev, lv_indev_data_t *data)
{
{
bool
cont
=
false
;
bool
cont
=
false
;
if
(
indev
->
driver
.
get_data
)
{
if
(
indev
->
driver
.
read_fp
)
{
cont
=
indev
->
driver
.
get_data
(
data
);
cont
=
indev
->
driver
.
read_fp
(
data
);
}
else
{
}
else
{
memset
(
data
,
0
,
sizeof
(
lv_indev_data_t
));
memset
(
data
,
0
,
sizeof
(
lv_indev_data_t
));
}
}
...
...
lv_hal/lv_hal_indev.h
View file @
c9b28c76
...
@@ -54,7 +54,7 @@ typedef struct {
...
@@ -54,7 +54,7 @@ typedef struct {
/*Initialized by the user and registered by 'lv_indev_add()'*/
/*Initialized by the user and registered by 'lv_indev_add()'*/
typedef
struct
{
typedef
struct
{
lv_hal_indev_type_t
type
;
/*Input device type*/
lv_hal_indev_type_t
type
;
/*Input device type*/
bool
(
*
get_data
)(
lv_indev_data_t
*
data
);
/*Function pointer to read data. Return 'true' if there is still data to be read (buffered)*/
bool
(
*
read_fp
)(
lv_indev_data_t
*
data
);
/*Function pointer to read data. Return 'true' if there is still data to be read (buffered)*/
}
lv_indev_drv_t
;
}
lv_indev_drv_t
;
struct
_lv_obj_t
;
struct
_lv_obj_t
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment