Giter VIP home page Giter VIP logo

Comments (15)

HermanChen avatar HermanChen commented on May 29, 2024

The cmake script handled the include directories by include_directories in CMakeLists.txt

from mpp.

Nybon avatar Nybon commented on May 29, 2024

I changed my build system to cmake and here is my CMakeLists.txt file.
Capture
What should I add to my CMakeLists.txt?

from mpp.

HermanChen avatar HermanChen commented on May 29, 2024

include_directories(your_directory)

from mpp.

Nybon avatar Nybon commented on May 29, 2024

Capture
I'm now able to find all the headers, but I am not able to use the functions. What should I write in my CMakeLists.txt to fix this?

from mpp.

HermanChen avatar HermanChen commented on May 29, 2024

You also need to add more source code.
The mpp_packet is in mpp/base/

from mpp.

Nybon avatar Nybon commented on May 29, 2024

This example https://github.com/WainDing/mpp_linux_cpp/blob/master/CMakeLists.txt imports the whole library with target_link_libraries(mpp_linux_demo mpp pthread drm).

Can I use something similar in my situation?

I added these lines to my CMakeLists.txt file:
include_directories(inc)
include_directories(utils)
include_directories(osal/inc)
include_directories(mpp/inc)
add_subdirectory(mpp)
Capture

from mpp.

HermanChen avatar HermanChen commented on May 29, 2024

Yes, it is right.

from mpp.

Nybon avatar Nybon commented on May 29, 2024

I am using target_link_libraries(mpp_linux_demo mpp pthread drm).

I have included the following directories:
include_directories(inc)
include_directories(utils)
include_directories(osal/inc)
include_directories(mpp/inc)
include_directories(mpp/hal/inc)
add_subdirectory(mpp)

And I am still getting the error messages shown in the picture above.

from mpp.

HermanChen avatar HermanChen commented on May 29, 2024

Sub-directory should be also added. The sub-diretory CMakeLists.txt should be recursively included.

from mpp.

Nybon avatar Nybon commented on May 29, 2024

I have added:
add_subdirectory(mpp)
add_subdirectory(osal)
add_subdirectory(utils)
add_subdirectory(test)
add_subdirectory(mpp-develop)
add_subdirectory(hal)
add_subdirectory(base)
add_subdirectory(codec)
add_subdirectory(mpp/legacy)
add_subdirectory(mpp/hal)
add_subdirectory(mpp)
add_subdirectory(osal)
add_subdirectory(test)
add_subdirectory(utils)
add_subdirectory(mpp/hal)
add_subdirectory(mpp/base)
add_subdirectory(mpp/codec)
add_subdirectory(mpp/vproc)
add_subdirectory(osal/test)
add_subdirectory(mpp/legacy)
add_subdirectory(mpp/hal/vpu)
add_subdirectory(mpp/codec/rc)
add_subdirectory(mpp/base/test)
add_subdirectory(mpp/codec/dec)
add_subdirectory(mpp/codec/enc)
add_subdirectory(mpp/hal/dummy)
add_subdirectory(mpp/hal/rkenc)
add_subdirectory(mpp/vproc/iep)
add_subdirectory(mpp/vproc/rga)
add_subdirectory(mpp/hal/common)
add_subdirectory(mpp/hal/vpu/common)
add_subdirectory(mpp/vproc/iep/test)

But nothing new happens.

from mpp.

HermanChen avatar HermanChen commented on May 29, 2024

add_subdirectory is to add the CMakeLists.txt in the subdirectory. Use include_directories also to add include directory.

from mpp.

EhsanVahab avatar EhsanVahab commented on May 29, 2024

I have added: add_subdirectory(mpp) add_subdirectory(osal) add_subdirectory(utils) add_subdirectory(test) add_subdirectory(mpp-develop) add_subdirectory(hal) add_subdirectory(base) add_subdirectory(codec) add_subdirectory(mpp/legacy) add_subdirectory(mpp/hal) add_subdirectory(mpp) add_subdirectory(osal) add_subdirectory(test) add_subdirectory(utils) add_subdirectory(mpp/hal) add_subdirectory(mpp/base) add_subdirectory(mpp/codec) add_subdirectory(mpp/vproc) add_subdirectory(osal/test) add_subdirectory(mpp/legacy) add_subdirectory(mpp/hal/vpu) add_subdirectory(mpp/codec/rc) add_subdirectory(mpp/base/test) add_subdirectory(mpp/codec/dec) add_subdirectory(mpp/codec/enc) add_subdirectory(mpp/hal/dummy) add_subdirectory(mpp/hal/rkenc) add_subdirectory(mpp/vproc/iep) add_subdirectory(mpp/vproc/rga) add_subdirectory(mpp/hal/common) add_subdirectory(mpp/hal/vpu/common) add_subdirectory(mpp/vproc/iep/test)

But nothing new happens.

Dear @Nybon
did you solve the problem?
could you please share your experience?

from mpp.

Nybon avatar Nybon commented on May 29, 2024

