Kubernetes Story - Day 1: Build and Manage Containers with PodmanMihai Criveti
OpenShift Workshop Day 1: https://www.youtube.com/watch?v=3IuaZu8-fsY - Build and Manage Containers with Podman
In this workshop you'll learn how to build and manage containers, publish images to Quay, then install and deploy containers onto OpenShift.
Single Page App (SPA) frameworks offer many benefits over traditional web apps which do all of their HTML generation on the server side. Popular SPA frameworks include Vue, React and Angular. Micronaut is very well suited for publishing REST APIs and is a terrific fit for implementing backend logic for SPAs.
Although tools like Varnish can improve performance and scalability for static sites, when user-specific content is needed, a hit to the PHP/Ruby/Python/.Net backend is still required, causing scalability issues. We’ll look at a brand-new Nginx module which implements an ultra-fast and scalable solution to this problem, changing the way developers think about designing sites with user-specific content.
Kubernetes Story - Day 1: Build and Manage Containers with PodmanMihai Criveti
OpenShift Workshop Day 1: https://www.youtube.com/watch?v=3IuaZu8-fsY - Build and Manage Containers with Podman
In this workshop you'll learn how to build and manage containers, publish images to Quay, then install and deploy containers onto OpenShift.
Single Page App (SPA) frameworks offer many benefits over traditional web apps which do all of their HTML generation on the server side. Popular SPA frameworks include Vue, React and Angular. Micronaut is very well suited for publishing REST APIs and is a terrific fit for implementing backend logic for SPAs.
Although tools like Varnish can improve performance and scalability for static sites, when user-specific content is needed, a hit to the PHP/Ruby/Python/.Net backend is still required, causing scalability issues. We’ll look at a brand-new Nginx module which implements an ultra-fast and scalable solution to this problem, changing the way developers think about designing sites with user-specific content.
Get started with Ansible - an introduction for Python developers
Ansible: Provisioning and Configuration Management
Molecule: Test your Ansible Playbooks on Docker, Vagrant or Cloud
Vagrant: Test images with vagrant
This is the presentation that was prepared for our meetup about the Bootstrap framework. More info about that meetup can be found at https://www.meetup.com/lifemichael/events/278511644/
Gradle build tool that rocks with DSL JavaOne India 4th May 2012Rajmahendra Hegde
For the long time, we have used various build tools to package applications for new software releases or applying patches to existing applications etc. dependency management, version controlling, scalability, flexibility, single-multiple projects sup portability are some of the key areas that drove the selection of a build tool, This session focuses on Gradle as a successful build tool and looks into all the above areas and uses Groovy as a DSL. We will also look into how easy it is to use Gradle as compared to other open source build tools.
Photos: https://plus.google.com/u/0/photos/105295086916869617504/albums/5739617166453582993
Gradle build tool that rocks with DSL By Rajmahendra Hegde at JavaOne Hyderabad, India on 4th May 2012
Spring Boot Revisited with KoFu and JaFuVMware Tanzu
SpringOne 2020
Spring Boot Revisited with KoFu and JaFu
Audrey Neveu, Software Engineer on Reactor at VMware
Sébastien Deleuze, Spring Framework Committer at VMware
Kubernetes Story - Day 3: Deploying and Scaling Applications on OpenShiftMihai Criveti
Day 3: OpenShift, CodeReady Containers and Operators https://www.youtube.com/watch?v=0txK3icU2Pg
Experience new tools to build, manage and deploy containerized applications following best practices. Learn how to build containers locally with podman, skopeo and buildah, publish and scan containers for vulnerabilities - and deploy containerized applications locally or on cloud using Kubernetes and OpenShift!
Mihai will take you through the process of:
Day 1 = Build: Building and running container images locally with podman, skopeo and buildah. Building containers for years or just getting started? Check out these new tools that help you build and run containers locally, and how they can help you get started with Kubernetes and OpenShift.
Learn some of the best practices on how you can build containers that run as regular users and how to automate the container build process using buildah. Learn about the Universal Base Image and how you can start your image builds from a known, trusted source.
and then over the next two Fridays the story will evolve as follows...
Day 2 = Publish: Publishing container images to quay.io and scanning containers for vulnerabilities and container best practices
Day 3 = Deploy: Getting started with OpenShift using CodeReady Containers or OKD and deploying containers on a Kubernetes Platform (Red Hat OpenShift / OKD / CRC)
[Image Results] Java Build Tools: Part 2 - A Decision Maker's Guide Compariso...ZeroTurnaround
For you lazy coders out there, we offer the visual aids for the first 3 chapters of "Java Build Tools: Part 2 - A Decision Maker's Comparison of Maven, Gradle and Ant + Ivy". Here you can find the raw scores given to each tool based on 6 feature categories. **Download the full report to see Chapter 4, mapping the features against different user profiles**
PVS-Studio: analyzing pull requests in Azure DevOps using self-hosted agentsAndrey Karpov
Static code analysis is most effective when changing a project, as errors are always more difficult to fix in the future than at an early stage. We continue expanding the options for using PVS-Studio in continuous development systems. This time, we'll show you how to configure pull request analysis using self-hosted agents in Microsoft Azure DevOps, using the example of the Minetest game.
Universal JS Web Applications with React - Luciano Mammino - Codemotion Rome ...Luciano Mammino
Since we started to see JS on the server side, the dream of developers has been to reduce the gap and the cost of switch between frontend/backend technologies. Today with Node.js, React and a whole ecosystem of tools, this dream is becoming real! In this talk, I am going to discuss Universal (a.k.a. Isomorphic) JavaScript and present some practical example regarding the significant patterns related to routing, data retrieval and rendering. I will use Node, React, Webpack, Babel and React Router and give you a series of example to get you started easily with this new technology trend.
(interactive slides at http://slides.com/lucianomammino/universal-js-web-applications-with-react-codemotion-rome-2017 )
MyFaces CODI and JBoss Seam3 become Apache DeltaSpikeos890
These slides show how to use type-safe mechanisms provided by MyFaces CODI for developing JSF applications which are more type-safe and easier to maintain as well as common pitfalls. Beyond that there is an basic overview of Apache DeltaSpike.
Presentazione integrale di Fabio Rizzotto, IT Research & Consulting Director di IDC Italia, portata al roadshow sulla cloud transformation nelle aziende italiane che si è svolto a fine 2012 nelle città di Roma, Bologna, Bari, Torino e Padova
Get started with Ansible - an introduction for Python developers
Ansible: Provisioning and Configuration Management
Molecule: Test your Ansible Playbooks on Docker, Vagrant or Cloud
Vagrant: Test images with vagrant
This is the presentation that was prepared for our meetup about the Bootstrap framework. More info about that meetup can be found at https://www.meetup.com/lifemichael/events/278511644/
Gradle build tool that rocks with DSL JavaOne India 4th May 2012Rajmahendra Hegde
For the long time, we have used various build tools to package applications for new software releases or applying patches to existing applications etc. dependency management, version controlling, scalability, flexibility, single-multiple projects sup portability are some of the key areas that drove the selection of a build tool, This session focuses on Gradle as a successful build tool and looks into all the above areas and uses Groovy as a DSL. We will also look into how easy it is to use Gradle as compared to other open source build tools.
Photos: https://plus.google.com/u/0/photos/105295086916869617504/albums/5739617166453582993
Gradle build tool that rocks with DSL By Rajmahendra Hegde at JavaOne Hyderabad, India on 4th May 2012
Spring Boot Revisited with KoFu and JaFuVMware Tanzu
SpringOne 2020
Spring Boot Revisited with KoFu and JaFu
Audrey Neveu, Software Engineer on Reactor at VMware
Sébastien Deleuze, Spring Framework Committer at VMware
Kubernetes Story - Day 3: Deploying and Scaling Applications on OpenShiftMihai Criveti
Day 3: OpenShift, CodeReady Containers and Operators https://www.youtube.com/watch?v=0txK3icU2Pg
Experience new tools to build, manage and deploy containerized applications following best practices. Learn how to build containers locally with podman, skopeo and buildah, publish and scan containers for vulnerabilities - and deploy containerized applications locally or on cloud using Kubernetes and OpenShift!
Mihai will take you through the process of:
Day 1 = Build: Building and running container images locally with podman, skopeo and buildah. Building containers for years or just getting started? Check out these new tools that help you build and run containers locally, and how they can help you get started with Kubernetes and OpenShift.
Learn some of the best practices on how you can build containers that run as regular users and how to automate the container build process using buildah. Learn about the Universal Base Image and how you can start your image builds from a known, trusted source.
and then over the next two Fridays the story will evolve as follows...
Day 2 = Publish: Publishing container images to quay.io and scanning containers for vulnerabilities and container best practices
Day 3 = Deploy: Getting started with OpenShift using CodeReady Containers or OKD and deploying containers on a Kubernetes Platform (Red Hat OpenShift / OKD / CRC)
[Image Results] Java Build Tools: Part 2 - A Decision Maker's Guide Compariso...ZeroTurnaround
For you lazy coders out there, we offer the visual aids for the first 3 chapters of "Java Build Tools: Part 2 - A Decision Maker's Comparison of Maven, Gradle and Ant + Ivy". Here you can find the raw scores given to each tool based on 6 feature categories. **Download the full report to see Chapter 4, mapping the features against different user profiles**
PVS-Studio: analyzing pull requests in Azure DevOps using self-hosted agentsAndrey Karpov
Static code analysis is most effective when changing a project, as errors are always more difficult to fix in the future than at an early stage. We continue expanding the options for using PVS-Studio in continuous development systems. This time, we'll show you how to configure pull request analysis using self-hosted agents in Microsoft Azure DevOps, using the example of the Minetest game.
Universal JS Web Applications with React - Luciano Mammino - Codemotion Rome ...Luciano Mammino
Since we started to see JS on the server side, the dream of developers has been to reduce the gap and the cost of switch between frontend/backend technologies. Today with Node.js, React and a whole ecosystem of tools, this dream is becoming real! In this talk, I am going to discuss Universal (a.k.a. Isomorphic) JavaScript and present some practical example regarding the significant patterns related to routing, data retrieval and rendering. I will use Node, React, Webpack, Babel and React Router and give you a series of example to get you started easily with this new technology trend.
(interactive slides at http://slides.com/lucianomammino/universal-js-web-applications-with-react-codemotion-rome-2017 )
MyFaces CODI and JBoss Seam3 become Apache DeltaSpikeos890
These slides show how to use type-safe mechanisms provided by MyFaces CODI for developing JSF applications which are more type-safe and easier to maintain as well as common pitfalls. Beyond that there is an basic overview of Apache DeltaSpike.
Presentazione integrale di Fabio Rizzotto, IT Research & Consulting Director di IDC Italia, portata al roadshow sulla cloud transformation nelle aziende italiane che si è svolto a fine 2012 nelle città di Roma, Bologna, Bari, Torino e Padova
GARA University2Business - Everis Italia, società di consulenza che offre soluzioni in grado di trasformare ogni organizzazione in un leader di mercato. L'azienda opera nei principali settori industriali: assicurazioni ed istituzioni finanziarie in genere, telecomunicazioni, industria, utilities ed energia, Amministrazioni Pubbliche, media e sanità.
Secondo varie ricerche svolte negli ultimi anni, quello degli Istituti Finanziari è tra i settori che godono del più basso indice di fiducia da parte dei propri clienti a livello mondiale, ma soprattutto per quanto riguarda il Vecchio Continente.
Everis ritiene che l’innovazione legata ai servizi offerti possa essere una delle leve principali attraverso cui gli Istituti Finanziari possono recuperare la fiducia nel rapporto con i propri clienti.
In particolare Everis è interessata ad individuare idee innovative relativamente ai servizi distintivi che gli Istituti Finanziari potrebbero offrire sfruttando le potenzialità delle tecnologie di ultima generazione con particolare riferimento ai wearable devices che stanno conquistando uno spazio sempre maggiore all’interno del mercato (es. google glass, smart watches, ecc…).
l documento in MS PowerPoint elaborato presenta, nella prima parte, una breve analisi di quelli che sono i trend attuali e le possibili (prossime) prospettive del settore finanziario e della tecnologia wearable, con un focus specifico sugli smartwatch, device scelto per l'applicazione proposta, descritta nella seconda parte della presentazione. Il mercato dei "Wearables", e in particolare degli smartwatch, è in costante crescita, stando ai dati IDC, gruppo mondiale specializzato in ricerche di mercato e servizi di consulenza.
Si è optato per il Sony Smartwatch 3, tra i più economici sul mercato e dotato di tecnologia e-paper per assicurare il minimo consumo energetico e la massima visibilità anche sotto il Sole.
L’applicazione proposta per la Gara consentirà agli utenti di controllare tutti i dettagli relativi alle operazioni effettuate sul proprio conto corrente nonché di scegliere azioni e indici dei mercati internazionali (FTSE MIB, Dow Jones, Nasdaq, Eurostoxx e altri) e seguirli praticamente in tempo reale. L’orologio visualizza le ultime informazioni, il prezzo per ogni azione e l’indice, così come le fluttuazioni dall’inizio della sessione di mercato.
L'app rappresenta dunque una soluzione smart, wearable, per avere sempre sotto controllo, al polso, il proprio portafoglio titoli e/o il proprio conto corrente.
A new way of social couponing!
Una piattaforma che vuole unire Social Couponing e Social Influence, in modo semplice, accessibile, ma innovativo. La nostra formula è "Be social, get it free!"; registrati, invita i tuoi amici, condividi le offerte con loro, incrementa la tua influence: socializza e ricevi coupon gratis e altri bonus esclusivi.
L'utente potrà (dovrà) sfruttare la propria social influence (misurata mediante algoritmo) per ottenere sconti esclusivi, coupon gratis e vantaggi, stando comodamente davanti al pc, smartphone o tablet e condividendo i vari coupon con gli amici. Più facile di così?
FOLLOW US: https://www.facebook.com/socigo.it
The brief presenteation have been showed at the <a href="http://www.iskoi.org/doc/milano07.htm">3rd annual ISKO meeting</a> on 22nd of June 2007 at Università di Milano Bicocca.
It's about the impact of information visualization in knowledge organization and discovery and it illustrates <a href="http://www.mentegrafica.it/blog/2006/11/04/infovis-and-thesaurus-a-new-document-available/">Domenico's dissertation project</a>.
This presentation has been created by Francesca Valsecchi, Domenico Frontera and me.
The evolution of semantic technology evaluation in my own flesh (The 15 tip...Raúl García Castro
Slides of my talk given at IMATI-CNR on October 15th 2013.
If you like them, I am available for gigs!
Abstract:
In this talk I will describe how semantic technology evaluation has evolved in the last ten years, focusing on my own research and experiences. It starts with evaluation as a one-time one-user activity and shows the progress towards mature evaluations that are community-driven and supported by rich methods and infrastructures. Along this talk, I will unveil the 15 tips for technology evaluation, which should be of interest for anyone interested in such topic.
Presentazione di Sergio Patano, Research & Consulting Manager di IDC Italia, tenuta all’IDC Big Data & Analytics Conference 2014 di Milano, il 18 Settembre 2014
Qual è lo scenario attuale delle Start-up in Italia? Quali i trend dell'ultimo anno? In quali settori ci sono più investimenti e quali sono i luoghi in cui si coltiva la cultura del fare innovazione?
IDC Mobiz Mobility Forum 2016 - "Enterprise of Everything: individui iperconn...IDC Italy
Abstract della presentazione di Gabriele Roberti, Research & Consulting Manager di IDC Italia, tenuta all'evento IDC Mobiz Mobility Forum 2016 di Milano il 22 giugno 2016
Data driven economy: l’impatto sulle infrastrutture IT e la data governance a...IDC Italy
Abstract della presentazione di Giancarlo Vercellino, Research & Consulting Manager di IDC Italia, tenuta nel corso dell'evento Building the Scalable Data Foundation for Digital Transformation svoltosi a Milano il 16 novembre 2016
This slide telling what "adaptive streaming" is. In the beginning, it explains how content(media) is prepared to fit adaptive needs, then talking about yapi.js - which is the web player used by KKTV(VOD service) in Taiwan.
How to implement camera recording for USB webcam or IP camera in C#.NETOzeki Informatics Ltd.
More info: www.camera-sdk.com
Source code: http://www.camera-sdk.com/p_123-video-tutorial-on-how-to-record-video-in-c-onvif.html
Welcome to this presentation that explains step-by-step how to develop video recording feature for your USB webcam and your IP camera / ONVIF IP camera in C#.NET to be able to capture and save the camera image. Good luck, have fun!
OpenCMIS, an Apache Chemistry sub-project, is an open source library which provides a simple Java API for accessing any CMIS compliant content repository. Think of it as the JDBC of content repositories. In this session, you'll learn about the architecture of OpenCMIS and walkthrough many code samples showing how easy it is to build CMIS-based applications.
Building Apps with SwiftUI and FirebasePeter Friese
In this talk, I'm going to show how to build data-driven SwiftUI applications that uses Cloud Firestore to store data.
You will learn how to architect your SwiftUI app so both its local and remote state stay in sync in real time
A quick overview of tips, tricks and code snippets for developers using Symfony and all its ecosystem, from Monolog to Doctrine. Learn how to become more productive and discover some rarely used options and features.
Replacing ActiveRecord callbacks with Pub/Subnburkley
As your application grows ActiveRecord callbacks can easily get out of hand - creating a chain of dependencies between your models and mixing in business logic where it doesn't belong.
On some recent projects, I've been using the 'wisper' gem to replace some callbacks with a simple publish/subscribe pattern decoupling callbacks from models.
I'd like talk about the benefits of using this approach and give a brief run through of how to go about it.
This is the support of a course to teach React programming for Java and C# programmers. It covers from its origins in Facebook til separation of presentational and container components. What is JSX, rules, state, props, refactoring, conditionals, repeats, forms, synchronizing values, composition, and so on.
Similar to 17 camera, media, and audio in windows phone 8.1 (20)
Generating a custom Ruby SDK for your web service or Rails API using Smithyg2nightmarescribd
Have you ever wanted a Ruby client API to communicate with your web service? Smithy is a protocol-agnostic language for defining services and SDKs. Smithy Ruby is an implementation of Smithy that generates a Ruby SDK using a Smithy model. In this talk, we will explore Smithy and Smithy Ruby to learn how to generate custom feature-rich SDKs that can communicate with any web service, such as a Rails JSON API.
UiPath Test Automation using UiPath Test Suite series, part 3DianaGray10
Welcome to UiPath Test Automation using UiPath Test Suite series part 3. In this session, we will cover desktop automation along with UI automation.
Topics covered:
UI automation Introduction,
UI automation Sample
Desktop automation flow
Pradeep Chinnala, Senior Consultant Automation Developer @WonderBotz and UiPath MVP
Deepak Rai, Automation Practice Lead, Boundaryless Group and UiPath MVP
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...UiPathCommunity
💥 Speed, accuracy, and scaling – discover the superpowers of GenAI in action with UiPath Document Understanding and Communications Mining™:
See how to accelerate model training and optimize model performance with active learning
Learn about the latest enhancements to out-of-the-box document processing – with little to no training required
Get an exclusive demo of the new family of UiPath LLMs – GenAI models specialized for processing different types of documents and messages
This is a hands-on session specifically designed for automation developers and AI enthusiasts seeking to enhance their knowledge in leveraging the latest intelligent document processing capabilities offered by UiPath.
Speakers:
👨🏫 Andras Palfi, Senior Product Manager, UiPath
👩🏫 Lenka Dulovicova, Product Program Manager, UiPath
JMeter webinar - integration with InfluxDB and GrafanaRTTS
Watch this recorded webinar about real-time monitoring of application performance. See how to integrate Apache JMeter, the open-source leader in performance testing, with InfluxDB, the open-source time-series database, and Grafana, the open-source analytics and visualization application.
In this webinar, we will review the benefits of leveraging InfluxDB and Grafana when executing load tests and demonstrate how these tools are used to visualize performance metrics.
Length: 30 minutes
Session Overview
-------------------------------------------
During this webinar, we will cover the following topics while demonstrating the integrations of JMeter, InfluxDB and Grafana:
- What out-of-the-box solutions are available for real-time monitoring JMeter tests?
- What are the benefits of integrating InfluxDB and Grafana into the load testing stack?
- Which features are provided by Grafana?
- Demonstration of InfluxDB and Grafana using a practice web application
To view the webinar recording, go to:
https://www.rttsweb.com/jmeter-integration-webinar
Builder.ai Founder Sachin Dev Duggal's Strategic Approach to Create an Innova...Ramesh Iyer
In today's fast-changing business world, Companies that adapt and embrace new ideas often need help to keep up with the competition. However, fostering a culture of innovation takes much work. It takes vision, leadership and willingness to take risks in the right proportion. Sachin Dev Duggal, co-founder of Builder.ai, has perfected the art of this balance, creating a company culture where creativity and growth are nurtured at each stage.
Elevating Tactical DDD Patterns Through Object CalisthenicsDorra BARTAGUIZ
After immersing yourself in the blue book and its red counterpart, attending DDD-focused conferences, and applying tactical patterns, you're left with a crucial question: How do I ensure my design is effective? Tactical patterns within Domain-Driven Design (DDD) serve as guiding principles for creating clear and manageable domain models. However, achieving success with these patterns requires additional guidance. Interestingly, we've observed that a set of constraints initially designed for training purposes remarkably aligns with effective pattern implementation, offering a more ‘mechanical’ approach. Let's explore together how Object Calisthenics can elevate the design of your tactical DDD patterns, offering concrete help for those venturing into DDD for the first time!
State of ICS and IoT Cyber Threat Landscape Report 2024 previewPrayukth K V
The IoT and OT threat landscape report has been prepared by the Threat Research Team at Sectrio using data from Sectrio, cyber threat intelligence farming facilities spread across over 85 cities around the world. In addition, Sectrio also runs AI-based advanced threat and payload engagement facilities that serve as sinks to attract and engage sophisticated threat actors, and newer malware including new variants and latent threats that are at an earlier stage of development.
The latest edition of the OT/ICS and IoT security Threat Landscape Report 2024 also covers:
State of global ICS asset and network exposure
Sectoral targets and attacks as well as the cost of ransom
Global APT activity, AI usage, actor and tactic profiles, and implications
Rise in volumes of AI-powered cyberattacks
Major cyber events in 2024
Malware and malicious payload trends
Cyberattack types and targets
Vulnerability exploit attempts on CVEs
Attacks on counties – USA
Expansion of bot farms – how, where, and why
In-depth analysis of the cyber threat landscape across North America, South America, Europe, APAC, and the Middle East
Why are attacks on smart factories rising?
Cyber risk predictions
Axis of attacks – Europe
Systemic attacks in the Middle East
Download the full report from here:
https://sectrio.com/resources/ot-threat-landscape-reports/sectrio-releases-ot-ics-and-iot-security-threat-landscape-report-2024/
Securing your Kubernetes cluster_ a step-by-step guide to success !KatiaHIMEUR1
Today, after several years of existence, an extremely active community and an ultra-dynamic ecosystem, Kubernetes has established itself as the de facto standard in container orchestration. Thanks to a wide range of managed services, it has never been so easy to set up a ready-to-use Kubernetes cluster.
However, this ease of use means that the subject of security in Kubernetes is often left for later, or even neglected. This exposes companies to significant risks.
In this talk, I'll show you step-by-step how to secure your Kubernetes cluster for greater peace of mind and reliability.
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...DanBrown980551
Do you want to learn how to model and simulate an electrical network from scratch in under an hour?
Then welcome to this PowSyBl workshop, hosted by Rte, the French Transmission System Operator (TSO)!
During the webinar, you will discover the PowSyBl ecosystem as well as handle and study an electrical network through an interactive Python notebook.
PowSyBl is an open source project hosted by LF Energy, which offers a comprehensive set of features for electrical grid modelling and simulation. Among other advanced features, PowSyBl provides:
- A fully editable and extendable library for grid component modelling;
- Visualization tools to display your network;
- Grid simulation tools, such as power flows, security analyses (with or without remedial actions) and sensitivity analyses;
The framework is mostly written in Java, with a Python binding so that Python developers can access PowSyBl functionalities as well.
What you will learn during the webinar:
- For beginners: discover PowSyBl's functionalities through a quick general presentation and the notebook, without needing any expert coding skills;
- For advanced developers: master the skills to efficiently apply PowSyBl functionalities to your real-world scenarios.
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024Albert Hoitingh
In this session I delve into the encryption technology used in Microsoft 365 and Microsoft Purview. Including the concepts of Customer Key and Double Key Encryption.
7. // Create NOK Imaging SDK effects pipeline and run it
var imageStream = new BitmapImageSource(image.AsBitmap());
using (var effect = new FilterEffect(imageStream))
{
// Define the filters list
var filter = new AntiqueFilter();
effect.Filters = new[] { filter };
// Render the filtered image to a WriteableBitmap.
var renderer = new WriteableBitmapRenderer(effect, editedBitmap);
editedBitmap = await renderer.RenderAsync();
editedBitmap.Invalidate();
// Show image in Xaml Image control
Image.Source = editedBitmap;
}
13. // Create MediaCapture and init
mediaCapture = new MediaCapture();
await mediaCapture.InitializeAsync();
// Assign to Xaml CaptureElement.Source and start preview
PreviewElement.Source = mediaCapture;
await mediaCapture.StartPreviewAsync();
// Create MediaCapture and init
mediaCapture = new MediaCapture();
await mediaCapture.InitializeAsync();
// Interop between new MediaCapture API and SL 8.1 to show
// the preview in SL XAML as Rectangle.Fill
var previewSink = new MediaCapturePreviewSink();
var videoBrush = new VideoBrush();
videoBrush.SetSource(previewSink);
PreviewElement.Fill = videoBrush;
// Find the supported preview size
var vdc = mediaCapture.VideoDeviceController;
var availableMediaStreamProperties =
vdc.GetAvailableMediaStreamProperties(MediaStreamType.VideoPreview);
// More LINQ selection happens here in the demo to find closest format
var previewFormat = availableMediaStreamProperties.FirstOrDefault();
// Start Preview stream
await vdc.SetMediaStreamPropertiesAsync(MediaStreamType.VideoPreview,
previewFormat);
await mediaCapture.StartPreviewToCustomSinkAsync(
new MediaEncodingProfile { Video = previewFormat }, previewSink);
14. public async Task CapturePhoto()
{
// Create photo encoding properties as JPEG and set the size that should be used for capturing
var imgEncodingProperties = ImageEncodingProperties.CreateJpeg();
imgEncodingProperties.Width = 640;
imgEncodingProperties.Height = 480;
// Create new unique file in the pictures library and capture photo into it
var photoStorageFile = await KnownFolders.PicturesLibrary.CreateFileAsync("photo.jpg",
CreationCollisionOption.GenerateUniqueName);
await mediaCapture.CapturePhotoToStorageFileAsync(imgEncodingProperties, photoStorageFile);
}
16. public async Task StartVideoRecording()
{
// Create video encoding profile as MP4
var videoEncodingProperties = MediaEncodingProfile.CreateMp4(VideoEncodingQuality.Vga);
// Create new unique file in the videos library and record video!
var videoStorageFile = await KnownFolders.VideosLibrary.CreateFileAsync("video.mp4",
CreationCollisionOption.GenerateUniqueName);
await mediaCapture.StartRecordToStorageFileAsync(videoEncodingProperties, videoStorageFile);
}
public async Task StopVideoRecording()
{
await mediaCapture.StopRecordAsync();
// Start playback in MediaElement
var videoFileStream = await videoFile.OpenReadAsync();
PlaybackElement.SetSource(videoFileStream, videoFile.ContentType);
}
21. // Wire up current screen as input for the MediaCapture
var screenCapture = ScreenCapture.GetForCurrentView();
mediaCapture = new MediaCapture();
await mediaCapture.InitializeAsync(new MediaCaptureInitializationSettings
{
VideoSource = screenCapture.VideoSource,
AudioSource = screenCapture.AudioSource,
});
// Create video encoding profile as MP4
var videoEncodingProperties = MediaEncodingProfile.CreateMp4(VideoEncodingQuality.Vga);
// Create new unique file in the videos library and record video!
var videoStorageFile = await KnownFolders.VideosLibrary.CreateFileAsync("screenrecording.mp4",
CreationCollisionOption.GenerateUniqueName);
await mediaCapture.StartRecordToStorageFileAsync(videoEncodingProperties, videoStorageFile);
26. mediaComposition = new MediaComposition();
foreach (StorageFile videoFile in videoFiles)
{
// Create Clip and add to composition
var clip = await MediaClip.CreateFromFileAsync(videoFile);
mediaComposition.Clips.Add(clip);
// Create thumbnail to show as placeholder in an UI ListView
var thumbnail = await videoFile.GetThumbnailAsync(ThumbnailMode.VideosView);
var image = new BitmapImage();
image.SetSource(thumbnail);
// Add to a viewmodel used as ItemsSource for a ListView of clips
videoClips.Add(new VideoClip(clip, image, videoFile.Name));
}
27. // Trimming. Skip 1 second from the beginning of the clip and 2 from the end
var clipVm = videoClips.SelectedClip;
clipVm.Clip.TrimTimeFromStart = TimeSpan.FromSeconds(1);
clipVm.Clip.TrimTimeFromEnd = clipVm.Clip.OriginalDuration.Subtract(TimeSpan.FromSeconds(2));
// Add MP3 as background which was deployed together with the AppX package
var file = await Package.Current.InstalledLocation.GetFileAsync("mymusic.mp3");
var audio = await BackgroundAudioTrack.CreateFromFileAsync(file);
mediaComposition.BackgroundAudioTracks.Add(audio);
28. // Play the composed result including all clips and the audio track in a Xaml MediaElement
var w = (int) MediaElement.ActualWidth;
var h = (int) MediaElement.ActualHeight;
MediaElement.SetMediaStreamSource(mediaComposition.GeneratePreviewMediaStreamSource(w, h)));
// Create output file
var vidLib = KnownFolders.VideosLibrary;
var resultFile = await vidLib.CreateFileAsync("myComposition.mp4",
CreationCollisionOption.ReplaceExisting);
// Encode new composition as MP4 to the file
var mediaEncodingProfile = MediaEncodingProfile.CreateMp4(VideoEncodingQuality.Vga);
await mediaComposition.RenderToFileAsync(resultFile, MediaTrimmingPreference.Fast, mediaEncodingProfile);
35. // Attach event handler to background player to update UI
BackgroundMediaPlayer.Current.CurrentStateChanged += MediaPlayerStateChanged;
// Uri could also be ms-appx:/// for package-local tracks
BackgroundMediaPlayer.Current.SetUriSource(new Uri("http://foo.bar/my.mp3"));
// Starts play since MediaPlayer.AutoPlay=true by default
// Or trigger manually play when AutoPlay=false
BackgroundMediaPlayer.Current.Play();
// Pause.
BackgroundMediaPlayer.Current.Pause();
// Stop. There's no MediaPlayer.Stop() method
BackgroundMediaPlayer.Current.Pause();
BackgroundMediaPlayer.Current.Position = TimeSpan.FromSeconds(0);
36. private async void MediaPlayerStateChanged(MediaPlayer sender, object args)
{
// This event is called from a background thread, so dispatch to UI
await Dispatcher.RunAsync(CoreDispatcherPriority.Normal, () =>
{
switch (BackgroundMediaPlayer.Current.CurrentState)
{
case MediaPlayerState.Playing:
AppBarBtnPause.IsEnabled = true;
// Pass params on to background process, so it can update the UVC text there
BackgroundMediaPlayer.SendMessageToBackground(new ValueSet
{ {"Title", "My Super MP3"}, {"Artist", "Foo Bar"} });
break;
case MediaPlayerState.Paused:
AppBarBtnPause.IsEnabled = false;
break;
}
});
}
37. public void Run(IBackgroundTaskInstance taskInstance)
{
// Initialize SMTC object to talk with UVC
// This is intended to run after app is paused,
// therefore all the logic must be written to run in background process
systemmediatransportcontrol = SystemMediaTransportControls.GetForCurrentView();
systemmediatransportcontrol.ButtonPressed += SystemControlsButtonPressed;
systemmediatransportcontrol.IsEnabled = true;
systemmediatransportcontrol.IsPauseEnabled = true;
systemmediatransportcontrol.IsPlayEnabled = true;
// Add handlers to update SMTC when MediaPlayer is used in foreground
BackgroundMediaPlayer.Current.CurrentStateChanged += BackgroundMediaPlayerCurrentStateChanged;
BackgroundMediaPlayer.MessageReceivedFromForeground += BackgroundMediaPlayerOnMessageReceived;
}
42. 47
Windows Phone 8 Windows Phone 8.1
Silverlight
Windows Phone 8.1
WinRT
Windows 8.1
Windows.Phone.
Media.Capture
Yes No No No
Windows.
Media.Capture
No Yes Yes Yes
VariablePhoto-
SequenceCapture
No Yes Yes No
ScreenCapture No Yes Yes No
43. 48
Windows Phone 8 Windows Phone 8.1
Silverlight
Windows Phone 8.1
WinRT
Windows 8.1
Windows.Media.
Editing
No Yes Yes No
Windows.Media.
Transcoding
No Yes Yes Yes
44. 49
Windows Phone 8 Windows Phone 8.1
Silverlight
Windows Phone 8.1
WinRT
Windows 8.1
Windows.Media.
BackgroundPlayback
No No Yes No
Microsoft.Phone.
BackgroundAudio
Yes No No No
MediaElement
AudioCategory=
"BackgroundCapable
Media"
No No No Yes