From 11492532e248c00c60600a58e3ddd47d658c39b5 Mon Sep 17 00:00:00 2001 From: everything411 Date: Mon, 12 Aug 2024 23:44:06 +0800 Subject: [PATCH] first commit --- .gitignore | 398 ++++++++++++++ LICENSE | 674 +++++++++++++++++++++++ README.md | 7 + VMAudioBackHook.sln | 30 ++ VMAudioBackHook.vcxproj | 111 ++++ VMAudioBackHook.vcxproj.filters | 38 ++ dllmain.cpp | 707 ++++++++++++++++++++++++ framework.h | 4 + pch.cpp | 5 + pch.h | 13 + winmm_jump.asm | 927 ++++++++++++++++++++++++++++++++ 11 files changed, 2914 insertions(+) create mode 100644 .gitignore create mode 100644 LICENSE create mode 100644 README.md create mode 100644 VMAudioBackHook.sln create mode 100644 VMAudioBackHook.vcxproj create mode 100644 VMAudioBackHook.vcxproj.filters create mode 100644 dllmain.cpp create mode 100644 framework.h create mode 100644 pch.cpp create mode 100644 pch.h create mode 100644 winmm_jump.asm diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..8dd4607 --- /dev/null +++ b/.gitignore @@ -0,0 +1,398 @@ +## Ignore Visual Studio temporary files, build results, and +## files generated by popular Visual Studio add-ons. +## +## Get latest from https://github.com/github/gitignore/blob/main/VisualStudio.gitignore + +# User-specific files +*.rsuser +*.suo +*.user +*.userosscache +*.sln.docstates + +# User-specific files (MonoDevelop/Xamarin Studio) +*.userprefs + +# Mono auto generated files +mono_crash.* + +# Build results +[Dd]ebug/ +[Dd]ebugPublic/ +[Rr]elease/ +[Rr]eleases/ +x64/ +x86/ +[Ww][Ii][Nn]32/ +[Aa][Rr][Mm]/ +[Aa][Rr][Mm]64/ +bld/ +[Bb]in/ +[Oo]bj/ +[Ll]og/ +[Ll]ogs/ + +# Visual Studio 2015/2017 cache/options directory +.vs/ +# Uncomment if you have tasks that create the project's static files in wwwroot +#wwwroot/ + +# Visual Studio 2017 auto generated files +Generated\ Files/ + +# MSTest test Results +[Tt]est[Rr]esult*/ +[Bb]uild[Ll]og.* + +# NUnit +*.VisualState.xml +TestResult.xml +nunit-*.xml + +# Build Results of an ATL Project +[Dd]ebugPS/ +[Rr]eleasePS/ +dlldata.c + +# Benchmark Results +BenchmarkDotNet.Artifacts/ + +# .NET Core +project.lock.json +project.fragment.lock.json +artifacts/ + +# ASP.NET Scaffolding +ScaffoldingReadMe.txt + +# StyleCop +StyleCopReport.xml + +# Files built by Visual Studio +*_i.c +*_p.c +*_h.h +*.ilk +*.meta +*.obj +*.iobj +*.pch +*.pdb +*.ipdb +*.pgc +*.pgd +*.rsp +*.sbr +*.tlb +*.tli +*.tlh +*.tmp +*.tmp_proj +*_wpftmp.csproj +*.log +*.tlog +*.vspscc +*.vssscc +.builds +*.pidb +*.svclog +*.scc + +# Chutzpah Test files +_Chutzpah* + +# Visual C++ cache files +ipch/ +*.aps +*.ncb +*.opendb +*.opensdf +*.sdf +*.cachefile +*.VC.db +*.VC.VC.opendb + +# Visual Studio profiler +*.psess +*.vsp +*.vspx +*.sap + +# Visual Studio Trace Files +*.e2e + +# TFS 2012 Local Workspace +$tf/ + +# Guidance Automation Toolkit +*.gpState + +# ReSharper is a .NET coding add-in +_ReSharper*/ +*.[Rr]e[Ss]harper +*.DotSettings.user + +# TeamCity is a build add-in +_TeamCity* + +# DotCover is a Code Coverage Tool +*.dotCover + +# AxoCover is a Code Coverage Tool +.axoCover/* +!.axoCover/settings.json + +# Coverlet is a free, cross platform Code Coverage Tool +coverage*.json +coverage*.xml +coverage*.info + +# Visual Studio code coverage results +*.coverage +*.coveragexml + +# NCrunch +_NCrunch_* +.*crunch*.local.xml +nCrunchTemp_* + +# MightyMoose +*.mm.* +AutoTest.Net/ + +# Web workbench (sass) +.sass-cache/ + +# Installshield output folder +[Ee]xpress/ + +# DocProject is a documentation generator add-in +DocProject/buildhelp/ +DocProject/Help/*.HxT +DocProject/Help/*.HxC +DocProject/Help/*.hhc +DocProject/Help/*.hhk +DocProject/Help/*.hhp +DocProject/Help/Html2 +DocProject/Help/html + +# Click-Once directory +publish/ + +# Publish Web Output +*.[Pp]ublish.xml +*.azurePubxml +# Note: Comment the next line if you want to checkin your web deploy settings, +# but database connection strings (with potential passwords) will be unencrypted +*.pubxml +*.publishproj + +# Microsoft Azure Web App publish settings. Comment the next line if you want to +# checkin your Azure Web App publish settings, but sensitive information contained +# in these scripts will be unencrypted +PublishScripts/ + +# NuGet Packages +*.nupkg +# NuGet Symbol Packages +*.snupkg +# The packages folder can be ignored because of Package Restore +**/[Pp]ackages/* +# except build/, which is used as an MSBuild target. +!**/[Pp]ackages/build/ +# Uncomment if necessary however generally it will be regenerated when needed +#!**/[Pp]ackages/repositories.config +# NuGet v3's project.json files produces more ignorable files +*.nuget.props +*.nuget.targets + +# Microsoft Azure Build Output +csx/ +*.build.csdef + +# Microsoft Azure Emulator +ecf/ +rcf/ + +# Windows Store app package directories and files +AppPackages/ +BundleArtifacts/ +Package.StoreAssociation.xml +_pkginfo.txt +*.appx +*.appxbundle +*.appxupload + +# Visual Studio cache files +# files ending in .cache can be ignored +*.[Cc]ache +# but keep track of directories ending in .cache +!?*.[Cc]ache/ + +# Others +ClientBin/ +~$* +*~ +*.dbmdl +*.dbproj.schemaview +*.jfm +*.pfx +*.publishsettings +orleans.codegen.cs + +# Including strong name files can present a security risk +# (https://github.com/github/gitignore/pull/2483#issue-259490424) +#*.snk + +# Since there are multiple workflows, uncomment next line to ignore bower_components +# (https://github.com/github/gitignore/pull/1529#issuecomment-104372622) +#bower_components/ + +# RIA/Silverlight projects +Generated_Code/ + +# Backup & report files from converting an old project file +# to a newer Visual Studio version. Backup files are not needed, +# because we have git ;-) +_UpgradeReport_Files/ +Backup*/ +UpgradeLog*.XML +UpgradeLog*.htm +ServiceFabricBackup/ +*.rptproj.bak + +# SQL Server files +*.mdf +*.ldf +*.ndf + +# Business Intelligence projects +*.rdl.data +*.bim.layout +*.bim_*.settings +*.rptproj.rsuser +*- [Bb]ackup.rdl +*- [Bb]ackup ([0-9]).rdl +*- [Bb]ackup ([0-9][0-9]).rdl + +# Microsoft Fakes +FakesAssemblies/ + +# GhostDoc plugin setting file +*.GhostDoc.xml + +# Node.js Tools for Visual Studio +.ntvs_analysis.dat +node_modules/ + +# Visual Studio 6 build log +*.plg + +# Visual Studio 6 workspace options file +*.opt + +# Visual Studio 6 auto-generated workspace file (contains which files were open etc.) +*.vbw + +# Visual Studio 6 auto-generated project file (contains which files were open etc.) +*.vbp + +# Visual Studio 6 workspace and project file (working project files containing files to include in project) +*.dsw +*.dsp + +# Visual Studio 6 technical files +*.ncb +*.aps + +# Visual Studio LightSwitch build output +**/*.HTMLClient/GeneratedArtifacts +**/*.DesktopClient/GeneratedArtifacts +**/*.DesktopClient/ModelManifest.xml +**/*.Server/GeneratedArtifacts +**/*.Server/ModelManifest.xml +_Pvt_Extensions + +# Paket dependency manager +.paket/paket.exe +paket-files/ + +# FAKE - F# Make +.fake/ + +# CodeRush personal settings +.cr/personal + +# Python Tools for Visual Studio (PTVS) +__pycache__/ +*.pyc + +# Cake - Uncomment if you are using it +# tools/** +# !tools/packages.config + +# Tabs Studio +*.tss + +# Telerik's JustMock configuration file +*.jmconfig + +# BizTalk build output +*.btp.cs +*.btm.cs +*.odx.cs +*.xsd.cs + +# OpenCover UI analysis results +OpenCover/ + +# Azure Stream Analytics local run output +ASALocalRun/ + +# MSBuild Binary and Structured Log +*.binlog + +# NVidia Nsight GPU debugger configuration file +*.nvuser + +# MFractors (Xamarin productivity tool) working folder +.mfractor/ + +# Local History for Visual Studio +.localhistory/ + +# Visual Studio History (VSHistory) files +.vshistory/ + +# BeatPulse healthcheck temp database +healthchecksdb + +# Backup folder for Package Reference Convert tool in Visual Studio 2017 +MigrationBackup/ + +# Ionide (cross platform F# VS Code tools) working folder +.ionide/ + +# Fody - auto-generated XML schema +FodyWeavers.xsd + +# VS Code files for those working on multiple tools +.vscode/* +!.vscode/settings.json +!.vscode/tasks.json +!.vscode/launch.json +!.vscode/extensions.json +*.code-workspace + +# Local History for Visual Studio Code +.history/ + +# Windows Installer files from build outputs +*.cab +*.msi +*.msix +*.msm +*.msp + +# JetBrains Rider +*.sln.iml \ No newline at end of file diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..e72bfdd --- /dev/null +++ b/LICENSE @@ -0,0 +1,674 @@ + GNU GENERAL PUBLIC LICENSE + Version 3, 29 June 2007 + + Copyright (C) 2007 Free Software Foundation, Inc. + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. + + Preamble + + The GNU General Public License is a free, copyleft license for +software and other kinds of works. + + The licenses for most software and other practical works are designed +to take away your freedom to share and change the works. By contrast, +the GNU General Public License is intended to guarantee your freedom to +share and change all versions of a program--to make sure it remains free +software for all its users. We, the Free Software Foundation, use the +GNU General Public License for most of our software; it applies also to +any other work released this way by its authors. You can apply it to +your programs, too. + + When we speak of free software, we are referring to freedom, not +price. Our General Public Licenses are designed to make sure that you +have the freedom to distribute copies of free software (and charge for +them if you wish), that you receive source code or can get it if you +want it, that you can change the software or use pieces of it in new +free programs, and that you know you can do these things. + + To protect your rights, we need to prevent others from denying you +these rights or asking you to surrender the rights. Therefore, you have +certain responsibilities if you distribute copies of the software, or if +you modify it: responsibilities to respect the freedom of others. + + For example, if you distribute copies of such a program, whether +gratis or for a fee, you must pass on to the recipients the same +freedoms that you received. You must make sure that they, too, receive +or can get the source code. And you must show them these terms so they +know their rights. + + Developers that use the GNU GPL protect your rights with two steps: +(1) assert copyright on the software, and (2) offer you this License +giving you legal permission to copy, distribute and/or modify it. + + For the developers' and authors' protection, the GPL clearly explains +that there is no warranty for this free software. For both users' and +authors' sake, the GPL requires that modified versions be marked as +changed, so that their problems will not be attributed erroneously to +authors of previous versions. + + Some devices are designed to deny users access to install or run +modified versions of the software inside them, although the manufacturer +can do so. This is fundamentally incompatible with the aim of +protecting users' freedom to change the software. The systematic +pattern of such abuse occurs in the area of products for individuals to +use, which is precisely where it is most unacceptable. Therefore, we +have designed this version of the GPL to prohibit the practice for those +products. If such problems arise substantially in other domains, we +stand ready to extend this provision to those domains in future versions +of the GPL, as needed to protect the freedom of users. + + Finally, every program is threatened constantly by software patents. +States should not allow patents to restrict development and use of +software on general-purpose computers, but in those that do, we wish to +avoid the special danger that patents applied to a free program could +make it effectively proprietary. To prevent this, the GPL assures that +patents cannot be used to render the program non-free. + + The precise terms and conditions for copying, distribution and +modification follow. + + TERMS AND CONDITIONS + + 0. Definitions. + + "This License" refers to version 3 of the GNU General Public License. + + "Copyright" also means copyright-like laws that apply to other kinds of +works, such as semiconductor masks. + + "The Program" refers to any copyrightable work licensed under this +License. Each licensee is addressed as "you". "Licensees" and +"recipients" may be individuals or organizations. + + To "modify" a work means to copy from or adapt all or part of the work +in a fashion requiring copyright permission, other than the making of an +exact copy. The resulting work is called a "modified version" of the +earlier work or a work "based on" the earlier work. + + A "covered work" means either the unmodified Program or a work based +on the Program. + + To "propagate" a work means to do anything with it that, without +permission, would make you directly or secondarily liable for +infringement under applicable copyright law, except executing it on a +computer or modifying a private copy. Propagation includes copying, +distribution (with or without modification), making available to the +public, and in some countries other activities as well. + + To "convey" a work means any kind of propagation that enables other +parties to make or receive copies. Mere interaction with a user through +a computer network, with no transfer of a copy, is not conveying. + + An interactive user interface displays "Appropriate Legal Notices" +to the extent that it includes a convenient and prominently visible +feature that (1) displays an appropriate copyright notice, and (2) +tells the user that there is no warranty for the work (except to the +extent that warranties are provided), that licensees may convey the +work under this License, and how to view a copy of this License. If +the interface presents a list of user commands or options, such as a +menu, a prominent item in the list meets this criterion. + + 1. Source Code. + + The "source code" for a work means the preferred form of the work +for making modifications to it. "Object code" means any non-source +form of a work. + + A "Standard Interface" means an interface that either is an official +standard defined by a recognized standards body, or, in the case of +interfaces specified for a particular programming language, one that +is widely used among developers working in that language. + + The "System Libraries" of an executable work include anything, other +than the work as a whole, that (a) is included in the normal form of +packaging a Major Component, but which is not part of that Major +Component, and (b) serves only to enable use of the work with that +Major Component, or to implement a Standard Interface for which an +implementation is available to the public in source code form. A +"Major Component", in this context, means a major essential component +(kernel, window system, and so on) of the specific operating system +(if any) on which the executable work runs, or a compiler used to +produce the work, or an object code interpreter used to run it. + + The "Corresponding Source" for a work in object code form means all +the source code needed to generate, install, and (for an executable +work) run the object code and to modify the work, including scripts to +control those activities. However, it does not include the work's +System Libraries, or general-purpose tools or generally available free +programs which are used unmodified in performing those activities but +which are not part of the work. For example, Corresponding Source +includes interface definition files associated with source files for +the work, and the source code for shared libraries and dynamically +linked subprograms that the work is specifically designed to require, +such as by intimate data communication or control flow between those +subprograms and other parts of the work. + + The Corresponding Source need not include anything that users +can regenerate automatically from other parts of the Corresponding +Source. + + The Corresponding Source for a work in source code form is that +same work. + + 2. Basic Permissions. + + All rights granted under this License are granted for the term of +copyright on the Program, and are irrevocable provided the stated +conditions are met. This License explicitly affirms your unlimited +permission to run the unmodified Program. The output from running a +covered work is covered by this License only if the output, given its +content, constitutes a covered work. This License acknowledges your +rights of fair use or other equivalent, as provided by copyright law. + + You may make, run and propagate covered works that you do not +convey, without conditions so long as your license otherwise remains +in force. You may convey covered works to others for the sole purpose +of having them make modifications exclusively for you, or provide you +with facilities for running those works, provided that you comply with +the terms of this License in conveying all material for which you do +not control copyright. Those thus making or running the covered works +for you must do so exclusively on your behalf, under your direction +and control, on terms that prohibit them from making any copies of +your copyrighted material outside their relationship with you. + + Conveying under any other circumstances is permitted solely under +the conditions stated below. Sublicensing is not allowed; section 10 +makes it unnecessary. + + 3. Protecting Users' Legal Rights From Anti-Circumvention Law. + + No covered work shall be deemed part of an effective technological +measure under any applicable law fulfilling obligations under article +11 of the WIPO copyright treaty adopted on 20 December 1996, or +similar laws prohibiting or restricting circumvention of such +measures. + + When you convey a covered work, you waive any legal power to forbid +circumvention of technological measures to the extent such circumvention +is effected by exercising rights under this License with respect to +the covered work, and you disclaim any intention to limit operation or +modification of the work as a means of enforcing, against the work's +users, your or third parties' legal rights to forbid circumvention of +technological measures. + + 4. Conveying Verbatim Copies. + + You may convey verbatim copies of the Program's source code as you +receive it, in any medium, provided that you conspicuously and +appropriately publish on each copy an appropriate copyright notice; +keep intact all notices stating that this License and any +non-permissive terms added in accord with section 7 apply to the code; +keep intact all notices of the absence of any warranty; and give all +recipients a copy of this License along with the Program. + + You may charge any price or no price for each copy that you convey, +and you may offer support or warranty protection for a fee. + + 5. Conveying Modified Source Versions. + + You may convey a work based on the Program, or the modifications to +produce it from the Program, in the form of source code under the +terms of section 4, provided that you also meet all of these conditions: + + a) The work must carry prominent notices stating that you modified + it, and giving a relevant date. + + b) The work must carry prominent notices stating that it is + released under this License and any conditions added under section + 7. This requirement modifies the requirement in section 4 to + "keep intact all notices". + + c) You must license the entire work, as a whole, under this + License to anyone who comes into possession of a copy. This + License will therefore apply, along with any applicable section 7 + additional terms, to the whole of the work, and all its parts, + regardless of how they are packaged. This License gives no + permission to license the work in any other way, but it does not + invalidate such permission if you have separately received it. + + d) If the work has interactive user interfaces, each must display + Appropriate Legal Notices; however, if the Program has interactive + interfaces that do not display Appropriate Legal Notices, your + work need not make them do so. + + A compilation of a covered work with other separate and independent +works, which are not by their nature extensions of the covered work, +and which are not combined with it such as to form a larger program, +in or on a volume of a storage or distribution medium, is called an +"aggregate" if the compilation and its resulting copyright are not +used to limit the access or legal rights of the compilation's users +beyond what the individual works permit. Inclusion of a covered work +in an aggregate does not cause this License to apply to the other +parts of the aggregate. + + 6. Conveying Non-Source Forms. + + You may convey a covered work in object code form under the terms +of sections 4 and 5, provided that you also convey the +machine-readable Corresponding Source under the terms of this License, +in one of these ways: + + a) Convey the object code in, or embodied in, a physical product + (including a physical distribution medium), accompanied by the + Corresponding Source fixed on a durable physical medium + customarily used for software interchange. + + b) Convey the object code in, or embodied in, a physical product + (including a physical distribution medium), accompanied by a + written offer, valid for at least three years and valid for as + long as you offer spare parts or customer support for that product + model, to give anyone who possesses the object code either (1) a + copy of the Corresponding Source for all the software in the + product that is covered by this License, on a durable physical + medium customarily used for software interchange, for a price no + more than your reasonable cost of physically performing this + conveying of source, or (2) access to copy the + Corresponding Source from a network server at no charge. + + c) Convey individual copies of the object code with a copy of the + written offer to provide the Corresponding Source. This + alternative is allowed only occasionally and noncommercially, and + only if you received the object code with such an offer, in accord + with subsection 6b. + + d) Convey the object code by offering access from a designated + place (gratis or for a charge), and offer equivalent access to the + Corresponding Source in the same way through the same place at no + further charge. You need not require recipients to copy the + Corresponding Source along with the object code. If the place to + copy the object code is a network server, the Corresponding Source + may be on a different server (operated by you or a third party) + that supports equivalent copying facilities, provided you maintain + clear directions next to the object code saying where to find the + Corresponding Source. Regardless of what server hosts the + Corresponding Source, you remain obligated to ensure that it is + available for as long as needed to satisfy these requirements. + + e) Convey the object code using peer-to-peer transmission, provided + you inform other peers where the object code and Corresponding + Source of the work are being offered to the general public at no + charge under subsection 6d. + + A separable portion of the object code, whose source code is excluded +from the Corresponding Source as a System Library, need not be +included in conveying the object code work. + + A "User Product" is either (1) a "consumer product", which means any +tangible personal property which is normally used for personal, family, +or household purposes, or (2) anything designed or sold for incorporation +into a dwelling. In determining whether a product is a consumer product, +doubtful cases shall be resolved in favor of coverage. For a particular +product received by a particular user, "normally used" refers to a +typical or common use of that class of product, regardless of the status +of the particular user or of the way in which the particular user +actually uses, or expects or is expected to use, the product. A product +is a consumer product regardless of whether the product has substantial +commercial, industrial or non-consumer uses, unless such uses represent +the only significant mode of use of the product. + + "Installation Information" for a User Product means any methods, +procedures, authorization keys, or other information required to install +and execute modified versions of a covered work in that User Product from +a modified version of its Corresponding Source. The information must +suffice to ensure that the continued functioning of the modified object +code is in no case prevented or interfered with solely because +modification has been made. + + If you convey an object code work under this section in, or with, or +specifically for use in, a User Product, and the conveying occurs as +part of a transaction in which the right of possession and use of the +User Product is transferred to the recipient in perpetuity or for a +fixed term (regardless of how the transaction is characterized), the +Corresponding Source conveyed under this section must be accompanied +by the Installation Information. But this requirement does not apply +if neither you nor any third party retains the ability to install +modified object code on the User Product (for example, the work has +been installed in ROM). + + The requirement to provide Installation Information does not include a +requirement to continue to provide support service, warranty, or updates +for a work that has been modified or installed by the recipient, or for +the User Product in which it has been modified or installed. Access to a +network may be denied when the modification itself materially and +adversely affects the operation of the network or violates the rules and +protocols for communication across the network. + + Corresponding Source conveyed, and Installation Information provided, +in accord with this section must be in a format that is publicly +documented (and with an implementation available to the public in +source code form), and must require no special password or key for +unpacking, reading or copying. + + 7. Additional Terms. + + "Additional permissions" are terms that supplement the terms of this +License by making exceptions from one or more of its conditions. +Additional permissions that are applicable to the entire Program shall +be treated as though they were included in this License, to the extent +that they are valid under applicable law. If additional permissions +apply only to part of the Program, that part may be used separately +under those permissions, but the entire Program remains governed by +this License without regard to the additional permissions. + + When you convey a copy of a covered work, you may at your option +remove any additional permissions from that copy, or from any part of +it. (Additional permissions may be written to require their own +removal in certain cases when you modify the work.) You may place +additional permissions on material, added by you to a covered work, +for which you have or can give appropriate copyright permission. + + Notwithstanding any other provision of this License, for material you +add to a covered work, you may (if authorized by the copyright holders of +that material) supplement the terms of this License with terms: + + a) Disclaiming warranty or limiting liability differently from the + terms of sections 15 and 16 of this License; or + + b) Requiring preservation of specified reasonable legal notices or + author attributions in that material or in the Appropriate Legal + Notices displayed by works containing it; or + + c) Prohibiting misrepresentation of the origin of that material, or + requiring that modified versions of such material be marked in + reasonable ways as different from the original version; or + + d) Limiting the use for publicity purposes of names of licensors or + authors of the material; or + + e) Declining to grant rights under trademark law for use of some + trade names, trademarks, or service marks; or + + f) Requiring indemnification of licensors and authors of that + material by anyone who conveys the material (or modified versions of + it) with contractual assumptions of liability to the recipient, for + any liability that these contractual assumptions directly impose on + those licensors and authors. + + All other non-permissive additional terms are considered "further +restrictions" within the meaning of section 10. If the Program as you +received it, or any part of it, contains a notice stating that it is +governed by this License along with a term that is a further +restriction, you may remove that term. If a license document contains +a further restriction but permits relicensing or conveying under this +License, you may add to a covered work material governed by the terms +of that license document, provided that the further restriction does +not survive such relicensing or conveying. + + If you add terms to a covered work in accord with this section, you +must place, in the relevant source files, a statement of the +additional terms that apply to those files, or a notice indicating +where to find the applicable terms. + + Additional terms, permissive or non-permissive, may be stated in the +form of a separately written license, or stated as exceptions; +the above requirements apply either way. + + 8. Termination. + + You may not propagate or modify a covered work except as expressly +provided under this License. Any attempt otherwise to propagate or +modify it is void, and will automatically terminate your rights under +this License (including any patent licenses granted under the third +paragraph of section 11). + + However, if you cease all violation of this License, then your +license from a particular copyright holder is reinstated (a) +provisionally, unless and until the copyright holder explicitly and +finally terminates your license, and (b) permanently, if the copyright +holder fails to notify you of the violation by some reasonable means +prior to 60 days after the cessation. + + Moreover, your license from a particular copyright holder is +reinstated permanently if the copyright holder notifies you of the +violation by some reasonable means, this is the first time you have +received notice of violation of this License (for any work) from that +copyright holder, and you cure the violation prior to 30 days after +your receipt of the notice. + + Termination of your rights under this section does not terminate the +licenses of parties who have received copies or rights from you under +this License. If your rights have been terminated and not permanently +reinstated, you do not qualify to receive new licenses for the same +material under section 10. + + 9. Acceptance Not Required for Having Copies. + + You are not required to accept this License in order to receive or +run a copy of the Program. Ancillary propagation of a covered work +occurring solely as a consequence of using peer-to-peer transmission +to receive a copy likewise does not require acceptance. However, +nothing other than this License grants you permission to propagate or +modify any covered work. These actions infringe copyright if you do +not accept this License. Therefore, by modifying or propagating a +covered work, you indicate your acceptance of this License to do so. + + 10. Automatic Licensing of Downstream Recipients. + + Each time you convey a covered work, the recipient automatically +receives a license from the original licensors, to run, modify and +propagate that work, subject to this License. You are not responsible +for enforcing compliance by third parties with this License. + + An "entity transaction" is a transaction transferring control of an +organization, or substantially all assets of one, or subdividing an +organization, or merging organizations. If propagation of a covered +work results from an entity transaction, each party to that +transaction who receives a copy of the work also receives whatever +licenses to the work the party's predecessor in interest had or could +give under the previous paragraph, plus a right to possession of the +Corresponding Source of the work from the predecessor in interest, if +the predecessor has it or can get it with reasonable efforts. + + You may not impose any further restrictions on the exercise of the +rights granted or affirmed under this License. For example, you may +not impose a license fee, royalty, or other charge for exercise of +rights granted under this License, and you may not initiate litigation +(including a cross-claim or counterclaim in a lawsuit) alleging that +any patent claim is infringed by making, using, selling, offering for +sale, or importing the Program or any portion of it. + + 11. Patents. + + A "contributor" is a copyright holder who authorizes use under this +License of the Program or a work on which the Program is based. The +work thus licensed is called the contributor's "contributor version". + + A contributor's "essential patent claims" are all patent claims +owned or controlled by the contributor, whether already acquired or +hereafter acquired, that would be infringed by some manner, permitted +by this License, of making, using, or selling its contributor version, +but do not include claims that would be infringed only as a +consequence of further modification of the contributor version. For +purposes of this definition, "control" includes the right to grant +patent sublicenses in a manner consistent with the requirements of +this License. + + Each contributor grants you a non-exclusive, worldwide, royalty-free +patent license under the contributor's essential patent claims, to +make, use, sell, offer for sale, import and otherwise run, modify and +propagate the contents of its contributor version. + + In the following three paragraphs, a "patent license" is any express +agreement or commitment, however denominated, not to enforce a patent +(such as an express permission to practice a patent or covenant not to +sue for patent infringement). To "grant" such a patent license to a +party means to make such an agreement or commitment not to enforce a +patent against the party. + + If you convey a covered work, knowingly relying on a patent license, +and the Corresponding Source of the work is not available for anyone +to copy, free of charge and under the terms of this License, through a +publicly available network server or other readily accessible means, +then you must either (1) cause the Corresponding Source to be so +available, or (2) arrange to deprive yourself of the benefit of the +patent license for this particular work, or (3) arrange, in a manner +consistent with the requirements of this License, to extend the patent +license to downstream recipients. "Knowingly relying" means you have +actual knowledge that, but for the patent license, your conveying the +covered work in a country, or your recipient's use of the covered work +in a country, would infringe one or more identifiable patents in that +country that you have reason to believe are valid. + + If, pursuant to or in connection with a single transaction or +arrangement, you convey, or propagate by procuring conveyance of, a +covered work, and grant a patent license to some of the parties +receiving the covered work authorizing them to use, propagate, modify +or convey a specific copy of the covered work, then the patent license +you grant is automatically extended to all recipients of the covered +work and works based on it. + + A patent license is "discriminatory" if it does not include within +the scope of its coverage, prohibits the exercise of, or is +conditioned on the non-exercise of one or more of the rights that are +specifically granted under this License. You may not convey a covered +work if you are a party to an arrangement with a third party that is +in the business of distributing software, under which you make payment +to the third party based on the extent of your activity of conveying +the work, and under which the third party grants, to any of the +parties who would receive the covered work from you, a discriminatory +patent license (a) in connection with copies of the covered work +conveyed by you (or copies made from those copies), or (b) primarily +for and in connection with specific products or compilations that +contain the covered work, unless you entered into that arrangement, +or that patent license was granted, prior to 28 March 2007. + + Nothing in this License shall be construed as excluding or limiting +any implied license or other defenses to infringement that may +otherwise be available to you under applicable patent law. + + 12. No Surrender of Others' Freedom. + + If conditions are imposed on you (whether by court order, agreement or +otherwise) that contradict the conditions of this License, they do not +excuse you from the conditions of this License. If you cannot convey a +covered work so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you may +not convey it at all. For example, if you agree to terms that obligate you +to collect a royalty for further conveying from those to whom you convey +the Program, the only way you could satisfy both those terms and this +License would be to refrain entirely from conveying the Program. + + 13. Use with the GNU Affero General Public License. + + Notwithstanding any other provision of this License, you have +permission to link or combine any covered work with a work licensed +under version 3 of the GNU Affero General Public License into a single +combined work, and to convey the resulting work. The terms of this +License will continue to apply to the part which is the covered work, +but the special requirements of the GNU Affero General Public License, +section 13, concerning interaction through a network will apply to the +combination as such. + + 14. Revised Versions of this License. + + The Free Software Foundation may publish revised and/or new versions of +the GNU General Public License from time to time. Such new versions will +be similar in spirit to the present version, but may differ in detail to +address new problems or concerns. + + Each version is given a distinguishing version number. If the +Program specifies that a certain numbered version of the GNU General +Public License "or any later version" applies to it, you have the +option of following the terms and conditions either of that numbered +version or of any later version published by the Free Software +Foundation. If the Program does not specify a version number of the +GNU General Public License, you may choose any version ever published +by the Free Software Foundation. + + If the Program specifies that a proxy can decide which future +versions of the GNU General Public License can be used, that proxy's +public statement of acceptance of a version permanently authorizes you +to choose that version for the Program. + + Later license versions may give you additional or different +permissions. However, no additional obligations are imposed on any +author or copyright holder as a result of your choosing to follow a +later version. + + 15. Disclaimer of Warranty. + + THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY +APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT +HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY +OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, +THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR +PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM +IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF +ALL NECESSARY SERVICING, REPAIR OR CORRECTION. + + 16. Limitation of Liability. + + IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING +WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS +THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY +GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE +USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF +DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD +PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), +EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF +SUCH DAMAGES. + + 17. Interpretation of Sections 15 and 16. + + If the disclaimer of warranty and limitation of liability provided +above cannot be given local legal effect according to their terms, +reviewing courts shall apply local law that most closely approximates +an absolute waiver of all civil liability in connection with the +Program, unless a warranty or assumption of liability accompanies a +copy of the Program in return for a fee. + + END OF TERMS AND CONDITIONS + + How to Apply These Terms to Your New Programs + + If you develop a new program, and you want it to be of the greatest +possible use to the public, the best way to achieve this is to make it +free software which everyone can redistribute and change under these terms. + + To do so, attach the following notices to the program. It is safest +to attach them to the start of each source file to most effectively +state the exclusion of warranty; and each file should have at least +the "copyright" line and a pointer to where the full notice is found. + + + Copyright (C) + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see . + +Also add information on how to contact you by electronic and paper mail. + + If the program does terminal interaction, make it output a short +notice like this when it starts in an interactive mode: + + Copyright (C) + This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. + This is free software, and you are welcome to redistribute it + under certain conditions; type `show c' for details. + +The hypothetical commands `show w' and `show c' should show the appropriate +parts of the General Public License. Of course, your program's commands +might be different; for a GUI interface, you would use an "about box". + + You should also get your employer (if you work as a programmer) or school, +if any, to sign a "copyright disclaimer" for the program, if necessary. +For more information on this, and how to apply and follow the GNU GPL, see +. + + The GNU General Public License does not permit incorporating your program +into proprietary programs. If your program is a subroutine library, you +may consider it more useful to permit linking proprietary applications with +the library. If this is what you want to do, use the GNU Lesser General +Public License instead of this License. But first, please read +. \ No newline at end of file diff --git a/README.md b/README.md new file mode 100644 index 0000000..4c99c6c --- /dev/null +++ b/README.md @@ -0,0 +1,7 @@ +# VMAudioBackHook +DLL hijack version of VMAudioBackHost. +## Usage +goto Release page and download `winmm.dll`, place it under the same folder as `vmware-vmx.exe`, normally the default is `C:\Program Files (x86)\VMware\VMware Workstation\x64`, and enjoy! +## Credits +[VMAudioBackHost](https://github.com/Raymai97/VMAudioBackHost) +[AheadLib-x86-x64](https://github.com/strivexjun/AheadLib-x86-x64) diff --git a/VMAudioBackHook.sln b/VMAudioBackHook.sln new file mode 100644 index 0000000..63aef9f --- /dev/null +++ b/VMAudioBackHook.sln @@ -0,0 +1,30 @@ + +Microsoft Visual Studio Solution File, Format Version 12.00 +# Visual Studio Version 17 +VisualStudioVersion = 17.9.34728.123 +MinimumVisualStudioVersion = 10.0.40219.1 +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "VMAudioBackHook", "VMAudioBackHook.vcxproj", "{7B9D7430-E9D4-4240-811F-37F89A9A90EF}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|x64 = Debug|x64 + Debug|x86 = Debug|x86 + Release|x64 = Release|x64 + Release|x86 = Release|x86 + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {7B9D7430-E9D4-4240-811F-37F89A9A90EF}.Debug|x64.ActiveCfg = Debug|x64 + {7B9D7430-E9D4-4240-811F-37F89A9A90EF}.Debug|x64.Build.0 = Debug|x64 + {7B9D7430-E9D4-4240-811F-37F89A9A90EF}.Debug|x86.ActiveCfg = Debug|x64 + {7B9D7430-E9D4-4240-811F-37F89A9A90EF}.Debug|x86.Build.0 = Debug|x64 + {7B9D7430-E9D4-4240-811F-37F89A9A90EF}.Release|x64.ActiveCfg = Release|x64 + {7B9D7430-E9D4-4240-811F-37F89A9A90EF}.Release|x64.Build.0 = Release|x64 + {7B9D7430-E9D4-4240-811F-37F89A9A90EF}.Release|x86.ActiveCfg = Release|x64 + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection + GlobalSection(ExtensibilityGlobals) = postSolution + SolutionGuid = {A0001CCC-DAE2-4DCD-ADD0-46860A19CAAF} + EndGlobalSection +EndGlobal diff --git a/VMAudioBackHook.vcxproj b/VMAudioBackHook.vcxproj new file mode 100644 index 0000000..85c50f4 --- /dev/null +++ b/VMAudioBackHook.vcxproj @@ -0,0 +1,111 @@ + + + + + Debug + x64 + + + Release + x64 + + + + 17.0 + Win32Proj + {7b9d7430-e9d4-4240-811f-37f89a9a90ef} + VMAudioBackHook + 10.0 + + + + DynamicLibrary + true + v143 + Unicode + + + DynamicLibrary + false + v143 + true + Unicode + + + + + + + + + + + + + + + winmm + + + winmm + + + + Level3 + true + _DEBUG;VMAUDIOBACKHOOK_EXPORTS;_WINDOWS;_USRDLL;%(PreprocessorDefinitions) + true + Use + pch.h + + + Windows + true + false + + + + + Level3 + true + true + true + NDEBUG;VMAUDIOBACKHOOK_EXPORTS;_WINDOWS;_USRDLL;%(PreprocessorDefinitions) + true + Use + pch.h + + + Windows + true + true + true + false + + + + + + + + + + Create + Create + + + + + false + false + Document + ml64 /Fo $(IntDir)%(fileName).obj /c /Cp %(fileName).asm + ml64 /Fo $(IntDir)%(fileName).obj /c /Cp %(fileName).asm + $(IntDir)%(fileName).obj;%(Outputs) + $(IntDir)%(fileName).obj;%(Outputs) + + + + + + \ No newline at end of file diff --git a/VMAudioBackHook.vcxproj.filters b/VMAudioBackHook.vcxproj.filters new file mode 100644 index 0000000..66063ae --- /dev/null +++ b/VMAudioBackHook.vcxproj.filters @@ -0,0 +1,38 @@ + + + + + {4FC737F1-C7A5-4376-A066-2A32D752A2FF} + cpp;c;cc;cxx;c++;cppm;ixx;def;odl;idl;hpj;bat;asm;asmx + + + {93995380-89BD-4b04-88EB-625FBE52EBFB} + h;hh;hpp;hxx;h++;hm;inl;inc;ipp;xsd + + + {67DA6AB6-F800-4c08-8B7A-83BB121AAD01} + rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms + + + + + 头文件 + + + 头文件 + + + + + 源文件 + + + 源文件 + + + + + 源文件 + + + \ No newline at end of file diff --git a/dllmain.cpp b/dllmain.cpp new file mode 100644 index 0000000..c018b90 --- /dev/null +++ b/dllmain.cpp @@ -0,0 +1,707 @@ +// dllmain.cpp : 定义 DLL 应用程序的入口点。 +#include "pch.h" + +typedef NTSTATUS(WINAPI* NtQueryTimerResolution_t)(ULONG* pMin, ULONG* pMax, ULONG* pCurr); +typedef NTSTATUS(WINAPI* NtSetTimerResolution_t)(ULONG desired, BOOL doSet, ULONG* pCurr); + +// +// created by AheadLib +// github:https://github.com/strivexjun/AheadLib-x86-x64 +// + +#pragma comment( lib, "Shlwapi.lib") + +#pragma comment(linker, "/EXPORT:Noname2=AheadLib_Unnamed2,@2,NONAME") +#pragma comment(linker, "/EXPORT:mciExecute=AheadLib_mciExecute,@3") +#pragma comment(linker, "/EXPORT:CloseDriver=AheadLib_CloseDriver,@4") +#pragma comment(linker, "/EXPORT:DefDriverProc=AheadLib_DefDriverProc,@5") +#pragma comment(linker, "/EXPORT:DriverCallback=AheadLib_DriverCallback,@6") +#pragma comment(linker, "/EXPORT:DrvGetModuleHandle=AheadLib_DrvGetModuleHandle,@7") +#pragma comment(linker, "/EXPORT:GetDriverModuleHandle=AheadLib_GetDriverModuleHandle,@8") +#pragma comment(linker, "/EXPORT:OpenDriver=AheadLib_OpenDriver,@9") +#pragma comment(linker, "/EXPORT:PlaySound=AheadLib_PlaySound,@10") +#pragma comment(linker, "/EXPORT:PlaySoundA=AheadLib_PlaySoundA,@11") +#pragma comment(linker, "/EXPORT:PlaySoundW=AheadLib_PlaySoundW,@12") +#pragma comment(linker, "/EXPORT:SendDriverMessage=AheadLib_SendDriverMessage,@13") +#pragma comment(linker, "/EXPORT:WOWAppExit=AheadLib_WOWAppExit,@14") +#pragma comment(linker, "/EXPORT:auxGetDevCapsA=AheadLib_auxGetDevCapsA,@15") +#pragma comment(linker, "/EXPORT:auxGetDevCapsW=AheadLib_auxGetDevCapsW,@16") +#pragma comment(linker, "/EXPORT:auxGetNumDevs=AheadLib_auxGetNumDevs,@17") +#pragma comment(linker, "/EXPORT:auxGetVolume=AheadLib_auxGetVolume,@18") +#pragma comment(linker, "/EXPORT:auxOutMessage=AheadLib_auxOutMessage,@19") +#pragma comment(linker, "/EXPORT:auxSetVolume=AheadLib_auxSetVolume,@20") +#pragma comment(linker, "/EXPORT:joyConfigChanged=AheadLib_joyConfigChanged,@21") +#pragma comment(linker, "/EXPORT:joyGetDevCapsA=AheadLib_joyGetDevCapsA,@22") +#pragma comment(linker, "/EXPORT:joyGetDevCapsW=AheadLib_joyGetDevCapsW,@23") +#pragma comment(linker, "/EXPORT:joyGetNumDevs=AheadLib_joyGetNumDevs,@24") +#pragma comment(linker, "/EXPORT:joyGetPos=AheadLib_joyGetPos,@25") +#pragma comment(linker, "/EXPORT:joyGetPosEx=AheadLib_joyGetPosEx,@26") +#pragma comment(linker, "/EXPORT:joyGetThreshold=AheadLib_joyGetThreshold,@27") +#pragma comment(linker, "/EXPORT:joyReleaseCapture=AheadLib_joyReleaseCapture,@28") +#pragma comment(linker, "/EXPORT:joySetCapture=AheadLib_joySetCapture,@29") +#pragma comment(linker, "/EXPORT:joySetThreshold=AheadLib_joySetThreshold,@30") +#pragma comment(linker, "/EXPORT:mciDriverNotify=AheadLib_mciDriverNotify,@31") +#pragma comment(linker, "/EXPORT:mciDriverYield=AheadLib_mciDriverYield,@32") +#pragma comment(linker, "/EXPORT:mciFreeCommandResource=AheadLib_mciFreeCommandResource,@33") +#pragma comment(linker, "/EXPORT:mciGetCreatorTask=AheadLib_mciGetCreatorTask,@34") +#pragma comment(linker, "/EXPORT:mciGetDeviceIDA=AheadLib_mciGetDeviceIDA,@35") +#pragma comment(linker, "/EXPORT:mciGetDeviceIDFromElementIDA=AheadLib_mciGetDeviceIDFromElementIDA,@36") +#pragma comment(linker, "/EXPORT:mciGetDeviceIDFromElementIDW=AheadLib_mciGetDeviceIDFromElementIDW,@37") +#pragma comment(linker, "/EXPORT:mciGetDeviceIDW=AheadLib_mciGetDeviceIDW,@38") +#pragma comment(linker, "/EXPORT:mciGetDriverData=AheadLib_mciGetDriverData,@39") +#pragma comment(linker, "/EXPORT:mciGetErrorStringA=AheadLib_mciGetErrorStringA,@40") +#pragma comment(linker, "/EXPORT:mciGetErrorStringW=AheadLib_mciGetErrorStringW,@41") +#pragma comment(linker, "/EXPORT:mciGetYieldProc=AheadLib_mciGetYieldProc,@42") +#pragma comment(linker, "/EXPORT:mciLoadCommandResource=AheadLib_mciLoadCommandResource,@43") +#pragma comment(linker, "/EXPORT:mciSendCommandA=AheadLib_mciSendCommandA,@44") +#pragma comment(linker, "/EXPORT:mciSendCommandW=AheadLib_mciSendCommandW,@45") +#pragma comment(linker, "/EXPORT:mciSendStringA=AheadLib_mciSendStringA,@46") +#pragma comment(linker, "/EXPORT:mciSendStringW=AheadLib_mciSendStringW,@47") +#pragma comment(linker, "/EXPORT:mciSetDriverData=AheadLib_mciSetDriverData,@48") +#pragma comment(linker, "/EXPORT:mciSetYieldProc=AheadLib_mciSetYieldProc,@49") +#pragma comment(linker, "/EXPORT:midiConnect=AheadLib_midiConnect,@50") +#pragma comment(linker, "/EXPORT:midiDisconnect=AheadLib_midiDisconnect,@51") +#pragma comment(linker, "/EXPORT:midiInAddBuffer=AheadLib_midiInAddBuffer,@52") +#pragma comment(linker, "/EXPORT:midiInClose=AheadLib_midiInClose,@53") +#pragma comment(linker, "/EXPORT:midiInGetDevCapsA=AheadLib_midiInGetDevCapsA,@54") +#pragma comment(linker, "/EXPORT:midiInGetDevCapsW=AheadLib_midiInGetDevCapsW,@55") +#pragma comment(linker, "/EXPORT:midiInGetErrorTextA=AheadLib_midiInGetErrorTextA,@56") +#pragma comment(linker, "/EXPORT:midiInGetErrorTextW=AheadLib_midiInGetErrorTextW,@57") +#pragma comment(linker, "/EXPORT:midiInGetID=AheadLib_midiInGetID,@58") +#pragma comment(linker, "/EXPORT:midiInGetNumDevs=AheadLib_midiInGetNumDevs,@59") +#pragma comment(linker, "/EXPORT:midiInMessage=AheadLib_midiInMessage,@60") +#pragma comment(linker, "/EXPORT:midiInOpen=AheadLib_midiInOpen,@61") +#pragma comment(linker, "/EXPORT:midiInPrepareHeader=AheadLib_midiInPrepareHeader,@62") +#pragma comment(linker, "/EXPORT:midiInReset=AheadLib_midiInReset,@63") +#pragma comment(linker, "/EXPORT:midiInStart=AheadLib_midiInStart,@64") +#pragma comment(linker, "/EXPORT:midiInStop=AheadLib_midiInStop,@65") +#pragma comment(linker, "/EXPORT:midiInUnprepareHeader=AheadLib_midiInUnprepareHeader,@66") +#pragma comment(linker, "/EXPORT:midiOutCacheDrumPatches=AheadLib_midiOutCacheDrumPatches,@67") +#pragma comment(linker, "/EXPORT:midiOutCachePatches=AheadLib_midiOutCachePatches,@68") +#pragma comment(linker, "/EXPORT:midiOutClose=AheadLib_midiOutClose,@69") +#pragma comment(linker, "/EXPORT:midiOutGetDevCapsA=AheadLib_midiOutGetDevCapsA,@70") +#pragma comment(linker, "/EXPORT:midiOutGetDevCapsW=AheadLib_midiOutGetDevCapsW,@71") +#pragma comment(linker, "/EXPORT:midiOutGetErrorTextA=AheadLib_midiOutGetErrorTextA,@72") +#pragma comment(linker, "/EXPORT:midiOutGetErrorTextW=AheadLib_midiOutGetErrorTextW,@73") +#pragma comment(linker, "/EXPORT:midiOutGetID=AheadLib_midiOutGetID,@74") +#pragma comment(linker, "/EXPORT:midiOutGetNumDevs=AheadLib_midiOutGetNumDevs,@75") +#pragma comment(linker, "/EXPORT:midiOutGetVolume=AheadLib_midiOutGetVolume,@76") +#pragma comment(linker, "/EXPORT:midiOutLongMsg=AheadLib_midiOutLongMsg,@77") +#pragma comment(linker, "/EXPORT:midiOutMessage=AheadLib_midiOutMessage,@78") +#pragma comment(linker, "/EXPORT:midiOutOpen=AheadLib_midiOutOpen,@79") +#pragma comment(linker, "/EXPORT:midiOutPrepareHeader=AheadLib_midiOutPrepareHeader,@80") +#pragma comment(linker, "/EXPORT:midiOutReset=AheadLib_midiOutReset,@81") +#pragma comment(linker, "/EXPORT:midiOutSetVolume=AheadLib_midiOutSetVolume,@82") +#pragma comment(linker, "/EXPORT:midiOutShortMsg=AheadLib_midiOutShortMsg,@83") +#pragma comment(linker, "/EXPORT:midiOutUnprepareHeader=AheadLib_midiOutUnprepareHeader,@84") +#pragma comment(linker, "/EXPORT:midiStreamClose=AheadLib_midiStreamClose,@85") +#pragma comment(linker, "/EXPORT:midiStreamOpen=AheadLib_midiStreamOpen,@86") +#pragma comment(linker, "/EXPORT:midiStreamOut=AheadLib_midiStreamOut,@87") +#pragma comment(linker, "/EXPORT:midiStreamPause=AheadLib_midiStreamPause,@88") +#pragma comment(linker, "/EXPORT:midiStreamPosition=AheadLib_midiStreamPosition,@89") +#pragma comment(linker, "/EXPORT:midiStreamProperty=AheadLib_midiStreamProperty,@90") +#pragma comment(linker, "/EXPORT:midiStreamRestart=AheadLib_midiStreamRestart,@91") +#pragma comment(linker, "/EXPORT:midiStreamStop=AheadLib_midiStreamStop,@92") +#pragma comment(linker, "/EXPORT:mixerClose=AheadLib_mixerClose,@93") +#pragma comment(linker, "/EXPORT:mixerGetControlDetailsA=AheadLib_mixerGetControlDetailsA,@94") +#pragma comment(linker, "/EXPORT:mixerGetControlDetailsW=AheadLib_mixerGetControlDetailsW,@95") +#pragma comment(linker, "/EXPORT:mixerGetDevCapsA=AheadLib_mixerGetDevCapsA,@96") +#pragma comment(linker, "/EXPORT:mixerGetDevCapsW=AheadLib_mixerGetDevCapsW,@97") +#pragma comment(linker, "/EXPORT:mixerGetID=AheadLib_mixerGetID,@98") +#pragma comment(linker, "/EXPORT:mixerGetLineControlsA=AheadLib_mixerGetLineControlsA,@99") +#pragma comment(linker, "/EXPORT:mixerGetLineControlsW=AheadLib_mixerGetLineControlsW,@100") +#pragma comment(linker, "/EXPORT:mixerGetLineInfoA=AheadLib_mixerGetLineInfoA,@101") +#pragma comment(linker, "/EXPORT:mixerGetLineInfoW=AheadLib_mixerGetLineInfoW,@102") +#pragma comment(linker, "/EXPORT:mixerGetNumDevs=AheadLib_mixerGetNumDevs,@103") +#pragma comment(linker, "/EXPORT:mixerMessage=AheadLib_mixerMessage,@104") +#pragma comment(linker, "/EXPORT:mixerOpen=AheadLib_mixerOpen,@105") +#pragma comment(linker, "/EXPORT:mixerSetControlDetails=AheadLib_mixerSetControlDetails,@106") +#pragma comment(linker, "/EXPORT:mmDrvInstall=AheadLib_mmDrvInstall,@107") +#pragma comment(linker, "/EXPORT:mmGetCurrentTask=AheadLib_mmGetCurrentTask,@108") +#pragma comment(linker, "/EXPORT:mmTaskBlock=AheadLib_mmTaskBlock,@109") +#pragma comment(linker, "/EXPORT:mmTaskCreate=AheadLib_mmTaskCreate,@110") +#pragma comment(linker, "/EXPORT:mmTaskSignal=AheadLib_mmTaskSignal,@111") +#pragma comment(linker, "/EXPORT:mmTaskYield=AheadLib_mmTaskYield,@112") +#pragma comment(linker, "/EXPORT:mmioAdvance=AheadLib_mmioAdvance,@113") +#pragma comment(linker, "/EXPORT:mmioAscend=AheadLib_mmioAscend,@114") +#pragma comment(linker, "/EXPORT:mmioClose=AheadLib_mmioClose,@115") +#pragma comment(linker, "/EXPORT:mmioCreateChunk=AheadLib_mmioCreateChunk,@116") +#pragma comment(linker, "/EXPORT:mmioDescend=AheadLib_mmioDescend,@117") +#pragma comment(linker, "/EXPORT:mmioFlush=AheadLib_mmioFlush,@118") +#pragma comment(linker, "/EXPORT:mmioGetInfo=AheadLib_mmioGetInfo,@119") +#pragma comment(linker, "/EXPORT:mmioInstallIOProcA=AheadLib_mmioInstallIOProcA,@120") +#pragma comment(linker, "/EXPORT:mmioInstallIOProcW=AheadLib_mmioInstallIOProcW,@121") +#pragma comment(linker, "/EXPORT:mmioOpenA=AheadLib_mmioOpenA,@122") +#pragma comment(linker, "/EXPORT:mmioOpenW=AheadLib_mmioOpenW,@123") +#pragma comment(linker, "/EXPORT:mmioRead=AheadLib_mmioRead,@124") +#pragma comment(linker, "/EXPORT:mmioRenameA=AheadLib_mmioRenameA,@125") +#pragma comment(linker, "/EXPORT:mmioRenameW=AheadLib_mmioRenameW,@126") +#pragma comment(linker, "/EXPORT:mmioSeek=AheadLib_mmioSeek,@127") +#pragma comment(linker, "/EXPORT:mmioSendMessage=AheadLib_mmioSendMessage,@128") +#pragma comment(linker, "/EXPORT:mmioSetBuffer=AheadLib_mmioSetBuffer,@129") +#pragma comment(linker, "/EXPORT:mmioSetInfo=AheadLib_mmioSetInfo,@130") +#pragma comment(linker, "/EXPORT:mmioStringToFOURCCA=AheadLib_mmioStringToFOURCCA,@131") +#pragma comment(linker, "/EXPORT:mmioStringToFOURCCW=AheadLib_mmioStringToFOURCCW,@132") +#pragma comment(linker, "/EXPORT:mmioWrite=AheadLib_mmioWrite,@133") +#pragma comment(linker, "/EXPORT:mmsystemGetVersion=AheadLib_mmsystemGetVersion,@134") +#pragma comment(linker, "/EXPORT:sndPlaySoundA=AheadLib_sndPlaySoundA,@135") +#pragma comment(linker, "/EXPORT:sndPlaySoundW=AheadLib_sndPlaySoundW,@136") +#pragma comment(linker, "/EXPORT:timeBeginPeriod=AheadLib_timeBeginPeriod,@137") +#pragma comment(linker, "/EXPORT:timeEndPeriod=AheadLib_timeEndPeriod,@138") +#pragma comment(linker, "/EXPORT:timeGetDevCaps=AheadLib_timeGetDevCaps,@139") +#pragma comment(linker, "/EXPORT:timeGetSystemTime=AheadLib_timeGetSystemTime,@140") +#pragma comment(linker, "/EXPORT:timeGetTime=AheadLib_timeGetTime,@141") +#pragma comment(linker, "/EXPORT:timeKillEvent=AheadLib_timeKillEvent,@142") +#pragma comment(linker, "/EXPORT:timeSetEvent=AheadLib_timeSetEvent,@143") +#pragma comment(linker, "/EXPORT:waveInAddBuffer=AheadLib_waveInAddBuffer,@144") +#pragma comment(linker, "/EXPORT:waveInClose=AheadLib_waveInClose,@145") +#pragma comment(linker, "/EXPORT:waveInGetDevCapsA=AheadLib_waveInGetDevCapsA,@146") +#pragma comment(linker, "/EXPORT:waveInGetDevCapsW=AheadLib_waveInGetDevCapsW,@147") +#pragma comment(linker, "/EXPORT:waveInGetErrorTextA=AheadLib_waveInGetErrorTextA,@148") +#pragma comment(linker, "/EXPORT:waveInGetErrorTextW=AheadLib_waveInGetErrorTextW,@149") +#pragma comment(linker, "/EXPORT:waveInGetID=AheadLib_waveInGetID,@150") +#pragma comment(linker, "/EXPORT:waveInGetNumDevs=AheadLib_waveInGetNumDevs,@151") +#pragma comment(linker, "/EXPORT:waveInGetPosition=AheadLib_waveInGetPosition,@152") +#pragma comment(linker, "/EXPORT:waveInMessage=AheadLib_waveInMessage,@153") +#pragma comment(linker, "/EXPORT:waveInOpen=AheadLib_waveInOpen,@154") +#pragma comment(linker, "/EXPORT:waveInPrepareHeader=AheadLib_waveInPrepareHeader,@155") +#pragma comment(linker, "/EXPORT:waveInReset=AheadLib_waveInReset,@156") +#pragma comment(linker, "/EXPORT:waveInStart=AheadLib_waveInStart,@157") +#pragma comment(linker, "/EXPORT:waveInStop=AheadLib_waveInStop,@158") +#pragma comment(linker, "/EXPORT:waveInUnprepareHeader=AheadLib_waveInUnprepareHeader,@159") +#pragma comment(linker, "/EXPORT:waveOutBreakLoop=AheadLib_waveOutBreakLoop,@160") +#pragma comment(linker, "/EXPORT:waveOutClose=AheadLib_waveOutClose,@161") +#pragma comment(linker, "/EXPORT:waveOutGetDevCapsA=AheadLib_waveOutGetDevCapsA,@162") +#pragma comment(linker, "/EXPORT:waveOutGetDevCapsW=AheadLib_waveOutGetDevCapsW,@163") +#pragma comment(linker, "/EXPORT:waveOutGetErrorTextA=AheadLib_waveOutGetErrorTextA,@164") +#pragma comment(linker, "/EXPORT:waveOutGetErrorTextW=AheadLib_waveOutGetErrorTextW,@165") +#pragma comment(linker, "/EXPORT:waveOutGetID=AheadLib_waveOutGetID,@166") +#pragma comment(linker, "/EXPORT:waveOutGetNumDevs=AheadLib_waveOutGetNumDevs,@167") +#pragma comment(linker, "/EXPORT:waveOutGetPitch=AheadLib_waveOutGetPitch,@168") +#pragma comment(linker, "/EXPORT:waveOutGetPlaybackRate=AheadLib_waveOutGetPlaybackRate,@169") +#pragma comment(linker, "/EXPORT:waveOutGetPosition=AheadLib_waveOutGetPosition,@170") +#pragma comment(linker, "/EXPORT:waveOutGetVolume=AheadLib_waveOutGetVolume,@171") +#pragma comment(linker, "/EXPORT:waveOutMessage=AheadLib_waveOutMessage,@172") +#pragma comment(linker, "/EXPORT:waveOutOpen=AheadLib_waveOutOpen,@173") +#pragma comment(linker, "/EXPORT:waveOutPause=AheadLib_waveOutPause,@174") +#pragma comment(linker, "/EXPORT:waveOutPrepareHeader=AheadLib_waveOutPrepareHeader,@175") +#pragma comment(linker, "/EXPORT:waveOutReset=AheadLib_waveOutReset,@176") +#pragma comment(linker, "/EXPORT:waveOutRestart=AheadLib_waveOutRestart,@177") +#pragma comment(linker, "/EXPORT:waveOutSetPitch=AheadLib_waveOutSetPitch,@178") +#pragma comment(linker, "/EXPORT:waveOutSetPlaybackRate=AheadLib_waveOutSetPlaybackRate,@179") +#pragma comment(linker, "/EXPORT:waveOutSetVolume=AheadLib_waveOutSetVolume,@180") +#pragma comment(linker, "/EXPORT:waveOutUnprepareHeader=AheadLib_waveOutUnprepareHeader,@181") +#pragma comment(linker, "/EXPORT:waveOutWrite=AheadLib_waveOutWrite,@182") + + +extern "C" +{ + PVOID pfnAheadLib_Unnamed2; + PVOID pfnAheadLib_mciExecute; + PVOID pfnAheadLib_CloseDriver; + PVOID pfnAheadLib_DefDriverProc; + PVOID pfnAheadLib_DriverCallback; + PVOID pfnAheadLib_DrvGetModuleHandle; + PVOID pfnAheadLib_GetDriverModuleHandle; + PVOID pfnAheadLib_OpenDriver; + PVOID pfnAheadLib_PlaySound; + PVOID pfnAheadLib_PlaySoundA; + PVOID pfnAheadLib_PlaySoundW; + PVOID pfnAheadLib_SendDriverMessage; + PVOID pfnAheadLib_WOWAppExit; + PVOID pfnAheadLib_auxGetDevCapsA; + PVOID pfnAheadLib_auxGetDevCapsW; + PVOID pfnAheadLib_auxGetNumDevs; + PVOID pfnAheadLib_auxGetVolume; + PVOID pfnAheadLib_auxOutMessage; + PVOID pfnAheadLib_auxSetVolume; + PVOID pfnAheadLib_joyConfigChanged; + PVOID pfnAheadLib_joyGetDevCapsA; + PVOID pfnAheadLib_joyGetDevCapsW; + PVOID pfnAheadLib_joyGetNumDevs; + PVOID pfnAheadLib_joyGetPos; + PVOID pfnAheadLib_joyGetPosEx; + PVOID pfnAheadLib_joyGetThreshold; + PVOID pfnAheadLib_joyReleaseCapture; + PVOID pfnAheadLib_joySetCapture; + PVOID pfnAheadLib_joySetThreshold; + PVOID pfnAheadLib_mciDriverNotify; + PVOID pfnAheadLib_mciDriverYield; + PVOID pfnAheadLib_mciFreeCommandResource; + PVOID pfnAheadLib_mciGetCreatorTask; + PVOID pfnAheadLib_mciGetDeviceIDA; + PVOID pfnAheadLib_mciGetDeviceIDFromElementIDA; + PVOID pfnAheadLib_mciGetDeviceIDFromElementIDW; + PVOID pfnAheadLib_mciGetDeviceIDW; + PVOID pfnAheadLib_mciGetDriverData; + PVOID pfnAheadLib_mciGetErrorStringA; + PVOID pfnAheadLib_mciGetErrorStringW; + PVOID pfnAheadLib_mciGetYieldProc; + PVOID pfnAheadLib_mciLoadCommandResource; + PVOID pfnAheadLib_mciSendCommandA; + PVOID pfnAheadLib_mciSendCommandW; + PVOID pfnAheadLib_mciSendStringA; + PVOID pfnAheadLib_mciSendStringW; + PVOID pfnAheadLib_mciSetDriverData; + PVOID pfnAheadLib_mciSetYieldProc; + PVOID pfnAheadLib_midiConnect; + PVOID pfnAheadLib_midiDisconnect; + PVOID pfnAheadLib_midiInAddBuffer; + PVOID pfnAheadLib_midiInClose; + PVOID pfnAheadLib_midiInGetDevCapsA; + PVOID pfnAheadLib_midiInGetDevCapsW; + PVOID pfnAheadLib_midiInGetErrorTextA; + PVOID pfnAheadLib_midiInGetErrorTextW; + PVOID pfnAheadLib_midiInGetID; + PVOID pfnAheadLib_midiInGetNumDevs; + PVOID pfnAheadLib_midiInMessage; + PVOID pfnAheadLib_midiInOpen; + PVOID pfnAheadLib_midiInPrepareHeader; + PVOID pfnAheadLib_midiInReset; + PVOID pfnAheadLib_midiInStart; + PVOID pfnAheadLib_midiInStop; + PVOID pfnAheadLib_midiInUnprepareHeader; + PVOID pfnAheadLib_midiOutCacheDrumPatches; + PVOID pfnAheadLib_midiOutCachePatches; + PVOID pfnAheadLib_midiOutClose; + PVOID pfnAheadLib_midiOutGetDevCapsA; + PVOID pfnAheadLib_midiOutGetDevCapsW; + PVOID pfnAheadLib_midiOutGetErrorTextA; + PVOID pfnAheadLib_midiOutGetErrorTextW; + PVOID pfnAheadLib_midiOutGetID; + PVOID pfnAheadLib_midiOutGetNumDevs; + PVOID pfnAheadLib_midiOutGetVolume; + PVOID pfnAheadLib_midiOutLongMsg; + PVOID pfnAheadLib_midiOutMessage; + PVOID pfnAheadLib_midiOutOpen; + PVOID pfnAheadLib_midiOutPrepareHeader; + PVOID pfnAheadLib_midiOutReset; + PVOID pfnAheadLib_midiOutSetVolume; + PVOID pfnAheadLib_midiOutShortMsg; + PVOID pfnAheadLib_midiOutUnprepareHeader; + PVOID pfnAheadLib_midiStreamClose; + PVOID pfnAheadLib_midiStreamOpen; + PVOID pfnAheadLib_midiStreamOut; + PVOID pfnAheadLib_midiStreamPause; + PVOID pfnAheadLib_midiStreamPosition; + PVOID pfnAheadLib_midiStreamProperty; + PVOID pfnAheadLib_midiStreamRestart; + PVOID pfnAheadLib_midiStreamStop; + PVOID pfnAheadLib_mixerClose; + PVOID pfnAheadLib_mixerGetControlDetailsA; + PVOID pfnAheadLib_mixerGetControlDetailsW; + PVOID pfnAheadLib_mixerGetDevCapsA; + PVOID pfnAheadLib_mixerGetDevCapsW; + PVOID pfnAheadLib_mixerGetID; + PVOID pfnAheadLib_mixerGetLineControlsA; + PVOID pfnAheadLib_mixerGetLineControlsW; + PVOID pfnAheadLib_mixerGetLineInfoA; + PVOID pfnAheadLib_mixerGetLineInfoW; + PVOID pfnAheadLib_mixerGetNumDevs; + PVOID pfnAheadLib_mixerMessage; + PVOID pfnAheadLib_mixerOpen; + PVOID pfnAheadLib_mixerSetControlDetails; + PVOID pfnAheadLib_mmDrvInstall; + PVOID pfnAheadLib_mmGetCurrentTask; + PVOID pfnAheadLib_mmTaskBlock; + PVOID pfnAheadLib_mmTaskCreate; + PVOID pfnAheadLib_mmTaskSignal; + PVOID pfnAheadLib_mmTaskYield; + PVOID pfnAheadLib_mmioAdvance; + PVOID pfnAheadLib_mmioAscend; + PVOID pfnAheadLib_mmioClose; + PVOID pfnAheadLib_mmioCreateChunk; + PVOID pfnAheadLib_mmioDescend; + PVOID pfnAheadLib_mmioFlush; + PVOID pfnAheadLib_mmioGetInfo; + PVOID pfnAheadLib_mmioInstallIOProcA; + PVOID pfnAheadLib_mmioInstallIOProcW; + PVOID pfnAheadLib_mmioOpenA; + PVOID pfnAheadLib_mmioOpenW; + PVOID pfnAheadLib_mmioRead; + PVOID pfnAheadLib_mmioRenameA; + PVOID pfnAheadLib_mmioRenameW; + PVOID pfnAheadLib_mmioSeek; + PVOID pfnAheadLib_mmioSendMessage; + PVOID pfnAheadLib_mmioSetBuffer; + PVOID pfnAheadLib_mmioSetInfo; + PVOID pfnAheadLib_mmioStringToFOURCCA; + PVOID pfnAheadLib_mmioStringToFOURCCW; + PVOID pfnAheadLib_mmioWrite; + PVOID pfnAheadLib_mmsystemGetVersion; + PVOID pfnAheadLib_sndPlaySoundA; + PVOID pfnAheadLib_sndPlaySoundW; + PVOID pfnAheadLib_timeBeginPeriod; + PVOID pfnAheadLib_timeEndPeriod; + PVOID pfnAheadLib_timeGetDevCaps; + PVOID pfnAheadLib_timeGetSystemTime; + PVOID pfnAheadLib_timeGetTime; + PVOID pfnAheadLib_timeKillEvent; + PVOID pfnAheadLib_timeSetEvent; + PVOID pfnAheadLib_waveInAddBuffer; + PVOID pfnAheadLib_waveInClose; + PVOID pfnAheadLib_waveInGetDevCapsA; + PVOID pfnAheadLib_waveInGetDevCapsW; + PVOID pfnAheadLib_waveInGetErrorTextA; + PVOID pfnAheadLib_waveInGetErrorTextW; + PVOID pfnAheadLib_waveInGetID; + PVOID pfnAheadLib_waveInGetNumDevs; + PVOID pfnAheadLib_waveInGetPosition; + PVOID pfnAheadLib_waveInMessage; + PVOID pfnAheadLib_waveInOpen; + PVOID pfnAheadLib_waveInPrepareHeader; + PVOID pfnAheadLib_waveInReset; + PVOID pfnAheadLib_waveInStart; + PVOID pfnAheadLib_waveInStop; + PVOID pfnAheadLib_waveInUnprepareHeader; + PVOID pfnAheadLib_waveOutBreakLoop; + PVOID pfnAheadLib_waveOutClose; + PVOID pfnAheadLib_waveOutGetDevCapsA; + PVOID pfnAheadLib_waveOutGetDevCapsW; + PVOID pfnAheadLib_waveOutGetErrorTextA; + PVOID pfnAheadLib_waveOutGetErrorTextW; + PVOID pfnAheadLib_waveOutGetID; + PVOID pfnAheadLib_waveOutGetNumDevs; + PVOID pfnAheadLib_waveOutGetPitch; + PVOID pfnAheadLib_waveOutGetPlaybackRate; + PVOID pfnAheadLib_waveOutGetPosition; + PVOID pfnAheadLib_waveOutGetVolume; + PVOID pfnAheadLib_waveOutMessage; + PVOID pfnAheadLib_waveOutOpen; + PVOID pfnAheadLib_waveOutPause; + PVOID pfnAheadLib_waveOutPrepareHeader; + PVOID pfnAheadLib_waveOutReset; + PVOID pfnAheadLib_waveOutRestart; + PVOID pfnAheadLib_waveOutSetPitch; + PVOID pfnAheadLib_waveOutSetPlaybackRate; + PVOID pfnAheadLib_waveOutSetVolume; + PVOID pfnAheadLib_waveOutUnprepareHeader; + PVOID pfnAheadLib_waveOutWrite; +} + + +static +HMODULE g_OldModule = NULL; + +VOID WINAPI Free() +{ + if (g_OldModule) + { + FreeLibrary(g_OldModule); + } +} + + +BOOL WINAPI Load() +{ + TCHAR tzPath[MAX_PATH]; + TCHAR tzTemp[MAX_PATH * 2]; + + GetSystemDirectory(tzPath, MAX_PATH); + + lstrcat(tzPath, TEXT("\\winmm.dll")); + + g_OldModule = LoadLibrary(tzPath); + if (g_OldModule == NULL) + { + wsprintf(tzTemp, TEXT("%s not found"), tzPath); + MessageBox(NULL, tzTemp, TEXT("AheadLib"), MB_ICONSTOP); + ExitProcess(-2); + } + + return (g_OldModule != NULL); + +} + + +FARPROC WINAPI GetAddress(PCSTR pszProcName) +{ + FARPROC fpAddress; + CHAR szProcName[64]; + TCHAR tzTemp[MAX_PATH]; + + fpAddress = GetProcAddress(g_OldModule, pszProcName); + if (fpAddress == NULL) + { + if (HIWORD(pszProcName) == 0) + { + wsprintfA(szProcName, "#%d", pszProcName); + pszProcName = szProcName; + } + + wsprintf(tzTemp, TEXT("function %hs not found"), pszProcName); + MessageBox(NULL, tzTemp, TEXT("AheadLib"), MB_ICONSTOP); + ExitProcess(-2); + } + return fpAddress; +} + +BOOL WINAPI Init() +{ + pfnAheadLib_Unnamed2 = GetAddress(MAKEINTRESOURCEA(2)); + pfnAheadLib_mciExecute = GetAddress("mciExecute"); + pfnAheadLib_CloseDriver = GetAddress("CloseDriver"); + pfnAheadLib_DefDriverProc = GetAddress("DefDriverProc"); + pfnAheadLib_DriverCallback = GetAddress("DriverCallback"); + pfnAheadLib_DrvGetModuleHandle = GetAddress("DrvGetModuleHandle"); + pfnAheadLib_GetDriverModuleHandle = GetAddress("GetDriverModuleHandle"); + pfnAheadLib_OpenDriver = GetAddress("OpenDriver"); + pfnAheadLib_PlaySound = GetAddress("PlaySound"); + pfnAheadLib_PlaySoundA = GetAddress("PlaySoundA"); + pfnAheadLib_PlaySoundW = GetAddress("PlaySoundW"); + pfnAheadLib_SendDriverMessage = GetAddress("SendDriverMessage"); + pfnAheadLib_WOWAppExit = GetAddress("WOWAppExit"); + pfnAheadLib_auxGetDevCapsA = GetAddress("auxGetDevCapsA"); + pfnAheadLib_auxGetDevCapsW = GetAddress("auxGetDevCapsW"); + pfnAheadLib_auxGetNumDevs = GetAddress("auxGetNumDevs"); + pfnAheadLib_auxGetVolume = GetAddress("auxGetVolume"); + pfnAheadLib_auxOutMessage = GetAddress("auxOutMessage"); + pfnAheadLib_auxSetVolume = GetAddress("auxSetVolume"); + pfnAheadLib_joyConfigChanged = GetAddress("joyConfigChanged"); + pfnAheadLib_joyGetDevCapsA = GetAddress("joyGetDevCapsA"); + pfnAheadLib_joyGetDevCapsW = GetAddress("joyGetDevCapsW"); + pfnAheadLib_joyGetNumDevs = GetAddress("joyGetNumDevs"); + pfnAheadLib_joyGetPos = GetAddress("joyGetPos"); + pfnAheadLib_joyGetPosEx = GetAddress("joyGetPosEx"); + pfnAheadLib_joyGetThreshold = GetAddress("joyGetThreshold"); + pfnAheadLib_joyReleaseCapture = GetAddress("joyReleaseCapture"); + pfnAheadLib_joySetCapture = GetAddress("joySetCapture"); + pfnAheadLib_joySetThreshold = GetAddress("joySetThreshold"); + pfnAheadLib_mciDriverNotify = GetAddress("mciDriverNotify"); + pfnAheadLib_mciDriverYield = GetAddress("mciDriverYield"); + pfnAheadLib_mciFreeCommandResource = GetAddress("mciFreeCommandResource"); + pfnAheadLib_mciGetCreatorTask = GetAddress("mciGetCreatorTask"); + pfnAheadLib_mciGetDeviceIDA = GetAddress("mciGetDeviceIDA"); + pfnAheadLib_mciGetDeviceIDFromElementIDA = GetAddress("mciGetDeviceIDFromElementIDA"); + pfnAheadLib_mciGetDeviceIDFromElementIDW = GetAddress("mciGetDeviceIDFromElementIDW"); + pfnAheadLib_mciGetDeviceIDW = GetAddress("mciGetDeviceIDW"); + pfnAheadLib_mciGetDriverData = GetAddress("mciGetDriverData"); + pfnAheadLib_mciGetErrorStringA = GetAddress("mciGetErrorStringA"); + pfnAheadLib_mciGetErrorStringW = GetAddress("mciGetErrorStringW"); + pfnAheadLib_mciGetYieldProc = GetAddress("mciGetYieldProc"); + pfnAheadLib_mciLoadCommandResource = GetAddress("mciLoadCommandResource"); + pfnAheadLib_mciSendCommandA = GetAddress("mciSendCommandA"); + pfnAheadLib_mciSendCommandW = GetAddress("mciSendCommandW"); + pfnAheadLib_mciSendStringA = GetAddress("mciSendStringA"); + pfnAheadLib_mciSendStringW = GetAddress("mciSendStringW"); + pfnAheadLib_mciSetDriverData = GetAddress("mciSetDriverData"); + pfnAheadLib_mciSetYieldProc = GetAddress("mciSetYieldProc"); + pfnAheadLib_midiConnect = GetAddress("midiConnect"); + pfnAheadLib_midiDisconnect = GetAddress("midiDisconnect"); + pfnAheadLib_midiInAddBuffer = GetAddress("midiInAddBuffer"); + pfnAheadLib_midiInClose = GetAddress("midiInClose"); + pfnAheadLib_midiInGetDevCapsA = GetAddress("midiInGetDevCapsA"); + pfnAheadLib_midiInGetDevCapsW = GetAddress("midiInGetDevCapsW"); + pfnAheadLib_midiInGetErrorTextA = GetAddress("midiInGetErrorTextA"); + pfnAheadLib_midiInGetErrorTextW = GetAddress("midiInGetErrorTextW"); + pfnAheadLib_midiInGetID = GetAddress("midiInGetID"); + pfnAheadLib_midiInGetNumDevs = GetAddress("midiInGetNumDevs"); + pfnAheadLib_midiInMessage = GetAddress("midiInMessage"); + pfnAheadLib_midiInOpen = GetAddress("midiInOpen"); + pfnAheadLib_midiInPrepareHeader = GetAddress("midiInPrepareHeader"); + pfnAheadLib_midiInReset = GetAddress("midiInReset"); + pfnAheadLib_midiInStart = GetAddress("midiInStart"); + pfnAheadLib_midiInStop = GetAddress("midiInStop"); + pfnAheadLib_midiInUnprepareHeader = GetAddress("midiInUnprepareHeader"); + pfnAheadLib_midiOutCacheDrumPatches = GetAddress("midiOutCacheDrumPatches"); + pfnAheadLib_midiOutCachePatches = GetAddress("midiOutCachePatches"); + pfnAheadLib_midiOutClose = GetAddress("midiOutClose"); + pfnAheadLib_midiOutGetDevCapsA = GetAddress("midiOutGetDevCapsA"); + pfnAheadLib_midiOutGetDevCapsW = GetAddress("midiOutGetDevCapsW"); + pfnAheadLib_midiOutGetErrorTextA = GetAddress("midiOutGetErrorTextA"); + pfnAheadLib_midiOutGetErrorTextW = GetAddress("midiOutGetErrorTextW"); + pfnAheadLib_midiOutGetID = GetAddress("midiOutGetID"); + pfnAheadLib_midiOutGetNumDevs = GetAddress("midiOutGetNumDevs"); + pfnAheadLib_midiOutGetVolume = GetAddress("midiOutGetVolume"); + pfnAheadLib_midiOutLongMsg = GetAddress("midiOutLongMsg"); + pfnAheadLib_midiOutMessage = GetAddress("midiOutMessage"); + pfnAheadLib_midiOutOpen = GetAddress("midiOutOpen"); + pfnAheadLib_midiOutPrepareHeader = GetAddress("midiOutPrepareHeader"); + pfnAheadLib_midiOutReset = GetAddress("midiOutReset"); + pfnAheadLib_midiOutSetVolume = GetAddress("midiOutSetVolume"); + pfnAheadLib_midiOutShortMsg = GetAddress("midiOutShortMsg"); + pfnAheadLib_midiOutUnprepareHeader = GetAddress("midiOutUnprepareHeader"); + pfnAheadLib_midiStreamClose = GetAddress("midiStreamClose"); + pfnAheadLib_midiStreamOpen = GetAddress("midiStreamOpen"); + pfnAheadLib_midiStreamOut = GetAddress("midiStreamOut"); + pfnAheadLib_midiStreamPause = GetAddress("midiStreamPause"); + pfnAheadLib_midiStreamPosition = GetAddress("midiStreamPosition"); + pfnAheadLib_midiStreamProperty = GetAddress("midiStreamProperty"); + pfnAheadLib_midiStreamRestart = GetAddress("midiStreamRestart"); + pfnAheadLib_midiStreamStop = GetAddress("midiStreamStop"); + pfnAheadLib_mixerClose = GetAddress("mixerClose"); + pfnAheadLib_mixerGetControlDetailsA = GetAddress("mixerGetControlDetailsA"); + pfnAheadLib_mixerGetControlDetailsW = GetAddress("mixerGetControlDetailsW"); + pfnAheadLib_mixerGetDevCapsA = GetAddress("mixerGetDevCapsA"); + pfnAheadLib_mixerGetDevCapsW = GetAddress("mixerGetDevCapsW"); + pfnAheadLib_mixerGetID = GetAddress("mixerGetID"); + pfnAheadLib_mixerGetLineControlsA = GetAddress("mixerGetLineControlsA"); + pfnAheadLib_mixerGetLineControlsW = GetAddress("mixerGetLineControlsW"); + pfnAheadLib_mixerGetLineInfoA = GetAddress("mixerGetLineInfoA"); + pfnAheadLib_mixerGetLineInfoW = GetAddress("mixerGetLineInfoW"); + pfnAheadLib_mixerGetNumDevs = GetAddress("mixerGetNumDevs"); + pfnAheadLib_mixerMessage = GetAddress("mixerMessage"); + pfnAheadLib_mixerOpen = GetAddress("mixerOpen"); + pfnAheadLib_mixerSetControlDetails = GetAddress("mixerSetControlDetails"); + pfnAheadLib_mmDrvInstall = GetAddress("mmDrvInstall"); + pfnAheadLib_mmGetCurrentTask = GetAddress("mmGetCurrentTask"); + pfnAheadLib_mmTaskBlock = GetAddress("mmTaskBlock"); + pfnAheadLib_mmTaskCreate = GetAddress("mmTaskCreate"); + pfnAheadLib_mmTaskSignal = GetAddress("mmTaskSignal"); + pfnAheadLib_mmTaskYield = GetAddress("mmTaskYield"); + pfnAheadLib_mmioAdvance = GetAddress("mmioAdvance"); + pfnAheadLib_mmioAscend = GetAddress("mmioAscend"); + pfnAheadLib_mmioClose = GetAddress("mmioClose"); + pfnAheadLib_mmioCreateChunk = GetAddress("mmioCreateChunk"); + pfnAheadLib_mmioDescend = GetAddress("mmioDescend"); + pfnAheadLib_mmioFlush = GetAddress("mmioFlush"); + pfnAheadLib_mmioGetInfo = GetAddress("mmioGetInfo"); + pfnAheadLib_mmioInstallIOProcA = GetAddress("mmioInstallIOProcA"); + pfnAheadLib_mmioInstallIOProcW = GetAddress("mmioInstallIOProcW"); + pfnAheadLib_mmioOpenA = GetAddress("mmioOpenA"); + pfnAheadLib_mmioOpenW = GetAddress("mmioOpenW"); + pfnAheadLib_mmioRead = GetAddress("mmioRead"); + pfnAheadLib_mmioRenameA = GetAddress("mmioRenameA"); + pfnAheadLib_mmioRenameW = GetAddress("mmioRenameW"); + pfnAheadLib_mmioSeek = GetAddress("mmioSeek"); + pfnAheadLib_mmioSendMessage = GetAddress("mmioSendMessage"); + pfnAheadLib_mmioSetBuffer = GetAddress("mmioSetBuffer"); + pfnAheadLib_mmioSetInfo = GetAddress("mmioSetInfo"); + pfnAheadLib_mmioStringToFOURCCA = GetAddress("mmioStringToFOURCCA"); + pfnAheadLib_mmioStringToFOURCCW = GetAddress("mmioStringToFOURCCW"); + pfnAheadLib_mmioWrite = GetAddress("mmioWrite"); + pfnAheadLib_mmsystemGetVersion = GetAddress("mmsystemGetVersion"); + pfnAheadLib_sndPlaySoundA = GetAddress("sndPlaySoundA"); + pfnAheadLib_sndPlaySoundW = GetAddress("sndPlaySoundW"); + pfnAheadLib_timeBeginPeriod = GetAddress("timeBeginPeriod"); + pfnAheadLib_timeEndPeriod = GetAddress("timeEndPeriod"); + pfnAheadLib_timeGetDevCaps = GetAddress("timeGetDevCaps"); + pfnAheadLib_timeGetSystemTime = GetAddress("timeGetSystemTime"); + pfnAheadLib_timeGetTime = GetAddress("timeGetTime"); + pfnAheadLib_timeKillEvent = GetAddress("timeKillEvent"); + pfnAheadLib_timeSetEvent = GetAddress("timeSetEvent"); + pfnAheadLib_waveInAddBuffer = GetAddress("waveInAddBuffer"); + pfnAheadLib_waveInClose = GetAddress("waveInClose"); + pfnAheadLib_waveInGetDevCapsA = GetAddress("waveInGetDevCapsA"); + pfnAheadLib_waveInGetDevCapsW = GetAddress("waveInGetDevCapsW"); + pfnAheadLib_waveInGetErrorTextA = GetAddress("waveInGetErrorTextA"); + pfnAheadLib_waveInGetErrorTextW = GetAddress("waveInGetErrorTextW"); + pfnAheadLib_waveInGetID = GetAddress("waveInGetID"); + pfnAheadLib_waveInGetNumDevs = GetAddress("waveInGetNumDevs"); + pfnAheadLib_waveInGetPosition = GetAddress("waveInGetPosition"); + pfnAheadLib_waveInMessage = GetAddress("waveInMessage"); + pfnAheadLib_waveInOpen = GetAddress("waveInOpen"); + pfnAheadLib_waveInPrepareHeader = GetAddress("waveInPrepareHeader"); + pfnAheadLib_waveInReset = GetAddress("waveInReset"); + pfnAheadLib_waveInStart = GetAddress("waveInStart"); + pfnAheadLib_waveInStop = GetAddress("waveInStop"); + pfnAheadLib_waveInUnprepareHeader = GetAddress("waveInUnprepareHeader"); + pfnAheadLib_waveOutBreakLoop = GetAddress("waveOutBreakLoop"); + pfnAheadLib_waveOutClose = GetAddress("waveOutClose"); + pfnAheadLib_waveOutGetDevCapsA = GetAddress("waveOutGetDevCapsA"); + pfnAheadLib_waveOutGetDevCapsW = GetAddress("waveOutGetDevCapsW"); + pfnAheadLib_waveOutGetErrorTextA = GetAddress("waveOutGetErrorTextA"); + pfnAheadLib_waveOutGetErrorTextW = GetAddress("waveOutGetErrorTextW"); + pfnAheadLib_waveOutGetID = GetAddress("waveOutGetID"); + pfnAheadLib_waveOutGetNumDevs = GetAddress("waveOutGetNumDevs"); + pfnAheadLib_waveOutGetPitch = GetAddress("waveOutGetPitch"); + pfnAheadLib_waveOutGetPlaybackRate = GetAddress("waveOutGetPlaybackRate"); + pfnAheadLib_waveOutGetPosition = GetAddress("waveOutGetPosition"); + pfnAheadLib_waveOutGetVolume = GetAddress("waveOutGetVolume"); + pfnAheadLib_waveOutMessage = GetAddress("waveOutMessage"); + pfnAheadLib_waveOutOpen = GetAddress("waveOutOpen"); + pfnAheadLib_waveOutPause = GetAddress("waveOutPause"); + pfnAheadLib_waveOutPrepareHeader = GetAddress("waveOutPrepareHeader"); + pfnAheadLib_waveOutReset = GetAddress("waveOutReset"); + pfnAheadLib_waveOutRestart = GetAddress("waveOutRestart"); + pfnAheadLib_waveOutSetPitch = GetAddress("waveOutSetPitch"); + pfnAheadLib_waveOutSetPlaybackRate = GetAddress("waveOutSetPlaybackRate"); + pfnAheadLib_waveOutSetVolume = GetAddress("waveOutSetVolume"); + pfnAheadLib_waveOutUnprepareHeader = GetAddress("waveOutUnprepareHeader"); + pfnAheadLib_waveOutWrite = GetAddress("waveOutWrite"); + return TRUE; +} + +DWORD WINAPI ThreadProc(LPVOID lpThreadParameter) +{ + HRESULT hr = 0; + WCHAR ntdll_path[MAX_PATH] = L""; + HMODULE ntdll_hMod = 0; + NtQueryTimerResolution_t pfnNtQueryTimerResolution = NULL; + NtSetTimerResolution_t pfnNtSetTimerResolution = NULL; + ULONG minRes = 0, maxRes = 0, currRes = 0, desiredRes = 0; + NTSTATUS ntstatus = 0; + + GetSystemDirectoryW(ntdll_path, MAX_PATH); + lstrcatW(ntdll_path, L"\\ntdll.dll"); + ntdll_hMod = GetModuleHandleW(ntdll_path); + if (!ntdll_hMod) + { + DWORD w32err = GetLastError(); + hr = HRESULT_FROM_WIN32(w32err); + goto eof; + } + pfnNtQueryTimerResolution = (NtQueryTimerResolution_t)GetProcAddress(ntdll_hMod, "NtQueryTimerResolution"); + if (!pfnNtQueryTimerResolution) + { + hr = E_NOTIMPL; + goto eof; + } + pfnNtSetTimerResolution = (NtSetTimerResolution_t)GetProcAddress(ntdll_hMod, "NtSetTimerResolution"); + if (!pfnNtSetTimerResolution) + { + hr = E_NOTIMPL; + goto eof; + } + + ntstatus = pfnNtQueryTimerResolution(&minRes, &maxRes, &currRes); + if (ntstatus) + { + hr = E_FAIL; + goto eof; + } + // in 100-ns units, 1000000ns = 1ms + desiredRes = 10000; + ntstatus = pfnNtSetTimerResolution(desiredRes, TRUE, &currRes); + if (ntstatus) + { + hr = E_FAIL; + goto eof; + } +eof: + return hr; +} + + +BOOL APIENTRY DllMain(HMODULE hModule, DWORD dwReason, PVOID pvReserved) +{ + if (dwReason == DLL_PROCESS_ATTACH) + { + DisableThreadLibraryCalls(hModule); + + if (Load() && Init()) + { + TCHAR szAppName[MAX_PATH] = TEXT("vmware-vmx.exe"); + TCHAR szCurName[MAX_PATH]; + + GetModuleFileName(NULL, szCurName, MAX_PATH); + PathStripPath(szCurName); + + if (StrCmpI(szCurName, szAppName) == 0) + { + // Go! + HANDLE hThread = CreateThread(NULL, NULL, ThreadProc, NULL, NULL, NULL); + if (hThread) + { + CloseHandle(hThread); + } + } + } + } + else if (dwReason == DLL_PROCESS_DETACH) + { + Free(); + } + + return TRUE; +} diff --git a/framework.h b/framework.h new file mode 100644 index 0000000..3e952c4 --- /dev/null +++ b/framework.h @@ -0,0 +1,4 @@ +#pragma once + +#include +#include diff --git a/pch.cpp b/pch.cpp new file mode 100644 index 0000000..b6fb8f4 --- /dev/null +++ b/pch.cpp @@ -0,0 +1,5 @@ +// pch.cpp: 与预编译标头对应的源文件 + +#include "pch.h" + +// 当使用预编译的头时,需要使用此源文件,编译才能成功。 diff --git a/pch.h b/pch.h new file mode 100644 index 0000000..9660927 --- /dev/null +++ b/pch.h @@ -0,0 +1,13 @@ +// pch.h: 这是预编译标头文件。 +// 下方列出的文件仅编译一次,提高了将来生成的生成性能。 +// 这还将影响 IntelliSense 性能,包括代码完成和许多代码浏览功能。 +// 但是,如果此处列出的文件中的任何一个在生成之间有更新,它们全部都将被重新编译。 +// 请勿在此处添加要频繁更新的文件,这将使得性能优势无效。 + +#ifndef PCH_H +#define PCH_H + +// 添加要在此处预编译的标头 +#include "framework.h" + +#endif //PCH_H diff --git a/winmm_jump.asm b/winmm_jump.asm new file mode 100644 index 0000000..b76b5e4 --- /dev/null +++ b/winmm_jump.asm @@ -0,0 +1,927 @@ + +; +; created by AheadLib +; github:https://github.com/strivexjun/AheadLib-x86-x64 +; +; 把 .asm 文件添加到工程一次 +; 右键单击文件-属性-常规- +; 项类型:自定义生成工具 +; 从生成中排除:否 + +; 然后复制下面命令填入 +; 命令行: ml64 /Fo $(IntDir)%(fileName).obj /c /Cp %(fileName).asm +; 输出: $(IntDir)%(fileName).obj;%(Outputs) +; 链接对象: 是 +; + + +.DATA +EXTERN pfnAheadLib_Unnamed2:dq; +EXTERN pfnAheadLib_mciExecute:dq; +EXTERN pfnAheadLib_CloseDriver:dq; +EXTERN pfnAheadLib_DefDriverProc:dq; +EXTERN pfnAheadLib_DriverCallback:dq; +EXTERN pfnAheadLib_DrvGetModuleHandle:dq; +EXTERN pfnAheadLib_GetDriverModuleHandle:dq; +EXTERN pfnAheadLib_OpenDriver:dq; +EXTERN pfnAheadLib_PlaySound:dq; +EXTERN pfnAheadLib_PlaySoundA:dq; +EXTERN pfnAheadLib_PlaySoundW:dq; +EXTERN pfnAheadLib_SendDriverMessage:dq; +EXTERN pfnAheadLib_WOWAppExit:dq; +EXTERN pfnAheadLib_auxGetDevCapsA:dq; +EXTERN pfnAheadLib_auxGetDevCapsW:dq; +EXTERN pfnAheadLib_auxGetNumDevs:dq; +EXTERN pfnAheadLib_auxGetVolume:dq; +EXTERN pfnAheadLib_auxOutMessage:dq; +EXTERN pfnAheadLib_auxSetVolume:dq; +EXTERN pfnAheadLib_joyConfigChanged:dq; +EXTERN pfnAheadLib_joyGetDevCapsA:dq; +EXTERN pfnAheadLib_joyGetDevCapsW:dq; +EXTERN pfnAheadLib_joyGetNumDevs:dq; +EXTERN pfnAheadLib_joyGetPos:dq; +EXTERN pfnAheadLib_joyGetPosEx:dq; +EXTERN pfnAheadLib_joyGetThreshold:dq; +EXTERN pfnAheadLib_joyReleaseCapture:dq; +EXTERN pfnAheadLib_joySetCapture:dq; +EXTERN pfnAheadLib_joySetThreshold:dq; +EXTERN pfnAheadLib_mciDriverNotify:dq; +EXTERN pfnAheadLib_mciDriverYield:dq; +EXTERN pfnAheadLib_mciFreeCommandResource:dq; +EXTERN pfnAheadLib_mciGetCreatorTask:dq; +EXTERN pfnAheadLib_mciGetDeviceIDA:dq; +EXTERN pfnAheadLib_mciGetDeviceIDFromElementIDA:dq; +EXTERN pfnAheadLib_mciGetDeviceIDFromElementIDW:dq; +EXTERN pfnAheadLib_mciGetDeviceIDW:dq; +EXTERN pfnAheadLib_mciGetDriverData:dq; +EXTERN pfnAheadLib_mciGetErrorStringA:dq; +EXTERN pfnAheadLib_mciGetErrorStringW:dq; +EXTERN pfnAheadLib_mciGetYieldProc:dq; +EXTERN pfnAheadLib_mciLoadCommandResource:dq; +EXTERN pfnAheadLib_mciSendCommandA:dq; +EXTERN pfnAheadLib_mciSendCommandW:dq; +EXTERN pfnAheadLib_mciSendStringA:dq; +EXTERN pfnAheadLib_mciSendStringW:dq; +EXTERN pfnAheadLib_mciSetDriverData:dq; +EXTERN pfnAheadLib_mciSetYieldProc:dq; +EXTERN pfnAheadLib_midiConnect:dq; +EXTERN pfnAheadLib_midiDisconnect:dq; +EXTERN pfnAheadLib_midiInAddBuffer:dq; +EXTERN pfnAheadLib_midiInClose:dq; +EXTERN pfnAheadLib_midiInGetDevCapsA:dq; +EXTERN pfnAheadLib_midiInGetDevCapsW:dq; +EXTERN pfnAheadLib_midiInGetErrorTextA:dq; +EXTERN pfnAheadLib_midiInGetErrorTextW:dq; +EXTERN pfnAheadLib_midiInGetID:dq; +EXTERN pfnAheadLib_midiInGetNumDevs:dq; +EXTERN pfnAheadLib_midiInMessage:dq; +EXTERN pfnAheadLib_midiInOpen:dq; +EXTERN pfnAheadLib_midiInPrepareHeader:dq; +EXTERN pfnAheadLib_midiInReset:dq; +EXTERN pfnAheadLib_midiInStart:dq; +EXTERN pfnAheadLib_midiInStop:dq; +EXTERN pfnAheadLib_midiInUnprepareHeader:dq; +EXTERN pfnAheadLib_midiOutCacheDrumPatches:dq; +EXTERN pfnAheadLib_midiOutCachePatches:dq; +EXTERN pfnAheadLib_midiOutClose:dq; +EXTERN pfnAheadLib_midiOutGetDevCapsA:dq; +EXTERN pfnAheadLib_midiOutGetDevCapsW:dq; +EXTERN pfnAheadLib_midiOutGetErrorTextA:dq; +EXTERN pfnAheadLib_midiOutGetErrorTextW:dq; +EXTERN pfnAheadLib_midiOutGetID:dq; +EXTERN pfnAheadLib_midiOutGetNumDevs:dq; +EXTERN pfnAheadLib_midiOutGetVolume:dq; +EXTERN pfnAheadLib_midiOutLongMsg:dq; +EXTERN pfnAheadLib_midiOutMessage:dq; +EXTERN pfnAheadLib_midiOutOpen:dq; +EXTERN pfnAheadLib_midiOutPrepareHeader:dq; +EXTERN pfnAheadLib_midiOutReset:dq; +EXTERN pfnAheadLib_midiOutSetVolume:dq; +EXTERN pfnAheadLib_midiOutShortMsg:dq; +EXTERN pfnAheadLib_midiOutUnprepareHeader:dq; +EXTERN pfnAheadLib_midiStreamClose:dq; +EXTERN pfnAheadLib_midiStreamOpen:dq; +EXTERN pfnAheadLib_midiStreamOut:dq; +EXTERN pfnAheadLib_midiStreamPause:dq; +EXTERN pfnAheadLib_midiStreamPosition:dq; +EXTERN pfnAheadLib_midiStreamProperty:dq; +EXTERN pfnAheadLib_midiStreamRestart:dq; +EXTERN pfnAheadLib_midiStreamStop:dq; +EXTERN pfnAheadLib_mixerClose:dq; +EXTERN pfnAheadLib_mixerGetControlDetailsA:dq; +EXTERN pfnAheadLib_mixerGetControlDetailsW:dq; +EXTERN pfnAheadLib_mixerGetDevCapsA:dq; +EXTERN pfnAheadLib_mixerGetDevCapsW:dq; +EXTERN pfnAheadLib_mixerGetID:dq; +EXTERN pfnAheadLib_mixerGetLineControlsA:dq; +EXTERN pfnAheadLib_mixerGetLineControlsW:dq; +EXTERN pfnAheadLib_mixerGetLineInfoA:dq; +EXTERN pfnAheadLib_mixerGetLineInfoW:dq; +EXTERN pfnAheadLib_mixerGetNumDevs:dq; +EXTERN pfnAheadLib_mixerMessage:dq; +EXTERN pfnAheadLib_mixerOpen:dq; +EXTERN pfnAheadLib_mixerSetControlDetails:dq; +EXTERN pfnAheadLib_mmDrvInstall:dq; +EXTERN pfnAheadLib_mmGetCurrentTask:dq; +EXTERN pfnAheadLib_mmTaskBlock:dq; +EXTERN pfnAheadLib_mmTaskCreate:dq; +EXTERN pfnAheadLib_mmTaskSignal:dq; +EXTERN pfnAheadLib_mmTaskYield:dq; +EXTERN pfnAheadLib_mmioAdvance:dq; +EXTERN pfnAheadLib_mmioAscend:dq; +EXTERN pfnAheadLib_mmioClose:dq; +EXTERN pfnAheadLib_mmioCreateChunk:dq; +EXTERN pfnAheadLib_mmioDescend:dq; +EXTERN pfnAheadLib_mmioFlush:dq; +EXTERN pfnAheadLib_mmioGetInfo:dq; +EXTERN pfnAheadLib_mmioInstallIOProcA:dq; +EXTERN pfnAheadLib_mmioInstallIOProcW:dq; +EXTERN pfnAheadLib_mmioOpenA:dq; +EXTERN pfnAheadLib_mmioOpenW:dq; +EXTERN pfnAheadLib_mmioRead:dq; +EXTERN pfnAheadLib_mmioRenameA:dq; +EXTERN pfnAheadLib_mmioRenameW:dq; +EXTERN pfnAheadLib_mmioSeek:dq; +EXTERN pfnAheadLib_mmioSendMessage:dq; +EXTERN pfnAheadLib_mmioSetBuffer:dq; +EXTERN pfnAheadLib_mmioSetInfo:dq; +EXTERN pfnAheadLib_mmioStringToFOURCCA:dq; +EXTERN pfnAheadLib_mmioStringToFOURCCW:dq; +EXTERN pfnAheadLib_mmioWrite:dq; +EXTERN pfnAheadLib_mmsystemGetVersion:dq; +EXTERN pfnAheadLib_sndPlaySoundA:dq; +EXTERN pfnAheadLib_sndPlaySoundW:dq; +EXTERN pfnAheadLib_timeBeginPeriod:dq; +EXTERN pfnAheadLib_timeEndPeriod:dq; +EXTERN pfnAheadLib_timeGetDevCaps:dq; +EXTERN pfnAheadLib_timeGetSystemTime:dq; +EXTERN pfnAheadLib_timeGetTime:dq; +EXTERN pfnAheadLib_timeKillEvent:dq; +EXTERN pfnAheadLib_timeSetEvent:dq; +EXTERN pfnAheadLib_waveInAddBuffer:dq; +EXTERN pfnAheadLib_waveInClose:dq; +EXTERN pfnAheadLib_waveInGetDevCapsA:dq; +EXTERN pfnAheadLib_waveInGetDevCapsW:dq; +EXTERN pfnAheadLib_waveInGetErrorTextA:dq; +EXTERN pfnAheadLib_waveInGetErrorTextW:dq; +EXTERN pfnAheadLib_waveInGetID:dq; +EXTERN pfnAheadLib_waveInGetNumDevs:dq; +EXTERN pfnAheadLib_waveInGetPosition:dq; +EXTERN pfnAheadLib_waveInMessage:dq; +EXTERN pfnAheadLib_waveInOpen:dq; +EXTERN pfnAheadLib_waveInPrepareHeader:dq; +EXTERN pfnAheadLib_waveInReset:dq; +EXTERN pfnAheadLib_waveInStart:dq; +EXTERN pfnAheadLib_waveInStop:dq; +EXTERN pfnAheadLib_waveInUnprepareHeader:dq; +EXTERN pfnAheadLib_waveOutBreakLoop:dq; +EXTERN pfnAheadLib_waveOutClose:dq; +EXTERN pfnAheadLib_waveOutGetDevCapsA:dq; +EXTERN pfnAheadLib_waveOutGetDevCapsW:dq; +EXTERN pfnAheadLib_waveOutGetErrorTextA:dq; +EXTERN pfnAheadLib_waveOutGetErrorTextW:dq; +EXTERN pfnAheadLib_waveOutGetID:dq; +EXTERN pfnAheadLib_waveOutGetNumDevs:dq; +EXTERN pfnAheadLib_waveOutGetPitch:dq; +EXTERN pfnAheadLib_waveOutGetPlaybackRate:dq; +EXTERN pfnAheadLib_waveOutGetPosition:dq; +EXTERN pfnAheadLib_waveOutGetVolume:dq; +EXTERN pfnAheadLib_waveOutMessage:dq; +EXTERN pfnAheadLib_waveOutOpen:dq; +EXTERN pfnAheadLib_waveOutPause:dq; +EXTERN pfnAheadLib_waveOutPrepareHeader:dq; +EXTERN pfnAheadLib_waveOutReset:dq; +EXTERN pfnAheadLib_waveOutRestart:dq; +EXTERN pfnAheadLib_waveOutSetPitch:dq; +EXTERN pfnAheadLib_waveOutSetPlaybackRate:dq; +EXTERN pfnAheadLib_waveOutSetVolume:dq; +EXTERN pfnAheadLib_waveOutUnprepareHeader:dq; +EXTERN pfnAheadLib_waveOutWrite:dq; + +.CODE +AheadLib_Unnamed2 PROC + jmp pfnAheadLib_Unnamed2 +AheadLib_Unnamed2 ENDP + +AheadLib_mciExecute PROC + jmp pfnAheadLib_mciExecute +AheadLib_mciExecute ENDP + +AheadLib_CloseDriver PROC + jmp pfnAheadLib_CloseDriver +AheadLib_CloseDriver ENDP + +AheadLib_DefDriverProc PROC + jmp pfnAheadLib_DefDriverProc +AheadLib_DefDriverProc ENDP + +AheadLib_DriverCallback PROC + jmp pfnAheadLib_DriverCallback +AheadLib_DriverCallback ENDP + +AheadLib_DrvGetModuleHandle PROC + jmp pfnAheadLib_DrvGetModuleHandle +AheadLib_DrvGetModuleHandle ENDP + +AheadLib_GetDriverModuleHandle PROC + jmp pfnAheadLib_GetDriverModuleHandle +AheadLib_GetDriverModuleHandle ENDP + +AheadLib_OpenDriver PROC + jmp pfnAheadLib_OpenDriver +AheadLib_OpenDriver ENDP + +AheadLib_PlaySound PROC + jmp pfnAheadLib_PlaySound +AheadLib_PlaySound ENDP + +AheadLib_PlaySoundA PROC + jmp pfnAheadLib_PlaySoundA +AheadLib_PlaySoundA ENDP + +AheadLib_PlaySoundW PROC + jmp pfnAheadLib_PlaySoundW +AheadLib_PlaySoundW ENDP + +AheadLib_SendDriverMessage PROC + jmp pfnAheadLib_SendDriverMessage +AheadLib_SendDriverMessage ENDP + +AheadLib_WOWAppExit PROC + jmp pfnAheadLib_WOWAppExit +AheadLib_WOWAppExit ENDP + +AheadLib_auxGetDevCapsA PROC + jmp pfnAheadLib_auxGetDevCapsA +AheadLib_auxGetDevCapsA ENDP + +AheadLib_auxGetDevCapsW PROC + jmp pfnAheadLib_auxGetDevCapsW +AheadLib_auxGetDevCapsW ENDP + +AheadLib_auxGetNumDevs PROC + jmp pfnAheadLib_auxGetNumDevs +AheadLib_auxGetNumDevs ENDP + +AheadLib_auxGetVolume PROC + jmp pfnAheadLib_auxGetVolume +AheadLib_auxGetVolume ENDP + +AheadLib_auxOutMessage PROC + jmp pfnAheadLib_auxOutMessage +AheadLib_auxOutMessage ENDP + +AheadLib_auxSetVolume PROC + jmp pfnAheadLib_auxSetVolume +AheadLib_auxSetVolume ENDP + +AheadLib_joyConfigChanged PROC + jmp pfnAheadLib_joyConfigChanged +AheadLib_joyConfigChanged ENDP + +AheadLib_joyGetDevCapsA PROC + jmp pfnAheadLib_joyGetDevCapsA +AheadLib_joyGetDevCapsA ENDP + +AheadLib_joyGetDevCapsW PROC + jmp pfnAheadLib_joyGetDevCapsW +AheadLib_joyGetDevCapsW ENDP + +AheadLib_joyGetNumDevs PROC + jmp pfnAheadLib_joyGetNumDevs +AheadLib_joyGetNumDevs ENDP + +AheadLib_joyGetPos PROC + jmp pfnAheadLib_joyGetPos +AheadLib_joyGetPos ENDP + +AheadLib_joyGetPosEx PROC + jmp pfnAheadLib_joyGetPosEx +AheadLib_joyGetPosEx ENDP + +AheadLib_joyGetThreshold PROC + jmp pfnAheadLib_joyGetThreshold +AheadLib_joyGetThreshold ENDP + +AheadLib_joyReleaseCapture PROC + jmp pfnAheadLib_joyReleaseCapture +AheadLib_joyReleaseCapture ENDP + +AheadLib_joySetCapture PROC + jmp pfnAheadLib_joySetCapture +AheadLib_joySetCapture ENDP + +AheadLib_joySetThreshold PROC + jmp pfnAheadLib_joySetThreshold +AheadLib_joySetThreshold ENDP + +AheadLib_mciDriverNotify PROC + jmp pfnAheadLib_mciDriverNotify +AheadLib_mciDriverNotify ENDP + +AheadLib_mciDriverYield PROC + jmp pfnAheadLib_mciDriverYield +AheadLib_mciDriverYield ENDP + +AheadLib_mciFreeCommandResource PROC + jmp pfnAheadLib_mciFreeCommandResource +AheadLib_mciFreeCommandResource ENDP + +AheadLib_mciGetCreatorTask PROC + jmp pfnAheadLib_mciGetCreatorTask +AheadLib_mciGetCreatorTask ENDP + +AheadLib_mciGetDeviceIDA PROC + jmp pfnAheadLib_mciGetDeviceIDA +AheadLib_mciGetDeviceIDA ENDP + +AheadLib_mciGetDeviceIDFromElementIDA PROC + jmp pfnAheadLib_mciGetDeviceIDFromElementIDA +AheadLib_mciGetDeviceIDFromElementIDA ENDP + +AheadLib_mciGetDeviceIDFromElementIDW PROC + jmp pfnAheadLib_mciGetDeviceIDFromElementIDW +AheadLib_mciGetDeviceIDFromElementIDW ENDP + +AheadLib_mciGetDeviceIDW PROC + jmp pfnAheadLib_mciGetDeviceIDW +AheadLib_mciGetDeviceIDW ENDP + +AheadLib_mciGetDriverData PROC + jmp pfnAheadLib_mciGetDriverData +AheadLib_mciGetDriverData ENDP + +AheadLib_mciGetErrorStringA PROC + jmp pfnAheadLib_mciGetErrorStringA +AheadLib_mciGetErrorStringA ENDP + +AheadLib_mciGetErrorStringW PROC + jmp pfnAheadLib_mciGetErrorStringW +AheadLib_mciGetErrorStringW ENDP + +AheadLib_mciGetYieldProc PROC + jmp pfnAheadLib_mciGetYieldProc +AheadLib_mciGetYieldProc ENDP + +AheadLib_mciLoadCommandResource PROC + jmp pfnAheadLib_mciLoadCommandResource +AheadLib_mciLoadCommandResource ENDP + +AheadLib_mciSendCommandA PROC + jmp pfnAheadLib_mciSendCommandA +AheadLib_mciSendCommandA ENDP + +AheadLib_mciSendCommandW PROC + jmp pfnAheadLib_mciSendCommandW +AheadLib_mciSendCommandW ENDP + +AheadLib_mciSendStringA PROC + jmp pfnAheadLib_mciSendStringA +AheadLib_mciSendStringA ENDP + +AheadLib_mciSendStringW PROC + jmp pfnAheadLib_mciSendStringW +AheadLib_mciSendStringW ENDP + +AheadLib_mciSetDriverData PROC + jmp pfnAheadLib_mciSetDriverData +AheadLib_mciSetDriverData ENDP + +AheadLib_mciSetYieldProc PROC + jmp pfnAheadLib_mciSetYieldProc +AheadLib_mciSetYieldProc ENDP + +AheadLib_midiConnect PROC + jmp pfnAheadLib_midiConnect +AheadLib_midiConnect ENDP + +AheadLib_midiDisconnect PROC + jmp pfnAheadLib_midiDisconnect +AheadLib_midiDisconnect ENDP + +AheadLib_midiInAddBuffer PROC + jmp pfnAheadLib_midiInAddBuffer +AheadLib_midiInAddBuffer ENDP + +AheadLib_midiInClose PROC + jmp pfnAheadLib_midiInClose +AheadLib_midiInClose ENDP + +AheadLib_midiInGetDevCapsA PROC + jmp pfnAheadLib_midiInGetDevCapsA +AheadLib_midiInGetDevCapsA ENDP + +AheadLib_midiInGetDevCapsW PROC + jmp pfnAheadLib_midiInGetDevCapsW +AheadLib_midiInGetDevCapsW ENDP + +AheadLib_midiInGetErrorTextA PROC + jmp pfnAheadLib_midiInGetErrorTextA +AheadLib_midiInGetErrorTextA ENDP + +AheadLib_midiInGetErrorTextW PROC + jmp pfnAheadLib_midiInGetErrorTextW +AheadLib_midiInGetErrorTextW ENDP + +AheadLib_midiInGetID PROC + jmp pfnAheadLib_midiInGetID +AheadLib_midiInGetID ENDP + +AheadLib_midiInGetNumDevs PROC + jmp pfnAheadLib_midiInGetNumDevs +AheadLib_midiInGetNumDevs ENDP + +AheadLib_midiInMessage PROC + jmp pfnAheadLib_midiInMessage +AheadLib_midiInMessage ENDP + +AheadLib_midiInOpen PROC + jmp pfnAheadLib_midiInOpen +AheadLib_midiInOpen ENDP + +AheadLib_midiInPrepareHeader PROC + jmp pfnAheadLib_midiInPrepareHeader +AheadLib_midiInPrepareHeader ENDP + +AheadLib_midiInReset PROC + jmp pfnAheadLib_midiInReset +AheadLib_midiInReset ENDP + +AheadLib_midiInStart PROC + jmp pfnAheadLib_midiInStart +AheadLib_midiInStart ENDP + +AheadLib_midiInStop PROC + jmp pfnAheadLib_midiInStop +AheadLib_midiInStop ENDP + +AheadLib_midiInUnprepareHeader PROC + jmp pfnAheadLib_midiInUnprepareHeader +AheadLib_midiInUnprepareHeader ENDP + +AheadLib_midiOutCacheDrumPatches PROC + jmp pfnAheadLib_midiOutCacheDrumPatches +AheadLib_midiOutCacheDrumPatches ENDP + +AheadLib_midiOutCachePatches PROC + jmp pfnAheadLib_midiOutCachePatches +AheadLib_midiOutCachePatches ENDP + +AheadLib_midiOutClose PROC + jmp pfnAheadLib_midiOutClose +AheadLib_midiOutClose ENDP + +AheadLib_midiOutGetDevCapsA PROC + jmp pfnAheadLib_midiOutGetDevCapsA +AheadLib_midiOutGetDevCapsA ENDP + +AheadLib_midiOutGetDevCapsW PROC + jmp pfnAheadLib_midiOutGetDevCapsW +AheadLib_midiOutGetDevCapsW ENDP + +AheadLib_midiOutGetErrorTextA PROC + jmp pfnAheadLib_midiOutGetErrorTextA +AheadLib_midiOutGetErrorTextA ENDP + +AheadLib_midiOutGetErrorTextW PROC + jmp pfnAheadLib_midiOutGetErrorTextW +AheadLib_midiOutGetErrorTextW ENDP + +AheadLib_midiOutGetID PROC + jmp pfnAheadLib_midiOutGetID +AheadLib_midiOutGetID ENDP + +AheadLib_midiOutGetNumDevs PROC + jmp pfnAheadLib_midiOutGetNumDevs +AheadLib_midiOutGetNumDevs ENDP + +AheadLib_midiOutGetVolume PROC + jmp pfnAheadLib_midiOutGetVolume +AheadLib_midiOutGetVolume ENDP + +AheadLib_midiOutLongMsg PROC + jmp pfnAheadLib_midiOutLongMsg +AheadLib_midiOutLongMsg ENDP + +AheadLib_midiOutMessage PROC + jmp pfnAheadLib_midiOutMessage +AheadLib_midiOutMessage ENDP + +AheadLib_midiOutOpen PROC + jmp pfnAheadLib_midiOutOpen +AheadLib_midiOutOpen ENDP + +AheadLib_midiOutPrepareHeader PROC + jmp pfnAheadLib_midiOutPrepareHeader +AheadLib_midiOutPrepareHeader ENDP + +AheadLib_midiOutReset PROC + jmp pfnAheadLib_midiOutReset +AheadLib_midiOutReset ENDP + +AheadLib_midiOutSetVolume PROC + jmp pfnAheadLib_midiOutSetVolume +AheadLib_midiOutSetVolume ENDP + +AheadLib_midiOutShortMsg PROC + jmp pfnAheadLib_midiOutShortMsg +AheadLib_midiOutShortMsg ENDP + +AheadLib_midiOutUnprepareHeader PROC + jmp pfnAheadLib_midiOutUnprepareHeader +AheadLib_midiOutUnprepareHeader ENDP + +AheadLib_midiStreamClose PROC + jmp pfnAheadLib_midiStreamClose +AheadLib_midiStreamClose ENDP + +AheadLib_midiStreamOpen PROC + jmp pfnAheadLib_midiStreamOpen +AheadLib_midiStreamOpen ENDP + +AheadLib_midiStreamOut PROC + jmp pfnAheadLib_midiStreamOut +AheadLib_midiStreamOut ENDP + +AheadLib_midiStreamPause PROC + jmp pfnAheadLib_midiStreamPause +AheadLib_midiStreamPause ENDP + +AheadLib_midiStreamPosition PROC + jmp pfnAheadLib_midiStreamPosition +AheadLib_midiStreamPosition ENDP + +AheadLib_midiStreamProperty PROC + jmp pfnAheadLib_midiStreamProperty +AheadLib_midiStreamProperty ENDP + +AheadLib_midiStreamRestart PROC + jmp pfnAheadLib_midiStreamRestart +AheadLib_midiStreamRestart ENDP + +AheadLib_midiStreamStop PROC + jmp pfnAheadLib_midiStreamStop +AheadLib_midiStreamStop ENDP + +AheadLib_mixerClose PROC + jmp pfnAheadLib_mixerClose +AheadLib_mixerClose ENDP + +AheadLib_mixerGetControlDetailsA PROC + jmp pfnAheadLib_mixerGetControlDetailsA +AheadLib_mixerGetControlDetailsA ENDP + +AheadLib_mixerGetControlDetailsW PROC + jmp pfnAheadLib_mixerGetControlDetailsW +AheadLib_mixerGetControlDetailsW ENDP + +AheadLib_mixerGetDevCapsA PROC + jmp pfnAheadLib_mixerGetDevCapsA +AheadLib_mixerGetDevCapsA ENDP + +AheadLib_mixerGetDevCapsW PROC + jmp pfnAheadLib_mixerGetDevCapsW +AheadLib_mixerGetDevCapsW ENDP + +AheadLib_mixerGetID PROC + jmp pfnAheadLib_mixerGetID +AheadLib_mixerGetID ENDP + +AheadLib_mixerGetLineControlsA PROC + jmp pfnAheadLib_mixerGetLineControlsA +AheadLib_mixerGetLineControlsA ENDP + +AheadLib_mixerGetLineControlsW PROC + jmp pfnAheadLib_mixerGetLineControlsW +AheadLib_mixerGetLineControlsW ENDP + +AheadLib_mixerGetLineInfoA PROC + jmp pfnAheadLib_mixerGetLineInfoA +AheadLib_mixerGetLineInfoA ENDP + +AheadLib_mixerGetLineInfoW PROC + jmp pfnAheadLib_mixerGetLineInfoW +AheadLib_mixerGetLineInfoW ENDP + +AheadLib_mixerGetNumDevs PROC + jmp pfnAheadLib_mixerGetNumDevs +AheadLib_mixerGetNumDevs ENDP + +AheadLib_mixerMessage PROC + jmp pfnAheadLib_mixerMessage +AheadLib_mixerMessage ENDP + +AheadLib_mixerOpen PROC + jmp pfnAheadLib_mixerOpen +AheadLib_mixerOpen ENDP + +AheadLib_mixerSetControlDetails PROC + jmp pfnAheadLib_mixerSetControlDetails +AheadLib_mixerSetControlDetails ENDP + +AheadLib_mmDrvInstall PROC + jmp pfnAheadLib_mmDrvInstall +AheadLib_mmDrvInstall ENDP + +AheadLib_mmGetCurrentTask PROC + jmp pfnAheadLib_mmGetCurrentTask +AheadLib_mmGetCurrentTask ENDP + +AheadLib_mmTaskBlock PROC + jmp pfnAheadLib_mmTaskBlock +AheadLib_mmTaskBlock ENDP + +AheadLib_mmTaskCreate PROC + jmp pfnAheadLib_mmTaskCreate +AheadLib_mmTaskCreate ENDP + +AheadLib_mmTaskSignal PROC + jmp pfnAheadLib_mmTaskSignal +AheadLib_mmTaskSignal ENDP + +AheadLib_mmTaskYield PROC + jmp pfnAheadLib_mmTaskYield +AheadLib_mmTaskYield ENDP + +AheadLib_mmioAdvance PROC + jmp pfnAheadLib_mmioAdvance +AheadLib_mmioAdvance ENDP + +AheadLib_mmioAscend PROC + jmp pfnAheadLib_mmioAscend +AheadLib_mmioAscend ENDP + +AheadLib_mmioClose PROC + jmp pfnAheadLib_mmioClose +AheadLib_mmioClose ENDP + +AheadLib_mmioCreateChunk PROC + jmp pfnAheadLib_mmioCreateChunk +AheadLib_mmioCreateChunk ENDP + +AheadLib_mmioDescend PROC + jmp pfnAheadLib_mmioDescend +AheadLib_mmioDescend ENDP + +AheadLib_mmioFlush PROC + jmp pfnAheadLib_mmioFlush +AheadLib_mmioFlush ENDP + +AheadLib_mmioGetInfo PROC + jmp pfnAheadLib_mmioGetInfo +AheadLib_mmioGetInfo ENDP + +AheadLib_mmioInstallIOProcA PROC + jmp pfnAheadLib_mmioInstallIOProcA +AheadLib_mmioInstallIOProcA ENDP + +AheadLib_mmioInstallIOProcW PROC + jmp pfnAheadLib_mmioInstallIOProcW +AheadLib_mmioInstallIOProcW ENDP + +AheadLib_mmioOpenA PROC + jmp pfnAheadLib_mmioOpenA +AheadLib_mmioOpenA ENDP + +AheadLib_mmioOpenW PROC + jmp pfnAheadLib_mmioOpenW +AheadLib_mmioOpenW ENDP + +AheadLib_mmioRead PROC + jmp pfnAheadLib_mmioRead +AheadLib_mmioRead ENDP + +AheadLib_mmioRenameA PROC + jmp pfnAheadLib_mmioRenameA +AheadLib_mmioRenameA ENDP + +AheadLib_mmioRenameW PROC + jmp pfnAheadLib_mmioRenameW +AheadLib_mmioRenameW ENDP + +AheadLib_mmioSeek PROC + jmp pfnAheadLib_mmioSeek +AheadLib_mmioSeek ENDP + +AheadLib_mmioSendMessage PROC + jmp pfnAheadLib_mmioSendMessage +AheadLib_mmioSendMessage ENDP + +AheadLib_mmioSetBuffer PROC + jmp pfnAheadLib_mmioSetBuffer +AheadLib_mmioSetBuffer ENDP + +AheadLib_mmioSetInfo PROC + jmp pfnAheadLib_mmioSetInfo +AheadLib_mmioSetInfo ENDP + +AheadLib_mmioStringToFOURCCA PROC + jmp pfnAheadLib_mmioStringToFOURCCA +AheadLib_mmioStringToFOURCCA ENDP + +AheadLib_mmioStringToFOURCCW PROC + jmp pfnAheadLib_mmioStringToFOURCCW +AheadLib_mmioStringToFOURCCW ENDP + +AheadLib_mmioWrite PROC + jmp pfnAheadLib_mmioWrite +AheadLib_mmioWrite ENDP + +AheadLib_mmsystemGetVersion PROC + jmp pfnAheadLib_mmsystemGetVersion +AheadLib_mmsystemGetVersion ENDP + +AheadLib_sndPlaySoundA PROC + jmp pfnAheadLib_sndPlaySoundA +AheadLib_sndPlaySoundA ENDP + +AheadLib_sndPlaySoundW PROC + jmp pfnAheadLib_sndPlaySoundW +AheadLib_sndPlaySoundW ENDP + +AheadLib_timeBeginPeriod PROC + jmp pfnAheadLib_timeBeginPeriod +AheadLib_timeBeginPeriod ENDP + +AheadLib_timeEndPeriod PROC + jmp pfnAheadLib_timeEndPeriod +AheadLib_timeEndPeriod ENDP + +AheadLib_timeGetDevCaps PROC + jmp pfnAheadLib_timeGetDevCaps +AheadLib_timeGetDevCaps ENDP + +AheadLib_timeGetSystemTime PROC + jmp pfnAheadLib_timeGetSystemTime +AheadLib_timeGetSystemTime ENDP + +AheadLib_timeGetTime PROC + jmp pfnAheadLib_timeGetTime +AheadLib_timeGetTime ENDP + +AheadLib_timeKillEvent PROC + jmp pfnAheadLib_timeKillEvent +AheadLib_timeKillEvent ENDP + +AheadLib_timeSetEvent PROC + jmp pfnAheadLib_timeSetEvent +AheadLib_timeSetEvent ENDP + +AheadLib_waveInAddBuffer PROC + jmp pfnAheadLib_waveInAddBuffer +AheadLib_waveInAddBuffer ENDP + +AheadLib_waveInClose PROC + jmp pfnAheadLib_waveInClose +AheadLib_waveInClose ENDP + +AheadLib_waveInGetDevCapsA PROC + jmp pfnAheadLib_waveInGetDevCapsA +AheadLib_waveInGetDevCapsA ENDP + +AheadLib_waveInGetDevCapsW PROC + jmp pfnAheadLib_waveInGetDevCapsW +AheadLib_waveInGetDevCapsW ENDP + +AheadLib_waveInGetErrorTextA PROC + jmp pfnAheadLib_waveInGetErrorTextA +AheadLib_waveInGetErrorTextA ENDP + +AheadLib_waveInGetErrorTextW PROC + jmp pfnAheadLib_waveInGetErrorTextW +AheadLib_waveInGetErrorTextW ENDP + +AheadLib_waveInGetID PROC + jmp pfnAheadLib_waveInGetID +AheadLib_waveInGetID ENDP + +AheadLib_waveInGetNumDevs PROC + jmp pfnAheadLib_waveInGetNumDevs +AheadLib_waveInGetNumDevs ENDP + +AheadLib_waveInGetPosition PROC + jmp pfnAheadLib_waveInGetPosition +AheadLib_waveInGetPosition ENDP + +AheadLib_waveInMessage PROC + jmp pfnAheadLib_waveInMessage +AheadLib_waveInMessage ENDP + +AheadLib_waveInOpen PROC + jmp pfnAheadLib_waveInOpen +AheadLib_waveInOpen ENDP + +AheadLib_waveInPrepareHeader PROC + jmp pfnAheadLib_waveInPrepareHeader +AheadLib_waveInPrepareHeader ENDP + +AheadLib_waveInReset PROC + jmp pfnAheadLib_waveInReset +AheadLib_waveInReset ENDP + +AheadLib_waveInStart PROC + jmp pfnAheadLib_waveInStart +AheadLib_waveInStart ENDP + +AheadLib_waveInStop PROC + jmp pfnAheadLib_waveInStop +AheadLib_waveInStop ENDP + +AheadLib_waveInUnprepareHeader PROC + jmp pfnAheadLib_waveInUnprepareHeader +AheadLib_waveInUnprepareHeader ENDP + +AheadLib_waveOutBreakLoop PROC + jmp pfnAheadLib_waveOutBreakLoop +AheadLib_waveOutBreakLoop ENDP + +AheadLib_waveOutClose PROC + jmp pfnAheadLib_waveOutClose +AheadLib_waveOutClose ENDP + +AheadLib_waveOutGetDevCapsA PROC + jmp pfnAheadLib_waveOutGetDevCapsA +AheadLib_waveOutGetDevCapsA ENDP + +AheadLib_waveOutGetDevCapsW PROC + jmp pfnAheadLib_waveOutGetDevCapsW +AheadLib_waveOutGetDevCapsW ENDP + +AheadLib_waveOutGetErrorTextA PROC + jmp pfnAheadLib_waveOutGetErrorTextA +AheadLib_waveOutGetErrorTextA ENDP + +AheadLib_waveOutGetErrorTextW PROC + jmp pfnAheadLib_waveOutGetErrorTextW +AheadLib_waveOutGetErrorTextW ENDP + +AheadLib_waveOutGetID PROC + jmp pfnAheadLib_waveOutGetID +AheadLib_waveOutGetID ENDP + +AheadLib_waveOutGetNumDevs PROC + jmp pfnAheadLib_waveOutGetNumDevs +AheadLib_waveOutGetNumDevs ENDP + +AheadLib_waveOutGetPitch PROC + jmp pfnAheadLib_waveOutGetPitch +AheadLib_waveOutGetPitch ENDP + +AheadLib_waveOutGetPlaybackRate PROC + jmp pfnAheadLib_waveOutGetPlaybackRate +AheadLib_waveOutGetPlaybackRate ENDP + +AheadLib_waveOutGetPosition PROC + jmp pfnAheadLib_waveOutGetPosition +AheadLib_waveOutGetPosition ENDP + +AheadLib_waveOutGetVolume PROC + jmp pfnAheadLib_waveOutGetVolume +AheadLib_waveOutGetVolume ENDP + +AheadLib_waveOutMessage PROC + jmp pfnAheadLib_waveOutMessage +AheadLib_waveOutMessage ENDP + +AheadLib_waveOutOpen PROC + jmp pfnAheadLib_waveOutOpen +AheadLib_waveOutOpen ENDP + +AheadLib_waveOutPause PROC + jmp pfnAheadLib_waveOutPause +AheadLib_waveOutPause ENDP + +AheadLib_waveOutPrepareHeader PROC + jmp pfnAheadLib_waveOutPrepareHeader +AheadLib_waveOutPrepareHeader ENDP + +AheadLib_waveOutReset PROC + jmp pfnAheadLib_waveOutReset +AheadLib_waveOutReset ENDP + +AheadLib_waveOutRestart PROC + jmp pfnAheadLib_waveOutRestart +AheadLib_waveOutRestart ENDP + +AheadLib_waveOutSetPitch PROC + jmp pfnAheadLib_waveOutSetPitch +AheadLib_waveOutSetPitch ENDP + +AheadLib_waveOutSetPlaybackRate PROC + jmp pfnAheadLib_waveOutSetPlaybackRate +AheadLib_waveOutSetPlaybackRate ENDP + +AheadLib_waveOutSetVolume PROC + jmp pfnAheadLib_waveOutSetVolume +AheadLib_waveOutSetVolume ENDP + +AheadLib_waveOutUnprepareHeader PROC + jmp pfnAheadLib_waveOutUnprepareHeader +AheadLib_waveOutUnprepareHeader ENDP + +AheadLib_waveOutWrite PROC + jmp pfnAheadLib_waveOutWrite +AheadLib_waveOutWrite ENDP + + +END