0% found this document useful (0 votes)
63 views

Chapter3 Multimedia - Programming Part2 PDF

The document discusses several programming languages used for multimedia development including C, C++, C#, Python, and Java. It provides details on the history and uses of each language, with C and C++ focusing on systems programming, and Python emphasizing rapid prototyping. The document also lists popular companies and industries that employ each language.

Uploaded by

mr nath
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
63 views

Chapter3 Multimedia - Programming Part2 PDF

The document discusses several programming languages used for multimedia development including C, C++, C#, Python, and Java. It provides details on the history and uses of each language, with C and C++ focusing on systems programming, and Python emphasizing rapid prototyping. The document also lists popular companies and industries that employ each language.

Uploaded by

mr nath
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 23

5/11/20

CHAPTER 3

MULTIMEDIA
PROGRAMMING
Part 2

Learning Outcomes
• At the end of this lecture, student should be able to:
• List several programming languages for multimedia application development
• Discuss multimedia support in programming languages

1
5/11/20

Topics
• Multimedia Programming Languages
• Multimedia Support in Programming Languages

2
5/11/20

Programming Languages
• Creates programming code
• Examples of languages:
• C
• C++
• C#
• Python
• Java
• …

3
5/11/20

Programming Languages

Fig 2: Most commonly used Programming, Scripting,


Fig 1: Top programming language (IEEE, 2019) and Markup Languages (Stackoverflow, 2019)

C
• C Language is a structure-oriented, middle-level programming language mostly
used to develop low-level applications.
• The C Language was developed by Dennis Ritchie in 1972 at Bell Labs specifically
for implementing the UNIX system.
• It eventually gave rise to many advanced programming languages, including C++,
Java, C#, JavaScript and Perl.
• Features:
• Simple to learn; there are only 32 keywords to master Dennis Ritchie
• Foundational language for beginners
• Easy to write systems programs such as compilers and interpreters

4
5/11/20

C
• C Language is used to develop systems applications that are integrated into operating systems
such as Windows, UNIX and Linux, as well as embedded software.
• Applications include graphics packages, word processors, spreadsheets, operating system
development, database systems, compilers and assemblers, network drivers and interpreters.
• Most device drivers are still developed using C Language.

C
WHO USES IT?
• Professions and Industries:
• Software developers, computer engineers, business and systems analysts, IT and Web content
administrators, embedded software engineers
• Used by employers in Information Technology, Engineering, Management, Healthcare and Professional
Services
• Major Organizations:
• Microsoft, Apple, Oracle, Cisco, etc.

• Specializations and Industries Where C Language is Used Most:


• Embedded Systems, Systems Programming, Artificial Intelligence, Industrial Automation, Computer
Graphics, Space Research, Image Processing and Game Programming

5
5/11/20

C++
• C++ is a general purpose, object-oriented, middle-level programming
language and is an extension of C language
• often considered an object-oriented version of C language
• in some situation programs written in C language can run in C++ compiler making C++
an example of a hybrid language

• 1983 Bell labs : created by Bjarne Stroustrup

• C++ was created to compile lean, efficient code, while providing high-level
abstractions
• to better manage large development projects

• known to be a very dominant language


• Used in a wide range of application domains
Bjarne Stroustrup

C++
• relatively high entry barrier (meaning it’s quite difficult to learn)
• allows a lot of control to computer resources
• more direct control over the hardware and graphical processes (very important in
game).
• its speed and ability to economically use resources able to surpass other
languages
• some game engines (such as Unreal) only accept information written in C++.
• If you only choose one language to learn, this would be it
• most other object-oriented languages stem from C++
• It is by far the most commonly used language for writing game engines, games,
and desktop apps
• E.g. computer programs and packaged software, office applications, graphics and video editors and
operating systems.

6
5/11/20

C++
WHO USES IT?
• Professions and Industries:
• C++ software engineers, C++ software developers, embedded engineers,
programmer analysts
• Used by employers in Information Technology, Engineering, Professional
Services, Design, Quality Control and Management
• Major Company and Organization Users:
• Microsoft, Google, Mozilla, Firefox, Adobe, Amazon, Lockheed Martin

• Specializations:
• System/Application Software, Drivers, Client-Server Applications,
Embedded Firmware

C#
• Pronounced C-sharp (not C-hashtag)
• C# is a multi-paradigm programming language
• features strong typing, imperative, declarative, functional, generic,
object-oriented and component-oriented disciplines.
• developed in 2002 by a group of Microsoft engineers lead by
Anders Hejlsberg in order to develop apps on the .NET platform.
• A great advantage of C# :
• its comparative simplicity
• the ability to focus on the algorithm more rather than the
implementation details.
• easy to understand for those who know C language
• uses an almost similar syntax which follows by C

7
5/11/20

C#
• helps developers create XML web services and Microsoft .NET-connected
applications for Windows operating systems and the Internet.
• Used to develop a wide range of software applications that accompany
Visual Studio IDE.
• The only language used by the Windows Presentation Foundation (WPF).
• Features:
• Ideal for beginners
• Easy Integration with Windows
• The go-to for working on Microsoft apps

