Skip to content

Commit

Permalink
Add C compatible interface for libultrahdr library
Browse files Browse the repository at this point in the history
Test: ./ultrahdr_unit_test

Co-authored-by: Aayush Soni <[email protected]>
Change-Id: I99d8ada4b0850630bc14a1c33a764a00e6f09e9f
  • Loading branch information
aayushsoni111 authored and ram-mohan committed Mar 18, 2024
1 parent f876210 commit 9096d4d
Show file tree
Hide file tree
Showing 8 changed files with 2,428 additions and 327 deletions.
6 changes: 5 additions & 1 deletion Android.bp
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,10 @@ cc_library {
name: "libultrahdr",
host_supported: true,
vendor_available: true,
export_include_dirs: ["lib/include"],
export_include_dirs: [
".",
"lib/include",
],
local_include_dirs: ["lib/include"],

srcs: [
Expand All @@ -44,6 +47,7 @@ cc_library {
"lib/src/gainmapmath.cpp",
"lib/src/jpegrutils.cpp",
"lib/src/multipictureformat.cpp",
"lib/src/ultrahdr_api.cpp",
],

shared_libs: [
Expand Down
3 changes: 2 additions & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -122,6 +122,7 @@ if(MSVC)
add_compile_options(/wd4267) # conversion from 'size_t' to 'type' possible loss of data
add_compile_options(/wd4305) # truncation from 'double' to 'float'
add_compile_options(/wd4838) # conversion from 'type1' to 'type2' requires a narrowing conversion
add_compile_options(/wd26812) # Prefer enum class over enum
else()
add_compile_options(-ffunction-sections)
add_compile_options(-fdata-sections)
Expand Down Expand Up @@ -299,7 +300,7 @@ file(GLOB UHDR_TEST_LIST "${TESTS_DIR}/*.cpp")
file(GLOB UHDR_BM_LIST "${BENCHMARK_DIR}/*.cpp")
file(GLOB IMAGE_IO_LIST "${THIRD_PARTY_DIR}/image_io/src/**/*.cc")

set(COMMON_INCLUDE_LIST ${SOURCE_DIR}/include/ ${JPEG_INCLUDE_DIRS})
set(COMMON_INCLUDE_LIST ${CMAKE_SOURCE_DIR} ${SOURCE_DIR}/include/ ${JPEG_INCLUDE_DIRS})
set(COMMON_LIBS_LIST ${JPEG_LIBRARIES} Threads::Threads)

###########################################################
Expand Down
Loading

0 comments on commit 9096d4d

Please sign in to comment.