Project and Code Structure of CEF3 Developer Series

CEF supports a range of programming languages ​​and operating systems, and can be easily integrated into new or existing projects. It is designed with ease of use and performance in mind.

      CEF3 supports a range of programming languages ​​and operating systems, and can be easily integrated into new or existing projects. It is designed with ease of use and performance in mind. Its purpose is to provide a set of embedded interfaces. It mainly relies on the public Content API to achieve. In order to clearly understand the relationship between them, the following diagram depicts the hierarchical relationship between WebKit, Content API, Chrome, Content shell and CEF3. Chrome browser, content shell and CEF3 are all developed based on content API, they just have different implementations and serve different application scenarios.

      

      Image source: http://blog.csdn.net/milado_nju/article/details/7455373

   Engineering and code structure are the most basic entry points to understand a set of code. After understanding the code structure, you basically know what the code is going to do and how to do it in general. Look at the picture first

       
  1. cefclient/cefsimple: Contains an example of a simple CEF-based application that can be created using the files in the version distribution. The application contains examples of most of the CEF functions.
  2. Debug: Contains the shared library (libcef) for building the debug version and other support libraries required for the platform. This application provides an example of creating the minimal functional browser window required.
  3. Release: Stores the release version of the CEF dynamic library and other library files required to run on the platform.
  4. include : includes the header files required by CEF
  5. libcef_dll: Contains libcef_dll_wrapper static link library source code, the necessary link library for applications using CEF C++ API.
  6. Resource: Contains the source code needed to create CEF applications, this folder also contains .pak files (binary files of global resources) and platform-related image and cursor resources

By the way, the source code downloaded from cefbuilds.com does not have a solution file. You need to use the build system tool to build the solution file sln and then compile it. For details, see Getting Started with CMake and Study Notes

There are several subfolders in the cefclient example after CEF3 3.2272 (corresponding to chromium 41): browser, common, renderer, resources.

  1. browser: Contains the code files used by the browser process, that is, the current main process.
  2. renderer: contains the code files needed by the renderer process
  3. common: Contains common files that implement the main process and the renderer process
  4. resources: mainly pictures, html files, pdf files and mouse cursor resources needed for testing

 

Some dll and resource roles of CEF projects

libcef.dll--------------->Cef's core class library

icudt.dll---------------------------->Class library that supports unicode

ffmpegsumo.dll--------------------->A class library that supports audio and video

d3dcompiler_43.dll----------------->Class library that supports 3D under WinXP

d3dcompiler_46.dll----------------->Win7 and later Win class library that supports 3D

libEGL.dll------------------------->Accelerated Synthesis Support Library

libGLESv2.dll------------>Accelerated Synthesis Support Library

locales---------------------------->This folder stores the language resources of various countries

cef.pak------------------>WebKit related resources (the core of Google Chrome is webkit)

devtools_resources.pak-------------> Debugger related resources

 

By the way, I am using CEF3 version 2.2272, and the development environment is VS2008, Win7. The articles and codes after this are based on this version and development environment. For other versions and development environments, please adapt accordingly, which is generally similar.

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=324411444&siteId=291194637