C#
WHO USES IT?
• Professions and Industries:
• C# developers, automation test engineers, software engineers, .net Web
developers
• Used by employers in Information Technology, Engineering, Design,
Professional Services, Management and Quality Control

• Major Organizations:
• Microsoft, Intel, Hewlett Packard

• Specializations:
• Windows-based platforms

8
5/11/20

Python
• Python is an advanced programming language that is interpreted and object-
oriented language.
• built on flexible and robust semantics.
• Created by Guido van Rossum and released in 1991
• can be used as a scripting language as well as a customary object-oriented
language for a large project.
• It is used:
• on a server to create web applications.
• alongside software to create workflows.
• to connect to database systems. It can also read and modify files.
• to handle big data and perform complex mathematics.
• for rapid prototyping, or for production-ready software development. Guido van Rossum
• suited for Rapid Application Develop (RAD).

Python
• Advantages:
• works on different platforms (Windows, Mac, Linux, Raspberry Pi, etc).
• has a simple syntax similar to the English language.
• has syntax that allows developers to write programs with fewer lines than some
other programming languages.
• runs on an interpreter system, meaning that code can be executed as soon as it
is written.
• This means that prototyping can be very quick.
• can be treated in a procedural way, an object-orientated way or a functional
way.
• Python lets you work quickly to integrate systems as a scripting or glue
language.

9
5/11/20

Python
Python Syntax compared to other programming languages:
• was designed for readability
• some similarities to the English language with influence from
mathematics.
• uses new lines to complete a command, as opposed to other
programming languages which often use semicolons or
parentheses.
• relies on indentation, using whitespace, to define scope; such as
the scope of loops, functions and classes.
• Other programming languages often use curly-brackets for this
purpose.

Python
WHO USES IT?
• Professions and Industries:
• Python developers, software engineers, back end developers, Python
programmers
• Used by employers in information technology, engineering, professional services
and design
• Major Organizations:
• Google, Pinterest, Instagram, YouTube, DropBox, NASA, ESRI
• The game Civilization 4 has all its inner logic, including AI, implemented in Python.
• NASA uses Python in its Integrated Planning System as a standard scripting language.

• Specializations and Industries:


• Web and Internet development (frameworks, micro-frameworks and advanced
content management systems); scientific and numeric computing; desktop (GUIs)

10
5/11/20

Java
• Is an object-oriented, cross platform, multi-purpose programming language.
• Originally known as Oak, Java was developed in 1990 by James Gosling at Sun
Microsystems to add capabilities to the C++ language.
• Java was developed according to the principle of WORA (Write Once Run
Anywhere).
• The language was introduced to the public in 1995 and is now owned by
Oracle.
• developed to be a machine independent web technology.

James Gosling

Java
• one of the most famous languages of the last two decades
• used to develop enterprise-level applications for video games and mobile apps, as well
as to create web-based applications with JSP (Java Server Pages).
• holds a sizable market share in mobile games and Android apps and enterprise web development world.
• Programs that are written in Java include Adobe Creative Suite, Eclipse, Lotus Notes, Minecraft and OpenOffice.
• Characteristics that have contributed to its popularity:
• Platform independence
• Many languages are compatible with only one platform. Java was specifically designed so that it would
run on any computer
• Simple and easy to use
• Java's creators tried to design it so code could be written efficiently and easily.
• Multi-functional
• can produce many applications from command-line programs to applets to Swing windows (basically,
sophisticated graphical user interfaces).

11
5/11/20

Java
WHO USES IT?
• Professions and Industries:
• Software engineers, Java developers
• Used by employers in communications, education, finance, health
sciences, hospitality, retail and utilities

• Major Organizations:
• V2COM, Eclipse Information Technologies, eBay, Eurotech

• Specializations and Industries:


• Internet of Things (IoT), Enterprise Architecture, Cloud Computing

Swift
• Swift is Apple’s newest open-source, multi-paradigm
programming language for iOS and OS X apps.
• based from the Objective-C programming language, was
introduced at Apple’s 2014 Worldwide Developers Conference
(WWDC).
• integrates Objective-C’s named parameters and object-oriented
model,

• including an advanced compiler, debugger and framework


infrastructure.

12
5/11/20

Swift
WHO USES IT?
• Professions and Industries:
• Swift Platform Developers, iOS Mobile Application Developers, Software
Developers, Senior Programmers, Data Engineers
• Information Technology, Engineering, Design, Management and Professional
Services
• Major Organizations:
• Apple, Getty Images, Slack, Dow Jones, Playlist Media
• Dow Jones is rewriting sections of its mobile Wall Street Journal app using Swift.
• Getty Images built its consumer-facing app, Stream, using Swift.

• Specializations Where Swift is Used Most:


• Software development

13
5/11/20

Multimedia Support by Languages and


