Chromium Embedded Framework MP3 support - mp3

I've downloaded Chromium Embedded Framework r306 for Windows and built it. Unfortunately, it shows, that it doesn't support mp3:
<script>
var a = document.createElement("audio");
document.write(a.canPlayType('audio/mpeg'));
</script>
Output is empty and when I try to open an mp3 file, it can't be played (ogg is playable).
The same time Google Chrome writes "maybe" (and it actually plays).
How can I add support for MP3 in CEF?

Marshall Greenblatt (the maintainer of the Chromium Embedded Framework) addresses the lack of support for MP3 (and AAC) in Chromium and CEF in this bug report (see comment #7, copied below):
Codecs like MP3 and AAC are included in Google Chrome releases but not Chromium builds. This is because these formats are not open and require licensing. Distributing these codecs with your application without a licensing agreement may violate the law in certain countries. You should discuss with a lawyer if appropriate.

NOTE: PLEASE CONSIDER LEGAL ISSUES BEFORE PROCEEDING
There is a way to enable MP3 support in CEF, but you'll have to modify the cef.gypi in the source distribution, regenerate the visual studio projects and rebuild.
Step by step instructions:
a
a

There is a way to enable MP3 support in CEF, but you'll have to modify the cef.gypi in the source distribution, regenerate the visual studio projects and rebuild.
Detailed build instructions:
https://bitbucket.org/chromiumembedded/cef/wiki/BranchesAndBuilding
Enabling proprietary codecs support:
http://code.google.com/p/chromiumembedded/issues/detail?id=371
Add 'proprietary_codecs': 1 to your cef.gypi configuration so that USE_PROPRIETARY_CODECS will be defined as required by net/base/mime_util.cc.
You'll also need proper builds of the avcodec, avformat and avutil DLLs. Luckily, you can just get these from the installation directory of Google Chrome itself ($User/AppData/Local/Google/Chrome/$Version).

the options to enable proprietary codecs (i.e. H.264 and MP3) have been moved since the last answer.
you can read my answer with all the details on how to compile CEF with enabled proprietary codecs
the magic now happens here:
set GN_DEFINES=is_official_build=true proprietary_codecs=true ffmpeg_branding=Chrome
there is 2 batch files that you should update/create (as found here):
c:\code\chromium_git\update.bat:
set CEF_USE_GN=1
set GN_DEFINES=is_official_build=true proprietary_codecs=true ffmpeg_branding=Chrome
set GN_ARGUMENTS=--ide=vs2015 --sln=cef --filters=//cef/*
python ..\automate\automate-git.py --download-dir=C:\code\chromium_git --depot-tools-dir=C:\code\depot_tools --no-distrib --no-build
c:\code\chromium_git\chromium\src\cef\create.bat:
set CEF_USE_GN=1
set GN_DEFINES=is_win_fastlink=true proprietary_codecs=true ffmpeg_branding=Chrome
set GN_ARGUMENTS=--ide=vs2015 --sln=cef --filters=//cef/*
call cef_create_projects.bat
There is 2 wiki articles that explain how to build CEF/Chromium:
https://bitbucket.org/chromiumembedded/cef/wiki/MasterBuildQuickStart.md
and BranchesAndBuilding in the same wiki

MP3 codec only be supported When build to Google Chrome, check chromium's Codec Support.
On client side, the compatible way may be Flash, check google translate's code.

I followed the steps in null1941's answer and they worked great save a few caveats having to do with modifying the build.ps1 script
step 16 e. search for any instances of 3.y.z and replace them with the current version you are building (from the folder name containing the builds ex. 3.2272.32.gbda8dc7).
in function DownloadNuget it is trying to see if you have nuget in a specific place and if it isn't there it tries to go get it. Problem is DownloadFile would fail if the save directory didn't already exist. so you can manualy create or add this to the function:
$Nuget_dir = Join-Path $env:LOCALAPPDATA .\nuget
if(-not (Test-Path $Nuget_dir))
{
mkdir $Nuget_dir
}
change line: "Copy-Item $Cef64\include $CefInclude -Recurse | Out-Null" to use $Cef32 if you don't have 64bit cef folders

Related

I used uDraper plugins in source edition UE5,tips build through you IDE

I used Draper in Source Edition UE5(release version UE4.24 and UE5.0.3 works correctly ), operated 1,2, and 3 according to ReadMe in the installation path, and also replaced BuildId. However, when I opened the project tips : build through you IDE
I get an error when I don't follow the README:
enter image description here
ReadMe Info:
uDraper plugin is distributed in a binary form (without source code).
There where some undocumented but well known ways to achieve this without breaking the build of C++ projects in UE4.
But in UE5 it seems not to be the case anymore (there are plenty of complaints about this issue on the Internet).
At this point we can suggest a somwhat hacky way to make your C++ projects work properly in the presence of uDraper plugin:
Copy UnrealBuildTool.DraperHook.* files into [UE5 Root]\Engine\Binaries\DotNET\UnrealBuildTool
Replace "UnrealBuildTool.exe" with "UnrealBuildTool.DraperHook.dll" in [UE5 Root]\Engine\Build\BatchFiles\Build.bat
replace "UnrealBuildTool.exe" with "UnrealBuildTool.DraperHook.exe" in [UE5 Root]\Engine\Config\BaseEngine.ini ("UnrealBuildTool" value under "PlatformPaths" section)
It's still a work in progress so we hope to find a better solution in the future.
Regarding custom Engine builds we expect that the binary distribution of the uDraper plugin should be compatible as long as ABI didn't change.
Just replace "BuildId" in Draper\Binaries\Win64\UnrealEditor.modules to your "CompatibleChangelist" from [UE5 Root]\Engine\Build\Build.version
step 1:
enter image description here
step 2: The original file says "UnrealBuildTool.dll" not "UnrealBuildTool.exe"
enter image description here
step 3:
enter image description here
The above modification is still the error of FIG. 1
step 4:
enter image description here
open project
enter image description here
I opened the project with VS and compiled it successfully, and opened it again with the same erro.Previously, the plug-in was placed in the project path to open the project promptFailed to generate Projiect files,
We try to keep uDraper plugin up to date with official UE releases and do not attempt to support custom builds from GitHub.
The instructions you're referring to might be helpful but we do not guarantee that it will work with any GitHub version.
You can try to find an earlier UE version on GitHub to better match an officially released version and try it out.

Windows Embedded Compact webservices.dll

On http://developer.toradex.com/software-resources/arm-family/windows-ce/tegra/release-details?view=release-roadmap&issue=10304 it is stated that one should "Copy webservices.dll manually to the target folder \Flashdisk\System\" in order to fix a problem with Ethernet debugging. My problem is that I have no idea where I should copy the file from. Any ideas?
This is for WEC2013.
The file is located in your platform builder path if you build your own CE image:
C:\WINCE800\public\COMMON\oak\target\ARMV7\retail\webservices.dll
If you use a Toradex Prebuilt image, get in contact with the support team, they will probably send the driver to you: https://www.toradex.com/support/support.

How to create the NLS.LC.CTYPE

How do one create the NLS.LC.CTYPE file on Universe on Unix AIX? I searched the BasicRef and BasicExt but don't see any documentation on this.
The NLS.LC.CTYPE file is part of NLS (National Language Support) package in UniVerse. You will need to install NLS as well as turn it on if you want to run in NLS mode.
The manual you are looking for is:
Rocket UniVerse NLS Guide
Note that there is no need to create the file if you are not using NLS.
Here is a link to the manual: http://docs.rocketsoftware.com/nxt/gateway.dll/RKBnew20/universe/11.2.3/nls.pdf

Reading Django documentation with restview

I am using Fedora 18 on Virtual Box on my Windows XP desktop to learn Django. After going through the .txt documentation files, I discovered these files were written using restructuredText. I've been spending the last day or so trying to figure out how to convert the files into something readable (HTML, Latex, PDF, etc.). First thing I did, was install docutils (from source - download page) and used rst2html.py to convert the files to HTML to be readable.
When I used this tool, I was getting the Unknown interpreted text role "doc", Unknown interpreted text role "ref", Unknown interpreted text role "term" errors, and more when opening the docs/intro/index.txt, docs/intro/install.txt and docs/intro/tutorial01.txt files. I was able to find very little on Google describing the exact problem I was having so I tried to use a different option.
Naively thinking the errors were native to docutils I decided to search for another tool and found this page and installed restview. Well, I didn't realize restview used docutils so I ended up back at square one.
How do I get rid of these and other errors? Did I install docutils and restview correctly?
Please tell me if I need to add more info
You need to use Sphinx. This tool is used by the Django project and it defines additional reStructuredText constructs to complement those defined by docutils. Such as
http://sphinx-doc.org/markup/inline.html#role-doc
http://sphinx-doc.org/markup/inline.html#role-ref
http://sphinx-doc.org/markup/inline.html#role-term

Issues with build in Carbide C++ 2.0

I'm building my application and when I try to run it on the emulator, I get this error.
Creation Time Description Resource Path Location Type
1254339868582 BLDMAKE ERROR: Directory "\S60\devices\Nokia_N97_SDK_v1.0\epoc32\" does not exist ZeFirst Unknown C/C++ Problem
The folder does exist and does have the necessary rights.
The console has the following set of warning messages
warning: "C:\S60\devices\Nokia_N97_SDK_v1.0\epoc32\tools\GCCEV6.bsf" Invalid BSF specification - customization restricted to ARMV5, ABIv2 and valid BSF platforms
warning: "C:\S60\devices\Nokia_N97_SDK_v1.0\epoc32\tools\GCCEV6T2.bsf" Invalid BSF specification - customization restricted to ARMV5, ABIv2 and valid BSF platforms
warning: "C:\S60\devices\Nokia_N97_SDK_v1.0\epoc32\tools\GCCEV7A.bsf" Invalid BSF specification - customization restricted to ARMV5, ABIv2 and valid BSF platforms
What other development tools do you have installed on your computer?
Is there a chance your path environment variable is in the wrong order and you're not using the correct version of the compiler, for example?
Feel free to post your path, it can only provide more information.
I'm not sure if this will work, but try this:
Subst a drive to C:\S60\devices\Nokia_N97_SDK_v1.0\
Start, Run...
subst x: C:\S60\devices\Nokia_N97_SDK_v1.0\
Then in carbide, set your SDK to point to this subst location.
Window, Preferences, Carbide C++, SDK ..
Change the paths to use "x:\" rather than C:\...
Delete any imported projects in Carbide
Select project, right-click, delete.
(Do NOT click the tick box that is displayed).
Re-import your project
File, Import, x:\.....\bld.inf
I have faced a similar problem once.
If you have been able to build and launch the eumlator on earlier occasions, then the only solution that worked for me was to re-install the SDK.
Techeretic,
make sure that your workspace is located in the same driver partition (C:) of your Symbian SDK installation. If don't try changing it.
Sometimes I solved that problem by changing .pkg file's content to use a relative path. For example:
;Files to install
;You should change the source paths to match that of your environment
;<source> <destination>
"$(EPOCROOT)Epoc32\release\$(PLATFORM)\$(TARGET)\MyApp.exe" -"!:\sys\bin\MyApp.exe"
"$(EPOCROOT)Epoc32\data\z\resource\apps\MyApp.r01" -"!:\resource\apps\MyApp.r01"
"$(EPOCROOT)Epoc32\data\z\private\10003a3f\apps\MyApp_reg.r01" -"!:\private\10003a3f\import\apps\MyApp_reg.r01"
"$(EPOCROOT)epoc32\data\z\resource\apps\MyApp_aif.mif" -"!:\resource\apps\MyApp_aif.mif"
"$(EPOCROOT)epoc32\data\z\resource\apps\MyApp.mbm" -"!:\resource\apps\MyApp.mbm"
Hope it helps.