I have added: add_subdirectory(mpp) add_subdirectory(osal) add_subdirectory(utils) add_subdirectory(test) add_subdirectory(mpp-develop) add_subdirectory(hal) add_subdirectory(base) add_subdirectory(codec) add_subdirectory(mpp/legacy) add_subdirectory(mpp/hal) add_subdirectory(mpp) add_subdirectory(osal) add_subdirectory(test) add_subdirectory(utils) add_subdirectory(mpp/hal) add_subdirectory(mpp/base) add_subdirectory(mpp/codec) add_subdirectory(mpp/vproc) add_subdirectory(osal/test) add_subdirectory(mpp/legacy) add_subdirectory(mpp/hal/vpu) add_subdirectory(mpp/codec/rc) add_subdirectory(mpp/base/test) add_subdirectory(mpp/codec/dec) add_subdirectory(mpp/codec/enc) add_subdirectory(mpp/hal/dummy) add_subdirectory(mpp/hal/rkenc) add_subdirectory(mpp/vproc/iep) add_subdirectory(mpp/vproc/rga) add_subdirectory(mpp/hal/common) add_subdirectory(mpp/hal/vpu/common) add_subdirectory(mpp/vproc/iep/test)
But nothing new happens.

Dear @Nybon did you solve the problem? could you please share your experience?

I never got it to work, but I found another solution. The project contains samples that will run fine. Try editing the samples instead of building the whole thing from scrath. It may be a bit messy, but it will at least work. Please share a better way to do this if you find one. Remember to keep the same file positions!

from mpp.

EhsanVahab avatar EhsanVahab commented on May 29, 2024

I have added: add_subdirectory(mpp) add_subdirectory(osal) add_subdirectory(utils) add_subdirectory(test) add_subdirectory(mpp-develop) add_subdirectory(hal) add_subdirectory(base) add_subdirectory(codec) add_subdirectory(mpp/legacy) add_subdirectory(mpp/hal) add_subdirectory(mpp) add_subdirectory(osal) add_subdirectory(test) add_subdirectory(utils) add_subdirectory(mpp/hal) add_subdirectory(mpp/base) add_subdirectory(mpp/codec) add_subdirectory(mpp/vproc) add_subdirectory(osal/test) add_subdirectory(mpp/legacy) add_subdirectory(mpp/hal/vpu) add_subdirectory(mpp/codec/rc) add_subdirectory(mpp/base/test) add_subdirectory(mpp/codec/dec) add_subdirectory(mpp/codec/enc) add_subdirectory(mpp/hal/dummy) add_subdirectory(mpp/hal/rkenc) add_subdirectory(mpp/vproc/iep) add_subdirectory(mpp/vproc/rga) add_subdirectory(mpp/hal/common) add_subdirectory(mpp/hal/vpu/common) add_subdirectory(mpp/vproc/iep/test)
But nothing new happens.

Dear @Nybon did you solve the problem? could you please share your experience?

I never got it to work, but I found another solution. The project contains samples that will run fine. Try editing the samples instead of building the whole thing from scrath. It may be a bit messy, but it will at least work. Please share a better way to do this if you find one. Remember to keep the same file positions!

I'm trying to make a simple and clear C++ example.
let you know if I do.

from mpp.

EhsanVahab avatar EhsanVahab commented on May 29, 2024

I have added: add_subdirectory(mpp) add_subdirectory(osal) add_subdirectory(utils) add_subdirectory(test) add_subdirectory(mpp-develop) add_subdirectory(hal) add_subdirectory(base) add_subdirectory(codec) add_subdirectory(mpp/legacy) add_subdirectory(mpp/hal) add_subdirectory(mpp) add_subdirectory(osal) add_subdirectory(test) add_subdirectory(utils) add_subdirectory(mpp/hal) add_subdirectory(mpp/base) add_subdirectory(mpp/codec) add_subdirectory(mpp/vproc) add_subdirectory(osal/test) add_subdirectory(mpp/legacy) add_subdirectory(mpp/hal/vpu) add_subdirectory(mpp/codec/rc) add_subdirectory(mpp/base/test) add_subdirectory(mpp/codec/dec) add_subdirectory(mpp/codec/enc) add_subdirectory(mpp/hal/dummy) add_subdirectory(mpp/hal/rkenc) add_subdirectory(mpp/vproc/iep) add_subdirectory(mpp/vproc/rga) add_subdirectory(mpp/hal/common) add_subdirectory(mpp/hal/vpu/common) add_subdirectory(mpp/vproc/iep/test)
But nothing new happens.

Dear @Nybon did you solve the problem? could you please share your experience?

I never got it to work, but I found another solution. The project contains samples that will run fine. Try editing the samples instead of building the whole thing from scrath. It may be a bit messy, but it will at least work. Please share a better way to do this if you find one. Remember to keep the same file positions!

dear @Nybon
I finally could Make it and use Opencv frame as input frame.
https://github.com/EhsanVahab/rockchip-mpp-encoder

from mpp.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.