Frameworks
• Generally, Multimedia application development requires features and concepts currently not
supported by common systems programming languages.
• Need additional libraries / API for multimedia implementation such as:
• OpenGL
• DirectX
• SFML
• SDL

Multimedia Support is Platform Dependent

14
5/11/20

Multimedia Abstraction Layer

Core Functionality of a Multimedia


Abstraction Layer

15
5/11/20

Additional Functionality for Advanced


Multimedia Applications (Games)

High-Level Multimedia Framework

16
5/11/20

Terminology
• Low-Level Multimedia Framework = Multimedia Abstraction Layer
• Platform independent media handling

• High-Level Multimedia Framework = Game Engine


• Advanced multimedia features
• Specific support for game functionalities
• In most cases includes low-level multimedia framework

Program Control and Frameworks

17
5/11/20

Implementation Language: Criteria


• Handling of multimedia objects
• Built into the language?
• Available in standard library? (e.g. Yes for Java 8)
• Portability to target platforms
• Critical in case of multiple platforms, mobile platforms etc.
• Performance: Memory efficiency
• Performance: Fast execution
• Performance: Access to hardware accelerations
• Performance…

Python, Java, C++

18
5/11/20

Open Graphics Library (OpenGL)


• Cross language, cross platform application programming
interface (API) for rendering 2D and 3D vector graphics.
• Typically used to interact with a graphics processing unit
(GPU),
• to achieve hardware-accelerated rendering.

• Silicon Graphics Inc., (SGI) began developing OpenGL in 1991


and released it on June 30, 1992
• Since 2006, OpenGL has been managed by the non-
profit technology consortium Khronos Group.

Open Graphics Library (OpenGL)


• Applications use it extensively in the fields of:
• computer-aided design (CAD), virtual reality, scientific
visualization, information visualization, flight simulation, video
games
• OpenGL specification describes an abstract API for drawing 2D
and 3D graphics.
• Although it is possible for the API to be implemented entirely in
software, it is designed to be implemented mostly or entirely in
hardware.

• OpenGL examples:
• https://cs.lmu.edu/~ray/notes/openglexamples/
• https://cs.lmu.edu/~ray/notes/flightsimulator/

19
5/11/20

DirectX
• DirectX was released in September 1995 as the Windows
Games SDK.
• Developed by three Microsoft employees—Craig Eisler, Alex St.
John, and Eric Engstrom
• Was the Win32 replacement for the DCI and WinG APIs
for Windows 3.1.
• Allowed all versions of Microsoft Windows, to incorporate
high-performance multimedia.
• starting with Windows 95,

DirectX
• Collection of APIs for handling tasks related to multimedia
on Microsoft platforms.
• especially game programming and video,.
• Originally, the names of these APIs all began with “Direct”
• such as Direct3D, DirectDraw, DirectMusic, DirectPlay,
DirectSound, and so forth.
• The name DirectX was coined as a shorthand term for all of
these APIs (the X standing in for the particular API names)
• Eventually became the name of the collection.

20
5/11/20

Simple and Fast Multimedia Library


• SFML is a simple and portable API written in C++.
• SFML is made of modules
• to be as useful as possible for everyone.
• SFML can be use as:
• a minimalist window system in order to use OpenGL, or
• as a complete multimedia library full of features to build video
games or multimedia software.
• SFML provides a simple interface to the various components
of your PC,
• to ease the development of games and multimedia applications.
• composed of five modules: system, window, graphics, audio and
network.

Simple and Fast Multimedia Library


• SFML is multi-platform and multi-language
• With SFML, your application can compile and run out of the
box on the most common operating systems:
• Windows, Linux, macOS and soon Android & iOS.
• Pre-compiled SDKs for your favourite OS are available

• SFML is implemented in C++.


• several bindings have been created for other languages that
allow SFML to be used
• from C, C#, C++/CLI, D, Ruby, Java, Python and VB.NET.

21
5/11/20

Simple DirectMedia Layer


• SDL is a cross-platform development library
• provide low level access to audio, keyboard, mouse, joystick, and graphics
hardware via OpenGL and Direct3D.
• used by:
• video playback software
• emulators
• popular games

Simple DirectMedia Layer


• SDL officially supports Windows, Mac OS X, Linux, iOS, and Android.
• Support for other platforms may be found in the source code.
• SDL is written in C, works natively with C++, and there are bindings
available for several other languages, including C# and Python.
• SDL 2.0 is distributed under the zlib license.
• This license allows you to use SDL freely in any software.

22
5/11/20

Multimedia Programming Advantages


• The advantages of MM programming languages include:
• Producing multimedia applications to run fast
• Accessing system calls directly
• being able to control non-standard hardware and software
• Being usable for a wide variety of platforms.
• Offers more flexibility
• Lets you tailor the application

Multimedia Programming Disadvantages


• The disadvantages of programming languages include:
• Slower development time
• Need for skilled programmers
• Difficulty in debugging
• Unsuitable for prototyping
• Not specifically designed to create multimedia applications

23

You might also like